예제 #1
0
파일: test.py 프로젝트: youdonotexist/gjms
def test_plat_game_relation_game():
    """ Test platform-game relationship from a game viewpoint. """

    game = games.get("Flingler")
    platform = platforms.get("Windows")
    platform2 = platforms.get("Android")

    game.platforms.append(platform)
    game.platforms.append(platform2)

    assert platform in game.platforms
    assert platform2 in game.platforms
예제 #2
0
def test_plat_game_relation_game():
    """ Test platform-game relationship from a game viewpoint. """

    game = games.get("Flingler")
    platform = platforms.get("Windows")
    platform2 = platforms.get("Android")

    game.platforms.append(platform)
    game.platforms.append(platform2)

    assert platform in game.platforms
    assert platform2 in game.platforms
예제 #3
0
파일: test.py 프로젝트: youdonotexist/gjms
def test_delete_platform():
    """ Test platform deleting. """

    platform = platforms.get("Windows")
    platform.delete()

    assert_raises(exceptions.NonExistentPlatform, platforms.get, "Windows")
예제 #4
0
파일: test.py 프로젝트: youdonotexist/gjms
def test_plat_game_relation_plat():
    """ Test platform-game relationship from a platform viewpoint. """

    platform = platforms.get("Android")
    game = games.get("Flingler")

    assert game in platform.games
예제 #5
0
def test_delete_platform():
    """ Test platform deleting. """

    platform = platforms.get("Windows")
    platform.delete()

    assert_raises(exceptions.NonExistentPlatform, platforms.get, "Windows")
예제 #6
0
def test_plat_game_relation_plat():
    """ Test platform-game relationship from a platform viewpoint. """

    platform = platforms.get("Android")
    game = games.get("Flingler")

    assert game in platform.games
예제 #7
0
파일: test.py 프로젝트: youdonotexist/gjms
def test_platform_get():
    """ Test platform getting. """

    platform = platforms.get("Windows")

    assert type(platform) == models.Platform
예제 #8
0
def test_platform_get():
    """ Test platform getting. """

    platform = platforms.get("Windows")

    assert type(platform) == models.Platform