intial commit of tests, documentation

This commit is contained in:
2022-11-05 13:53:37 -05:00
parent 9085c184bf
commit 852acafcae
115 changed files with 21599 additions and 1229 deletions

View File

@@ -0,0 +1,20 @@
import unittest
from tests.base import BaseModelTestCase
from unittest import TestCase
from pyteamsnap.models import EventLineupEntry, Event
@unittest.skip("EventLineupEntry Test Known to Fail, need to figure out how to filter events that have a lineup and therefore entries")
class TestEventLineupEntry(BaseModelTestCase, TestCase):
__test__ = True
TestClass = EventLineupEntry
def test_data(self):
with self.cassette:
event_search_results = Event.search(self.client, team_id=self.TEAMSNAP_TEAM)
event_instance = event_search_results[0]
search_results = self.TestClass.search(self.client, event_id=event_instance.id)
instance = search_results[0]
self.assertIsInstance(instance, self.TestClass)
self.assertTrue(len(instance.data))
return instance