Exemple #1
0
def test_open_editor():
    level = client.run(client.get_level(30029017))
    assert level.open_editor().objects
Exemple #2
0
import pytest

from conftest import client, gd

# PREPARATIONS

pytestmark = pytest.mark.asyncio

artist = client.run(client.get_artist_info(1))


# MAIN TESTS
async def test_get_artist_info():
    custom_song = await client.get_song(1)
    await custom_song.get_artist_info()

    official_song = gd.Song.official(0)
    await official_song.get_artist_info()


async def test_artist_properties():
    info = await client.get_artist_info(1)
    assert info.artist
    assert info.song
    assert info.exists

    assert info.is_scouted()
    assert info.is_whitelisted()
    assert info.api_allowed()

Exemple #3
0
from datetime import datetime
import pytest

from conftest import client, gd

# PREPARATIONS

pytestmark = pytest.mark.asyncio

level = client.run(client.get_level(30029017))
message = "[gd.py] ({}): Running tests...".format(datetime.utcnow())


# MAIN TESTS
async def test_attach_client():
    level.attach_client(client)


async def test_properties():
    level.name
    level.description
    level.version
    level.downloads
    level.rating
    level.score
    level.creator
    level.song
    level.difficulty
    level.password
    level.stars
    level.coins
Exemple #4
0
from datetime import datetime
import pytest

from conftest import client

# PREPARATIONS

pytestmark = pytest.mark.asyncio
user = client.run(client.search_user("NeKitDS"))

message = "[gd.py] ({}): Running tests...".format(datetime.utcnow())


# MAIN TESTS
async def test_properties():
    user.stars
    user.demons
    user.cp
    user.diamonds
    user.coins
    user.user_coins
    user.lb_place
    user.role
    user.rank
    user.youtube
    user.youtube_link
    user.twitter
    user.twitter_link
    user.twitch
    user.twitch_link
    user.message_policy
Exemple #5
0
from datetime import datetime
import pytest

from conftest import client

# PREPARATIONS

pytestmark = pytest.mark.asyncio
user = client.run(client.search_user('NeKitDS'))

message = ('[gd.py] ({}): Running tests...'.format(datetime.utcnow()))


# MAIN TESTS
async def test_properties():
    user.stars
    user.demons
    user.cp
    user.diamonds
    user.coins
    user.user_coins
    user.lb_place
    user.role
    user.rank
    user.youtube
    user.youtube_link
    user.twitter
    user.twitter_link
    user.twitch
    user.twitch_link
    user.msg_policy
Exemple #6
0
from datetime import datetime
import pytest

from conftest import client

# PREPARATIONS

pytestmark = pytest.mark.asyncio
user = client.run(client.search_user("nekitdev"))

message = "[gd.py] ({}): Running tests...".format(datetime.utcnow())


# MAIN TESTS
async def test_properties():
    user.stars
    user.demons
    user.cp
    user.diamonds
    user.coins
    user.user_coins
    user.place
    user.role
    user.rank
    user.youtube
    user.youtube_link
    user.twitter
    user.twitter_link
    user.twitch
    user.twitch_link
    user.message_policy