Skip to content

Commit

Permalink
fix testcases issue for djangocms-versioning 2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
FreemanPancake committed Apr 24, 2024
1 parent 4c7b7fb commit fcf8c83
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion tests/requirements/dj42_cms41.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
Django>=4.2,<5.0
django-cms>=4.1,<4.2

djangocms-versioning>=2.0.0
djangocms-versioning>=2.0.1
djangocms-alias>=2.0.0
2 changes: 1 addition & 1 deletion tests/requirements/dj50_cms41.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
Django>=5.0,<5.1
django-cms>=4.1,<4.2

djangocms-versioning>=2.0.0
djangocms-versioning>=2.0.1
djangocms-alias>=2.0.0
4 changes: 2 additions & 2 deletions tests/test_monkeypatch.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def test_get_edit_link(self, mock_is_obj_review_locked):
)
# We test that moderation check is called when getting an edit link
self.assertTrue(mock_is_obj_review_locked.called)
if versioning_version < "2":
if versioning_version != "2.0.0":
# Edit link is inactive as `mock_is_obj_review_locked` is True
self.assertIn("inactive", edit_link)
else:
Expand Down Expand Up @@ -92,7 +92,7 @@ def test_get_archive_link(self, _mock):
archive_link = ""
# We test that moderation check is called when getting an edit link
self.assertEqual(1, _mock.call_count)
if versioning_version < "2":
if versioning_version != "2.0.0":
# Edit link is inactive as `mock_is_obj_review_locked` is True
self.assertIn("inactive", archive_link)
else:
Expand Down

0 comments on commit fcf8c83

Please sign in to comment.