test_hooks.py — requests Source File
Architecture documentation for test_hooks.py, a python file in the requests codebase. 2 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 1d2ba420_9232_b5f4_05b0_bf9869bb65d0["test_hooks.py"] b820826b_04e7_9e1b_bbf6_b336eaff9a23["pytest"] 1d2ba420_9232_b5f4_05b0_bf9869bb65d0 --> b820826b_04e7_9e1b_bbf6_b336eaff9a23 ce06e854_c78b_b510_291a_dbc144a59aff["requests"] 1d2ba420_9232_b5f4_05b0_bf9869bb65d0 --> ce06e854_c78b_b510_291a_dbc144a59aff style 1d2ba420_9232_b5f4_05b0_bf9869bb65d0 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import pytest
from requests import hooks
def hook(value):
return value[1:]
@pytest.mark.parametrize(
"hooks_list, result",
(
(hook, "ata"),
([hook, lambda x: None, hook], "ta"),
),
)
def test_hooks(hooks_list, result):
assert hooks.dispatch_hook("response", {"response": hooks_list}, "Data") == result
def test_default_hooks():
assert hooks.default_hooks() == {"response": []}
Domain
Subdomains
Functions
Dependencies
- pytest
- requests
Source
Frequently Asked Questions
What does test_hooks.py do?
test_hooks.py is a source file in the requests codebase, written in python. It belongs to the CoreAPI domain, VerbHandlers subdomain.
What functions are defined in test_hooks.py?
test_hooks.py defines 3 function(s): hook, test_default_hooks, test_hooks.
What does test_hooks.py depend on?
test_hooks.py imports 2 module(s): pytest, requests.
Where is test_hooks.py in the architecture?
test_hooks.py is located at tests/test_hooks.py (domain: CoreAPI, subdomain: VerbHandlers, directory: tests).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free