updates to pyswiss aspect & aspect application data served over API, incl. seminal invocation of Space parades & Time stellia
This commit is contained in:
@@ -114,10 +114,42 @@ class ChartApiTest(TestCase):
|
||||
"""All 10 planets are assigned to exactly one classical element."""
|
||||
data = self._get({'dt': J2000, **LONDON}).json()
|
||||
classical = sum(
|
||||
data['elements'][e] for e in ('Fire', 'Water', 'Earth', 'Air')
|
||||
data['elements'][e]['count'] for e in ('Fire', 'Water', 'Earth', 'Air')
|
||||
)
|
||||
self.assertEqual(classical, 10)
|
||||
|
||||
def test_each_element_has_count_key(self):
|
||||
data = self._get({'dt': J2000, **LONDON}).json()
|
||||
for key in ('Fire', 'Water', 'Earth', 'Air', 'Time', 'Space'):
|
||||
with self.subTest(element=key):
|
||||
self.assertIn('count', data['elements'][key])
|
||||
|
||||
def test_classic_elements_have_contributors(self):
|
||||
data = self._get({'dt': J2000, **LONDON}).json()
|
||||
for key in ('Fire', 'Water', 'Earth', 'Air'):
|
||||
with self.subTest(element=key):
|
||||
self.assertIn('contributors', data['elements'][key])
|
||||
|
||||
def test_time_has_stellia(self):
|
||||
data = self._get({'dt': J2000, **LONDON}).json()
|
||||
self.assertIn('stellia', data['elements']['Time'])
|
||||
|
||||
def test_space_has_parades(self):
|
||||
data = self._get({'dt': J2000, **LONDON}).json()
|
||||
self.assertIn('parades', data['elements']['Space'])
|
||||
|
||||
def test_each_planet_has_speed(self):
|
||||
data = self._get({'dt': J2000, **LONDON}).json()
|
||||
for name, planet in data['planets'].items():
|
||||
with self.subTest(planet=name):
|
||||
self.assertIn('speed', planet)
|
||||
|
||||
def test_each_aspect_has_applying_planet(self):
|
||||
data = self._get({'dt': J2000, **LONDON}).json()
|
||||
for aspect in data['aspects']:
|
||||
with self.subTest(aspect=aspect):
|
||||
self.assertIn('applying_planet', aspect)
|
||||
|
||||
# ── house system ──────────────────────────────────────────────────────
|
||||
|
||||
def test_default_house_system_is_porphyry(self):
|
||||
|
||||
Reference in New Issue
Block a user