============================= test session starts ==============================
platform linux -- Python 3.12.3, pytest-9.1.1, pluggy-1.6.0 -- /venv/bin/python3
cachedir: .pytest_cache
rootdir: /builds/keystone/python/pjdev-feedback
configfile: pyproject.toml
plugins: anyio-4.15.0
collecting ... collected 77 items

tests/test_feedback.py::test_mode_a_without_require_user_refuses_to_mount PASSED [  1%]
tests/test_feedback.py::test_mode_a_unauthenticated_user_returns_401 PASSED [  2%]
tests/test_feedback.py::test_missing_project_token_returns_503 PASSED    [  3%]
tests/test_feedback.py::test_bad_cid_map_returns_400 PASSED              [  5%]
tests/test_feedback.py::test_non_string_cid_map_value_returns_400 PASSED [  6%]
tests/test_feedback.py::test_request_type_is_off_by_default PASSED       [  7%]
tests/test_feedback.py::test_missing_request_type_returns_400_once_configured PASSED [  9%]
tests/test_feedback.py::test_unknown_request_type_returns_400 PASSED     [ 10%]
tests/test_feedback.py::test_each_default_request_type_labels_and_heads_the_issue[bug-request::bug-Something isn't working] PASSED [ 11%]
tests/test_feedback.py::test_each_default_request_type_labels_and_heads_the_issue[how-to-request::how-to-I need help using the app] PASSED [ 12%]
tests/test_feedback.py::test_each_default_request_type_labels_and_heads_the_issue[access-request::access-I need access to a system] PASSED [ 14%]
tests/test_feedback.py::test_each_default_request_type_labels_and_heads_the_issue[idea-request::idea-I have an idea or suggestion] PASSED [ 15%]
tests/test_feedback.py::test_custom_request_types_replace_the_defaults PASSED [ 16%]
tests/test_feedback.py::test_request_type_can_be_offered_without_being_required PASSED [ 18%]
tests/test_feedback.py::test_duplicate_request_type_values_refuse_to_mount PASSED [ 19%]
tests/test_feedback.py::test_request_type_label_is_not_duplicated PASSED [ 20%]
tests/test_feedback.py::test_request_type_heading_precedes_an_escaped_body PASSED [ 22%]
tests/test_feedback.py::test_too_many_files_returns_400 PASSED           [ 23%]
tests/test_feedback.py::test_total_bytes_cap_returns_413 PASSED          [ 24%]
tests/test_feedback.py::test_gitlab_413_passthrough PASSED               [ 25%]
tests/test_feedback.py::test_non_413_gitlab_errors_map_to_502[401] PASSED [ 27%]
tests/test_feedback.py::test_non_413_gitlab_errors_map_to_502[403] PASSED [ 28%]
tests/test_feedback.py::test_non_413_gitlab_errors_map_to_502[404] PASSED [ 29%]
tests/test_feedback.py::test_non_413_gitlab_errors_map_to_502[500] PASSED [ 31%]
tests/test_feedback.py::test_http_error_message_wording[401-GitLab rejected the request (401)] PASSED [ 32%]
tests/test_feedback.py::test_http_error_message_wording[403-GitLab rejected the request (403)] PASSED [ 33%]
tests/test_feedback.py::test_http_error_message_wording[404-GitLab project not found] PASSED [ 35%]
tests/test_feedback.py::test_http_error_message_wording[413-too large] PASSED [ 36%]
tests/test_feedback.py::test_http_error_message_wording[500-GitLab returned 500] PASSED [ 37%]
tests/test_feedback.py::test_happy_path_substitutes_cid PASSED           [ 38%]
tests/test_feedback.py::test_duplicate_display_filenames_upload_distinct_content PASSED [ 40%]
tests/test_feedback.py::test_mode_b_injects_bearer_client PASSED         [ 41%]
tests/test_feedback.py::test_mode_b_unresolved_token_returns_401 PASSED  [ 42%]
tests/test_feedback.py::test_turnkey_oauth_full_flow PASSED              [ 44%]
tests/test_feedback.py::test_cross_site_requests_rejected PASSED         [ 45%]
tests/test_feedback.py::test_app_csrf_dependency_is_enforced PASSED      [ 46%]
tests/test_feedback.py::test_turnkey_oauth_callback_bad_state_returns_400 PASSED [ 48%]
tests/test_feedback.py::test_mounting_initializes_the_gitlab_sdk_global PASSED [ 49%]
tests/test_feedback.py::test_existing_sdk_config_is_not_clobbered PASSED [ 50%]
tests/test_feedback.py::test_reporter_footer_falls_back_to_username PASSED [ 51%]
tests/test_feedback.py::test_display_name_still_wins_over_username PASSED [ 53%]
tests/test_feedback.py::test_reporter_identity_cannot_inject_markdown PASSED [ 54%]
tests/test_feedback.py::test_ordinary_identities_are_left_readable PASSED [ 55%]
tests/test_feedback.py::test_escape_quick_actions[/close-\\/close] PASSED [ 57%]
tests/test_feedback.py::test_escape_quick_actions[/confidential-\\/confidential] PASSED [ 58%]
tests/test_feedback.py::test_escape_quick_actions[/move group/other-\\/move group/other] PASSED [ 59%]
tests/test_feedback.py::test_escape_quick_actions[/create_merge_request evil-branch-\\/create_merge_request evil-branch] PASSED [ 61%]
tests/test_feedback.py::test_escape_quick_actions[Search is broken.\n/close\nThanks!-Search is broken.\n\\/close\nThanks!] PASSED [ 62%]
tests/test_feedback.py::test_escape_quick_actions[Broken.\r\n/close\r\n-Broken.\r\n\\/close\r\n] PASSED [ 63%]
tests/test_feedback.py::test_escape_quick_actions[  /close-  /close] PASSED [ 64%]
tests/test_feedback.py::test_escape_quick_actions[see /docs/setup for repro-see /docs/setup for repro] PASSED [ 66%]
tests/test_feedback.py::test_escape_quick_actions[/ 2 of the pages-/ 2 of the pages] PASSED [ 67%]
tests/test_feedback.py::test_escape_quick_actions[-] PASSED              [ 68%]
tests/test_feedback.py::test_escape_quick_actions_leaves_fenced_code_alone PASSED [ 70%]
tests/test_feedback.py::test_quick_actions_in_description_are_neutralized PASSED [ 71%]
tests/test_feedback.py::test_app_version_is_recorded_in_the_footer PASSED [ 72%]
tests/test_feedback.py::test_app_version_is_recorded_without_a_reporter PASSED [ 74%]
tests/test_feedback.py::test_no_footer_at_all_when_there_is_nothing_to_say PASSED [ 75%]
tests/test_feedback.py::test_page_url_is_ignored_unless_the_app_asks_for_it PASSED [ 76%]
tests/test_feedback.py::test_page_url_lands_in_the_footer_when_enabled PASSED [ 77%]
tests/test_feedback.py::test_hostile_page_urls_are_dropped[javascript:alert(document.cookie)] PASSED [ 79%]
tests/test_feedback.py::test_hostile_page_urls_are_dropped[JavaScript:alert(1)] PASSED [ 80%]
tests/test_feedback.py::test_hostile_page_urls_are_dropped[data:text/html;base64,PHNjcmlwdD4=] PASSED [ 81%]
tests/test_feedback.py::test_hostile_page_urls_are_dropped[not a url] PASSED [ 83%]
tests/test_feedback.py::test_hostile_page_urls_are_dropped[] PASSED      [ 84%]
tests/test_feedback.py::test_hostile_page_urls_are_dropped[https://app.example.com/>](http://evil.test)] PASSED [ 85%]
tests/test_feedback.py::test_hostile_page_urls_are_dropped[https://app.example.com/<script>] PASSED [ 87%]
tests/test_feedback.py::test_hostile_page_urls_are_dropped[https://app.example.com/`x`] PASSED [ 88%]
tests/test_feedback.py::test_page_url_cannot_inject_markdown_lines PASSED [ 89%]
tests/test_feedback.py::test_an_over_long_page_url_is_refused_by_the_form_field PASSED [ 90%]
tests/test_feedback.py::test_a_sha_like_version_is_not_left_for_gitlab_to_autolink PASSED [ 92%]
tests/test_feedback.py::test_append_footer_shapes[None-None-Body] PASSED [ 93%]
tests/test_feedback.py::test_append_footer_shapes[None-2.0.6-Body\n\n---\nApp version: `2.0.6`\n] PASSED [ 94%]
tests/test_feedback.py::test_append_footer_shapes[None--Body] PASSED     [ 96%]
tests/test_feedback.py::test_reporter_footer_cannot_be_escaped_into_a_command PASSED [ 97%]
tests/test_feedback.py::test_misconfiguration_message_names_the_missing_field[overrides0-project_token-project_id] PASSED [ 98%]
tests/test_feedback.py::test_misconfiguration_message_names_the_missing_field[overrides1-project_id-project_token] PASSED [100%]

=============================== warnings summary ===============================
tests/test_feedback.py::test_total_bytes_cap_returns_413
tests/test_feedback.py::test_gitlab_413_passthrough
  /venv/lib/python3.12/site-packages/fastapi/routing.py:352: StarletteDeprecationWarning: 'HTTP_413_REQUEST_ENTITY_TOO_LARGE' is deprecated. Use 'HTTP_413_CONTENT_TOO_LARGE' instead.
    return await dependant.call(**values)

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
======================== 77 passed, 2 warnings in 1.24s ========================
