archive_data = <swh.web.tests.conftest._ArchiveData object at 0x7fdbe4be9c18>
client = <django.test.client.Client object at 0x7fdbe1baf7b8>
@given(origin())
> def test_legacy_swhid_browse(archive_data, client, origin):
.tox/py3/lib/python3.7/site-packages/swh/web/tests/browse/views/test_identifiers.py:161:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
.tox/py3/lib/python3.7/site-packages/swh/web/tests/browse/views/test_identifiers.py:179: in test_legacy_swhid_browse
client, resp["location"], status_code=200, template_used="browse/content.html"
.tox/py3/lib/python3.7/site-packages/swh/web/tests/utils.py:205: in check_html_get_response
client, url, status_code, content_type="text/html"
.tox/py3/lib/python3.7/site-packages/swh/web/tests/utils.py:66: in check_http_get_response
content_type=content_type,
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
response = <HttpResponse status_code=500, "text/html; charset=utf-8">
status_code = 200, content_type = 'text/html'
def _assert_http_response(
response: HttpResponse, status_code: int, content_type: str
) -> HttpResponse:
if isinstance(response, Response):
drf_response = cast(Response, response)
error_context = (
drf_response.data.pop("traceback")
if isinstance(drf_response.data, dict) and "traceback" in drf_response.data
else drf_response.data
)
elif isinstance(response, StreamingHttpResponse):
error_context = getattr(response, "traceback", response.streaming_content)
else:
error_context = getattr(response, "traceback", response.content)
> assert response.status_code == status_code, error_context
E AssertionError: Traceback (most recent call last):
E File "/var/lib/jenkins/workspace/DWAPPS/tests-on-diff/.tox/py3/lib/python3.7/site-packages/django/core/handlers/base.py", line 113, in _get_response
E response = wrapped_callback(request, *callback_args, **callback_kwargs)
E File "/var/lib/jenkins/workspace/DWAPPS/tests-on-diff/.tox/py3/lib/python3.7/site-packages/swh/web/browse/views/content.py", line 212, in content_display
E browse_context=ObjectType.CONTENT,
E File "/var/lib/jenkins/workspace/DWAPPS/tests-on-diff/.tox/py3/lib/python3.7/site-packages/swh/web/browse/snapshot_context.py", line 583, in get_snapshot_context
E browse_view_name, url_args=url_args, query_params=branch_query_params
E File "/var/lib/jenkins/workspace/DWAPPS/tests-on-diff/.tox/py3/lib/python3.7/site-packages/swh/web/common/utils.py", line 74, in reverse
E viewname, urlconf=urlconf, kwargs=url_args, current_app=current_app
E File "/var/lib/jenkins/workspace/DWAPPS/tests-on-diff/.tox/py3/lib/python3.7/site-packages/django/urls/base.py", line 90, in reverse
E return iri_to_uri(resolver._reverse_with_prefix(view, prefix, *args, **kwargs))
E File "/var/lib/jenkins/workspace/DWAPPS/tests-on-diff/.tox/py3/lib/python3.7/site-packages/django/urls/resolvers.py", line 673, in _reverse_with_prefix
E raise NoReverseMatch(msg)
E django.urls.exceptions.NoReverseMatch: Reverse for 'browse-origin-ObjectType.CONTENT' not found. 'browse-origin-ObjectType.CONTENT' is not a valid view function or pattern name.
E
E assert 500 == 200
E +500
E -200
.tox/py3/lib/python3.7/site-packages/swh/web/tests/utils.py:32: AssertionError
TEST RESULT
TEST RESULT
- Run At
- Mar 3 2021, 10:02 AM