Register custom marks

This commit is contained in:
Michael Shepanski 2019-10-02 21:29:08 -04:00
parent 8bdd83164d
commit 73502f8f24
2 changed files with 8 additions and 2 deletions

6
pytest.ini Normal file
View file

@ -0,0 +1,6 @@
[pytest]
markers =
client: this is a client test.
req_client: require a client to run this test.
anonymously: test plexapi anonymously.
authenticated: test plexapi authenticated.

View file

@ -12,6 +12,8 @@ from plexapi.compat import patch, MagicMock
from plexapi.client import PlexClient
from plexapi.server import PlexServer
SERVER_BASEURL = plexapi.CONFIG.get('auth.server_baseurl')
MYPLEX_USERNAME = plexapi.CONFIG.get('auth.myplex_username')
MYPLEX_PASSWORD = plexapi.CONFIG.get('auth.myplex_password')
@ -34,8 +36,6 @@ ENTITLEMENTS = {'ios', 'roku', 'android', 'xbox_one', 'xbox_360', 'windows', 'wi
TEST_AUTHENTICATED = 'authenticated'
TEST_ANONYMOUSLY = 'anonymously'
ANON_PARAM = pytest.param(TEST_ANONYMOUSLY, marks=pytest.mark.anonymous)
AUTH_PARAM = pytest.param(TEST_AUTHENTICATED, marks=pytest.mark.authenticated)