You are viewing an older version (2.4.3). Go to latest (2.4.4)
{ } Raw JSON

bundles / numpy 2.4.3 / numpy / _pytesttester / PytestTester / __call__

function

numpy._pytesttester:PytestTester.__call__

source: /numpy/_pytesttester.py :79

Signature

def   __call__ ( self label = fast verbose = 1 extra_argv = None doctests = False coverage = False durations = -1 tests = None )

Summary

Run tests for module using pytest.

Parameters

label : {'fast', 'full'}, optional

Identifies the tests to run. When set to 'fast', tests decorated with pytest.mark.slow are skipped, when 'full', the slow marker is ignored.

verbose : int, optional

Verbosity value for test outputs, in the range 1-3. Default is 1.

extra_argv : list, optional

List with any extra arguments to pass to pytests.

doctests : bool, optional
coverage : bool, optional

If True, report coverage of NumPy code. Default is False. Requires installation of (pip) pytest-cov.

durations : int, optional

If < 0, do nothing, If 0, report time of all tests, if > 0, report the time of the slowest timer tests. Default is -1.

tests : test or list of tests

Tests to be executed with pytest '--pyargs'

Returns

result : bool

Return True on success, false otherwise.

Notes

Each NumPy module exposes test in its namespace to run all tests for it. For example, to run all tests for numpy.lib:

>>> np.lib.test() #doctest: +SKIP

Examples

result = np.lib.test() #doctest: +SKIP
result

Aliases

  • numpy._pytesttester.PytestTester.__call__