### Question:
MultiplayerType { public int getRoomSize(Object data) { return roomSize; } MultiplayerType(int roomSize, boolean disposable);  MultiplayerType(int roomSize, int levelsCount, boolean disposable); boolean isDisposable(); boolean isSingle(); boolean isMultiple(); boolean isTriple(); boolean isTournament(); boolean isQuadro(); boolean isTeam(); boolean isSingleplayer(); boolean isMultiplayer(); boolean isTraining(); boolean isLastLevel(int levelNumber); String getType(); int loadProgress(Game game, JSONObject save); int getRoomSize(Object data); int getRoomSize(); int getLevelsCount(); final static boolean DISPOSABLE; static final MultiplayerType SINGLE; static final MultiplayerType MULTIPLE; static final BiFunction<Integer, Boolean, MultiplayerType> TEAM; static final MultiplayerType TOURNAMENT; static final MultiplayerType TRIPLE; static MultiplayerType QUADRO; static final Function<Integer, MultiplayerType> TRAINING; }### Answer:
@Test public void typeTraining_lastLevelIsMultiple() { MultiplayerType type = MultiplayerType.TRAINING.apply(3); assertEquals(1, type.getRoomSize()); assertEquals(1, type.getRoomSize(new LevelProgress(3, 1, 2))); assertEquals(1, type.getRoomSize(new LevelProgress(3, 2, 2))); assertEquals(Integer.MAX_VALUE, type.getRoomSize(new LevelProgress(3, 3, 3))); }