Home / Function/ test_fragment_maintained_on_redirect() — requests Function Reference

test_fragment_maintained_on_redirect() — requests Function Reference

Architecture documentation for the test_fragment_maintained_on_redirect() function in test_requests.py from the requests codebase.

Entity Profile

Dependency Diagram

graph TD
  578475a5_711f_bbfa_1257_daf107cfe137["test_fragment_maintained_on_redirect()"]
  22b80b19_26d4_cd0e_c476_3edf87b3df14["TestRequests"]
  578475a5_711f_bbfa_1257_daf107cfe137 -->|defined in| 22b80b19_26d4_cd0e_c476_3edf87b3df14
  style 578475a5_711f_bbfa_1257_daf107cfe137 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

tests/test_requests.py lines 352–358

    def test_fragment_maintained_on_redirect(self, httpbin):
        fragment = "#view=edit&token=hunter2"
        r = requests.get(httpbin("redirect-to?url=get") + fragment)

        assert len(r.history) > 0
        assert r.history[0].request.url == httpbin("redirect-to?url=get") + fragment
        assert r.url == httpbin("get") + fragment

Domain

Subdomains

Frequently Asked Questions

What does test_fragment_maintained_on_redirect() do?
test_fragment_maintained_on_redirect() is a function in the requests codebase, defined in tests/test_requests.py.
Where is test_fragment_maintained_on_redirect() defined?
test_fragment_maintained_on_redirect() is defined in tests/test_requests.py at line 352.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free