mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-07-23 11:16:07 +02:00
Fix test cases broken by recent merge
This commit is contained in:
parent
63a58ae182
commit
724b549d70
1 changed files with 8 additions and 18 deletions
|
@ -15,15 +15,7 @@ from registrar.admin import (
|
|||
ContactAdmin,
|
||||
UserDomainRoleAdmin,
|
||||
)
|
||||
from registrar.models import (
|
||||
Domain,
|
||||
DomainApplication,
|
||||
DomainInformation,
|
||||
User,
|
||||
DomainInvitation,
|
||||
Contact,
|
||||
Website
|
||||
)
|
||||
from registrar.models import Domain, DomainApplication, DomainInformation, User, DomainInvitation, Contact, Website
|
||||
from registrar.models.user_domain_role import UserDomainRole
|
||||
from .common import (
|
||||
completed_application,
|
||||
|
@ -844,7 +836,6 @@ class TestDomainApplicationAdmin(MockEppLib):
|
|||
# Assert that DomainInformation got Deleted
|
||||
with self.assertRaises(DomainInformation.DoesNotExist):
|
||||
domain_information.refresh_from_db()
|
||||
|
||||
|
||||
def test_has_correct_filters(self):
|
||||
"""Tests if DomainApplicationAdmin has the correct filters"""
|
||||
|
@ -908,7 +899,7 @@ class TestDomainApplicationAdmin(MockEppLib):
|
|||
[
|
||||
{
|
||||
"parameter_name": "investigator",
|
||||
"parameter_value": "SomeGuy first_name:investigator SomeGuy last_name:investigator",
|
||||
"parameter_value": "SomeGuy first_name:creator SomeGuy last_name:creator",
|
||||
},
|
||||
],
|
||||
)
|
||||
|
@ -938,15 +929,14 @@ class TestDomainApplicationAdmin(MockEppLib):
|
|||
follow=True,
|
||||
)
|
||||
|
||||
expected_name = "SomeGuy first_name:investigator SomeGuy last_name:investigator"
|
||||
# We expect to see this four times, two of them are from the html for the filter,
|
||||
# the other two are the html from the list entry in the table.
|
||||
self.assertContains(response, expected_name, count=4)
|
||||
expected_name = "SomeGuy first_name:creator SomeGuy last_name:creator"
|
||||
# We expect to see this six times, two of them are from the html for the filter,
|
||||
# two are from the page content, and the other two are the html from the list entry in the table.
|
||||
self.assertContains(response, expected_name, count=6)
|
||||
|
||||
# Check that we don't also get the thing we aren't filtering for.
|
||||
# We expect to see this two times, two of them are from the html for the filter.
|
||||
unexpected_name = "BadGuy first_name:investigator BadGuy last_name:investigator"
|
||||
self.assertContains(response, unexpected_name, count=2)
|
||||
unexpected_name = "BadGuy first_name:creator BadGuy last_name:creator"
|
||||
self.assertContains(response, unexpected_name, count=0)
|
||||
|
||||
def tearDown(self):
|
||||
super().tearDown()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue