Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
farridav committed Oct 8, 2024
1 parent 097720d commit 109ed08
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions tests/test_admin_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -208,10 +208,10 @@ def test_detail(admin_client):
"admin/widgets/foreign_key_raw_id.html": 1,
"admin/widgets/related_widget_wrapper.html": 4,
"admin/widgets/split_datetime.html": 2,
"django/forms/widgets/attrs.html": 47,
"django/forms/widgets/attrs.html": 47 if django.VERSION < (5, 0, 0) else 49,
"django/forms/widgets/date.html": 5,
"django/forms/widgets/hidden.html": 6,
"django/forms/widgets/input.html": 19,
"django/forms/widgets/hidden.html": 6 if django.VERSION < (5, 0, 0) else 8,
"django/forms/widgets/input.html": 19 if django.VERSION < (5, 0, 0) else 21,
"django/forms/widgets/number.html": 1,
"django/forms/widgets/select.html": 6,
"django/forms/widgets/select_option.html": 21,
Expand Down
2 changes: 1 addition & 1 deletion tests/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def parse_topmenu(response):
anchor = li.find("a")

# Skip brand link and menu button
if type(anchor.contents[0]) == Tag:
if isinstance(anchor.contents[0], Tag):
continue

item = {"name": anchor.text.strip(), "link": anchor["href"]}
Expand Down

0 comments on commit 109ed08

Please sign in to comment.