Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/pytest-dev/pytest
/ functions
Functions
4,602 in github.com/pytest-dev/pytest
⨍
Functions
4,602
◇
Types & classes
572
↳
Endpoints
16
Method
pytest_runtest_setup
(self, item: Item)
src/_pytest/capture.py:779
Function
pytest_runtest_teardown
()
src/_pytest/unraisableexception.py:92
Function
pytest_runtest_teardown
Called to perform the teardown phase for a test item. The default implementation runs the finalizers and calls ``teardown()`` on ``item`` and
src/_pytest/hookspec.py:506
Function
pytest_runtest_teardown
(item: Item, nextitem: Optional[Item])
src/_pytest/runner.py:179
Function
pytest_runtest_teardown
()
src/_pytest/threadexception.py:87
Method
pytest_runtest_teardown
(self, item: nodes.Item)
src/_pytest/logging.py:727
Method
pytest_runtest_teardown
(self, item: Item)
src/_pytest/capture.py:789
Function
pytest_runtestloop
Perform the main runtest loop (after collection finished). The default hook implementation performs the runtest protocol for all items collec
src/_pytest/hookspec.py:407
Function
pytest_runtestloop
(session: "Session")
src/_pytest/main.py:335
Function
pytest_sessionfinish
Called after whole test run finished, right before returning the exit status to the system. :param pytest.Session session: The pytest session obj
src/_pytest/hookspec.py:606
Function
pytest_sessionfinish
(session: "Session")
src/_pytest/runner.py:106
Function
pytest_sessionfinish
(session: Session)
src/_pytest/warnings.py:126
Function
pytest_sessionfinish
(session: Session)
src/_pytest/stepwise.py:48
Function
pytest_sessionfinish
(session: "Session")
src/_pytest/assertion/__init__.py:171
Method
pytest_sessionfinish
(self)
src/_pytest/logging.py:739
Method
pytest_sessionfinish
(self, session: Session)
src/_pytest/cacheprovider.py:379
Method
pytest_sessionfinish
(self)
src/_pytest/cacheprovider.py:424
Method
pytest_sessionfinish
( self, session: "Session", exitstatus: Union[int, ExitCode] )
src/_pytest/terminal.py:788
Method
pytest_sessionfinish
(self)
src/_pytest/stepwise.py:121
Function
pytest_sessionstart
Called after the ``Session`` object has been created and before performing collection and entering the run test loop. :param pytest.Session s
src/_pytest/hookspec.py:598
Function
pytest_sessionstart
(session: "Session")
src/_pytest/runner.py:102
Function
pytest_sessionstart
(session: "Session")
src/_pytest/fixtures.py:113
Method
pytest_sessionstart
(self)
src/_pytest/logging.py:655
Method
pytest_sessionstart
(self, session: "Session")
src/_pytest/terminal.py:681
Method
pytest_sessionstart
(self, session: Session)
src/_pytest/stepwise.py:65
Function
pytest_terminal_summary
(terminalreporter: TerminalReporter)
src/_pytest/pastebin.py:94
Function
pytest_terminal_summary
Add a section to terminal summary reporting. :param _pytest.terminal.TerminalReporter terminalreporter: The internal terminal reporter object.
src/_pytest/hookspec.py:764
Function
pytest_terminal_summary
(terminalreporter: "TerminalReporter")
src/_pytest/runner.py:70
Function
pytest_terminal_summary
( terminalreporter: TerminalReporter, )
src/_pytest/warnings.py:115
Method
pytest_terminal_summary
(self, terminalreporter: TerminalReporter)
src/_pytest/junitxml.py:681
Function
pytest_unconfigure
(config: Config)
src/_pytest/junitxml.py:443
Function
pytest_unconfigure
(config: Config)
src/_pytest/pastebin.py:52
Function
pytest_unconfigure
Called before test process is exited. :param pytest.Config config: The pytest config object.
src/_pytest/hookspec.py:617
Function
pytest_unconfigure
()
src/_pytest/doctest.py:116
Function
pytest_unconfigure
(config: Config)
src/_pytest/pythonpath.py:20
Function
pytest_unconfigure
(config: Config)
src/_pytest/faulthandler.py:35
Function
pytest_unconfigure
(config: Config)
src/_pytest/mark/__init__.py:281
Function
pytest_unconfigure
(config)
testing/example_scripts/conftest_usageerror/conftest.py:7
Method
pytest_unconfigure
(self)
src/_pytest/terminal.py:828
Method
pytest_unconfigure
(self)
testing/test_pythonpath.py:98
Function
pytest_warning_captured
(**Deprecated**) Process a warning captured by the internal pytest warnings plugin. .. deprecated:: 6.0 This hook is considered deprecated a
src/_pytest/hookspec.py:781
Function
pytest_warning_recorded
Process a warning captured by the internal pytest warnings plugin. :param warnings.WarningMessage warning_message: The captured warning.
src/_pytest/hookspec.py:816
Method
pytest_warning_recorded
( self, warning_message: warnings.WarningMessage, nodeid: str, )
src/_pytest/terminal.py:470
Method
pytest_warning_recorded
(self, warning_message, when, nodeid, location)
testing/test_warnings.py:270
Method
pytest_warning_recorded
(cls, warning_message, when, nodeid, location)
testing/test_warnings.py:665
Function
pytest_xyz
X
testing/test_pytester.py:179
Function
pytest_xyz_noarg
X
testing/test_pytester.py:182
Function
pytestconfig
Session-scoped fixture that returns the session's :class:`pytest.Config` object. Example:: def test_foo(pytestconfig): i
src/_pytest/fixtures.py:1365
Function
pytester
Facilities to write tests/configuration files, execute pytest in isolation, and match against expected output, perfect for black-box testing
src/_pytest/pytester.py:480
Function
pytester
(pytester: Pytester, monkeypatch: MonkeyPatch)
testing/conftest.py:134
Method
pytester
(self, pytester: Pytester)
testing/python/fixtures.py:1532
Method
pytester
(self, pytester: Pytester)
testing/python/fixtures.py:1762
Function
pytestpm
()
testing/test_pluginmanager.py:19
Function
python1
(request, tmp_path)
doc/en/example/multipython.py:15
Function
python2
(request, python1)
doc/en/example/multipython.py:21
Function
raise_assertion
()
testing/test_runner.py:492
Method
raise_baseexception
(self)
testing/test_compat.py:154
Method
raise_exception
(self)
testing/test_compat.py:158
Function
raise_exit
(obj)
testing/test_assertion.py:1653
Method
raise_fail_outcome
(self)
testing/test_compat.py:162
Method
raise_on_assertionpass
(*_, **__)
testing/test_assertrewrite.py:1549
Method
raise_oserror
(*args)
testing/test_assertrewrite.py:1067
Method
raiseos
()
testing/code/test_excinfo.py:810
Function
raises
()
testing/code/test_excinfo.py:339
Method
readouterr
Read and return the captured output so far, resetting the internal buffer. :returns: The captured content as a namedtuple
src/_pytest/capture.py:833
Function
record_func
No-op function in case --junitxml was not passed in the command-line.
src/_pytest/junitxml.py:368
Function
record_property
Add extra properties to the calling test. User properties become part of the test report and are available to the configured reporters, like
src/_pytest/junitxml.py:282
Function
record_testsuite_property
Record a new ``<property>`` tag as child of the root ``<testsuite>``. This is suitable to writing global information regarding the entire test
src/_pytest/junitxml.py:343
Method
record_tuples
A list of a stripped down version of log records intended for use in assertion comparison. The format of the tuple is: (
src/_pytest/logging.py:408
Function
record_xml_attribute
Add extra xml attributes to the tag for the calling test. The fixture is callable with ``name, value``. The value is automatically XML-encode
src/_pytest/junitxml.py:305
Method
records
The list of log records.
src/_pytest/logging.py:403
Function
recwarn
Return a :class:`WarningsRecorder` instance that records all warnings emitted by test functions. See https://docs.python.org/library/how-to/captu
src/_pytest/recwarn.py:29
Function
register_assert_rewrite
Register one or more module names to be rewritten on import. This function will make sure that this module or all modules inside the package
src/_pytest/assertion/__init__.py:47
Method
relline
(self)
src/_pytest/_code/code.py:218
Method
remove_prefixes
(regex: Pattern[str], txt: str)
src/_pytest/doctest.py:629
Function
renamed_failed
(*args)
testing/test_pathlib.py:344
Function
repl
(matchobj: Match[str])
src/_pytest/junitxml.py:51
Method
report_failure
( self, out, test: "doctest.DocTest", example: "doctest.Exampl
src/_pytest/doctest.py:196
Method
report_failure
(self, out, test, example, got)
testing/python/approx.py:37
Method
report_unexpected_exception
( self, out, test: "doctest.DocTest", example: "doctest.Exampl
src/_pytest/doctest.py:209
Method
reportinfo
(self)
src/_pytest/doctest.py:374
Method
reportinfo
(self)
src/_pytest/python.py:331
Method
reportinfo
(self)
doc/en/example/nonpython/conftest.py:42
Method
repr
(self, class_name: str)
src/_pytest/capture.py:244
Method
repr
Return a 'safe' (non-recursive, one-line) string repr for 'object'.
src/_pytest/_code/code.py:172
Method
repr_failure
( # type: ignore[override] self, excinfo: ExceptionInfo[BaseException], )
src/_pytest/doctest.py:310
Method
repr_failure
( # type: ignore[override] self, excinfo: ExceptionInfo[BaseException], )
src/_pytest/python.py:1745
Method
repr_failure
Return a representation of a collection failure. :param excinfo: Exception information for the failure.
src/_pytest/nodes.py:530
Method
repr_failure
Called when self.runtest() raises an exception.
doc/en/example/nonpython/conftest.py:31
Method
repr_instance
(self, x: object, level: int)
src/_pytest/_io/saferepr.py:69
Function
request
()
testing/example_scripts/fixtures/test_fixture_named_request.py:5
Method
request
(self)
src/_pytest/legacypath.py:68
Method
reraise_me
()
testing/code/test_excinfo.py:242
Method
reset
(self)
src/_pytest/logging.py:823
Method
reset
(self)
testing/test_debugging.py:50
Method
reset
(self)
testing/test_debugging.py:69
Method
reset
(self)
testing/python/approx.py:28
Method
response
(url, data)
testing/test_pastebin.py:178
Method
restore
(self)
testing/test_pytester.py:239
Function
restore_tracing
Restore tracing function (when run with Coverage.py). https://bugs.python.org/issue37011
testing/conftest.py:12
← previous
next →
1,901–2,000 of 4,602, ranked by callers