use of com.faforever.server.rating.RatingService in project faf-java-server by FAForever.
the class MatchMakerServiceTest method setUp.
@Before
public void setUp() throws Exception {
properties = new ServerProperties();
FeaturedMod ladder1v1Mod = new FeaturedMod().setTechnicalName("faf");
when(modService.getFeaturedMod(ladder1v1Mod.getTechnicalName())).thenReturn(Optional.of(ladder1v1Mod));
when(modService.getLadder1v1()).thenReturn(Optional.of(ladder1v1Mod));
when(modService.isLadder1v1(ladder1v1Mod)).thenReturn(true);
when(mapService.getRandomLadderMap()).thenReturn(new MapVersion().setFilename("maps/SCMP_001.zip"));
when(gameService.createGame(any(), any(), any(), any(), any(), anyInt(), anyInt(), any())).thenReturn(CompletableFuture.completedFuture(new Game().setId(1)));
RatingService ratingService = new RatingService(properties);
instance = new MatchMakerService(modService, properties, ratingService, clientService, gameService, mapService, playerService);
}
Aggregations