Skip to content

Commit

Permalink
Fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
const-cloudinary committed Dec 22, 2024
1 parent c9b3f4d commit 950936f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -1087,8 +1087,9 @@ def test_upload_mapping(self):
result = api.upload_mapping(MAPPING_TEST_ID)
self.assertEqual(result["template"], "http://res.cloudinary.com")
result = api.upload_mappings()
self.assertIn({"folder": MAPPING_TEST_ID, "template": "http://res.cloudinary.com"},
result["mappings"])
self.assertTrue(any(
mapping.get("folder") == MAPPING_TEST_ID and mapping.get("template") == "http://res.cloudinary.com" for
mapping in result["mappings"]))
api.delete_upload_mapping(MAPPING_TEST_ID)
result = api.upload_mappings()
self.assertNotIn(MAPPING_TEST_ID, [mapping.get("folder") for mapping in result["mappings"]])
Expand Down

0 comments on commit 950936f

Please sign in to comment.