Changeset View
Changeset View
Standalone View
Standalone View
swh/web/tests/browse/views/test_content.py
| Show First 20 Lines • Show All 650 Lines • ▼ Show 20 Lines | def test_content_dispaly_empty_query_string_missing_path(client): | ||||
| assert_contains(resp, "The path query parameter must be provided.", status_code=400) | assert_contains(resp, "The path query parameter must be provided.", status_code=400) | ||||
| def test_content_dispaly_empty_query_string_and_snapshot_origin(client): | def test_content_dispaly_empty_query_string_and_snapshot_origin(client): | ||||
| url = reverse("browse-content", query_params={"path": "test.txt"},) | url = reverse("browse-content", query_params={"path": "test.txt"},) | ||||
| resp = check_html_get_response(client, url, status_code=400,) | resp = check_html_get_response(client, url, status_code=400,) | ||||
| assert_contains( | assert_contains( | ||||
| resp, | resp, | ||||
| "The origin_url or snapshot query parameters must be provided.", | "The origin_url or snapshot query parameter must be provided.", | ||||
| status_code=400, | status_code=400, | ||||
| ) | ) | ||||
| def test_content_dispaly_empty_query_string_with_origin( | def test_content_dispaly_empty_query_string_with_origin( | ||||
| client, archive_data, origin_with_multiple_visits | client, archive_data, origin_with_multiple_visits | ||||
| ): | ): | ||||
| origin_url = origin_with_multiple_visits["url"] | origin_url = origin_with_multiple_visits["url"] | ||||
| ▲ Show 20 Lines • Show All 407 Lines • Show Last 20 Lines | |||||