Skip to content

Commit

Permalink
fix unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
jnussbaum committed Oct 16, 2023
1 parent 68e5be5 commit 62658c5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/test_ap_serialization.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,9 @@ def test_serialize_aps_of_project(self):
)
with open(self.output_file, mode="r", encoding="utf-8") as f:
aps_file = json.load(f)
self.assertTrue("Project 1234 has 2 APs" in aps_file)
aps_as_dicts = aps_file["Project 1234 has 2 APs"]
explanation_text = list(aps_file.keys())[0]
self.assertRegex(explanation_text, r"Project 1234 on host .+ has \d+ APs")
aps_as_dicts = aps_file[explanation_text]
self.assertEqual(self.ap1, Ap.model_validate(aps_as_dicts[0]))
self.assertEqual(self.ap2, Ap.model_validate(aps_as_dicts[1]))

Expand Down

0 comments on commit 62658c5

Please sign in to comment.