fix(identity): validate persistent character pairs
This commit is contained in:
1 parent
0aec421ad2
commit
6af34d4706
8 files changed
+44
-1
No files matched your search
@@ -93,6 +93,11 @@ class ApiTests(unittest.TestCase):
|
||||
self.assertEqual(response["status"], "provided")
|
||||
self.assertIsNone(directory.resolve(character_id=1617140))
|
||||
|
||||
def test_identity_lookup_rejects_boolean_and_non_positive_ids(self):
|
||||
for character_id in (True, 0, -1):
|
||||
with self.subTest(character_id=character_id), self.assertRaises(ApiError):
|
||||
resolve_identity_payload({"character_id": character_id})
|
||||
|
||||
def test_calculation_store_persists_full_record(self):
|
||||
with TemporaryDirectory() as directory:
|
||||
path = f"{directory}/history.sqlite3"
|
||||
|
||||
Reference in new issue
Block a user