SCSS refactor, theme cleanup

This commit is contained in:
Alex Janousek
2025-11-05 09:24:31 -05:00
parent 1566c70027
commit 937417480e
33 changed files with 269 additions and 223 deletions

View File

@@ -171,7 +171,7 @@ def test_choose_account_should_show_choose_accounts_page_if_no_services(
assert len(links) == 1
add_service_link = links[0]
assert normalize_spaces(page.h1.text) == "Choose service"
assert normalize_spaces(add_service_link.text) == "Add a new service"
assert normalize_spaces(add_service_link.text) == "Add service"
assert not page.select("main h2")
assert add_service_link["href"] == url_for("main.add_service")

View File

@@ -1585,9 +1585,24 @@ def test_organization_dashboard_shows_service_counts(
"app.organizations_client.get_organization_dashboard",
return_value={
"services": [
{"service_id": "1", "service_name": "Live Service", "active": True, "restricted": False},
{"service_id": "2", "service_name": "Trial Service", "active": True, "restricted": True},
{"service_id": "3", "service_name": "Suspended", "active": False, "restricted": False},
{
"service_id": "1",
"service_name": "Live Service",
"active": True,
"restricted": False,
},
{
"service_id": "2",
"service_name": "Trial Service",
"active": True,
"restricted": True,
},
{
"service_id": "3",
"service_name": "Suspended",
"active": False,
"restricted": False,
},
]
},
)
@@ -1615,11 +1630,17 @@ def test_organization_dashboard_services_table(
mocker,
active_user_with_permissions,
):
mocker.patch.dict("flask.current_app.config", {"ORGANIZATION_DASHBOARD_ENABLED": True})
mocker.patch.dict(
"flask.current_app.config", {"ORGANIZATION_DASHBOARD_ENABLED": True}
)
mocker.patch(
"app.organizations_client.get_organization_message_usage",
return_value={"messages_sent": 0, "messages_remaining": 0, "total_message_limit": 0},
return_value={
"messages_sent": 0,
"messages_remaining": 0,
"total_message_limit": 0,
},
)
mocker.patch(
"app.organizations_client.get_organization_services",

View File

@@ -17,7 +17,7 @@ def test_non_gov_user_cannot_see_add_service_button(
):
client_request.login(api_nongov_user_active)
page = client_request.get("main.choose_account")
assert "Add a new service" not in page.text
assert "Add service" not in page.text
@pytest.mark.parametrize(

View File

@@ -108,7 +108,7 @@ def e2e_created_service(e2e_test_service): # noqa: PT022
page.goto(f"{E2E_TEST_URI}/accounts")
page.wait_for_load_state("domcontentloaded")
add_service_button = page.get_by_role("button", name="Add a new service")
add_service_button = page.get_by_role("button", name="Add service")
add_service_button.click()
page.wait_for_load_state("domcontentloaded")

View File

@@ -29,9 +29,7 @@ def test_add_new_service_workflow(e2e_test_service):
expect(sign_in_heading).to_be_visible()
# Retrieve some prominent elements on the page for testing.
add_service_button = page.get_by_role(
"button", name=re.compile("Add a new service")
)
add_service_button = page.get_by_role("button", name=re.compile("Add service"))
expect(add_service_button).to_be_visible()

View File

@@ -119,9 +119,7 @@ def test_create_new_template(end_to_end_context):
expect(sign_in_heading).to_be_visible()
# Retrieve some prominent elements on the page for testing.
add_service_button = page.get_by_role(
"button", name=re.compile("Add a new service")
)
add_service_button = page.get_by_role("button", name=re.compile("Add service"))
expect(add_service_button).to_be_visible()

View File

@@ -32,9 +32,7 @@ def _setup(page):
expect(sign_in_heading).to_be_visible()
# Retrieve some prominent elements on the page for testing.
add_service_button = page.get_by_role(
"button", name=re.compile("Add a new service")
)
add_service_button = page.get_by_role("button", name=re.compile("Add service"))
expect(add_service_button).to_be_visible()

View File

@@ -34,9 +34,7 @@ def _setup(page):
expect(sign_in_heading).to_be_visible()
# Retrieve some prominent elements on the page for testing.
add_service_button = page.get_by_role(
"button", name=re.compile("Add a new service")
)
add_service_button = page.get_by_role("button", name=re.compile("Add service"))
expect(add_service_button).to_be_visible()