Skip to content

Commit

Permalink
Add test that resource list does not server error (#15635)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlanCoding authored Nov 15, 2024
1 parent 5448757 commit 3dbcfb1
Showing 1 changed file with 15 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import pytest

from ansible_base.lib.utils.response import get_relative_url


@pytest.mark.django_db
def test_users_in_resource_list(admin_user, rando, get):
url = get_relative_url("resource-list")
get(url=url, expect=200, user=admin_user)


@pytest.mark.django_db
def test_user_resource_detail(admin_user, rando, get):
url = get_relative_url("resource-detail", kwargs={'ansible_id': str(rando.resource.ansible_id)})
get(url=url, expect=200, user=admin_user)

0 comments on commit 3dbcfb1

Please sign in to comment.