Beispiel #1
0
    def test_game_list_content(self, client):
        GameFactory.create_batch(3)
        GameFactory(game_activated=False)

        gameList = Game.objects.exclude(game_activated=False)
        response = client.get('/api/games/')

        assert gameList.count() == len(response.data)
Beispiel #2
0
def list_games(num_games=2):
    return GameFactory.create_batch(num_games)