From 5a7aa123ea29987287a4e01b8e61aacce282cd40 Mon Sep 17 00:00:00 2001 From: Bruno Oliveira Date: Wed, 22 Aug 2018 11:22:30 -0300 Subject: [PATCH] Improve docs formatting --- doc/en/example/pythoncollection.rst | 10 +++++----- doc/en/reference.rst | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/en/example/pythoncollection.rst b/doc/en/example/pythoncollection.rst index 6c86b8a63..b4950a75c 100644 --- a/doc/en/example/pythoncollection.rst +++ b/doc/en/example/pythoncollection.rst @@ -108,9 +108,9 @@ Here is an example:: # can also be defined in tox.ini or setup.cfg file, although the section # name in setup.cfg files should be "tool:pytest" [pytest] - python_files=check_*.py - python_classes=Check - python_functions=*_check + python_files = check_*.py + python_classes = Check + python_functions = *_check This would make ``pytest`` look for tests in files that match the ``check_* .py`` glob-pattern, ``Check`` prefixes in classes, and functions and methods @@ -144,13 +144,13 @@ You can check for multiple glob patterns by adding a space between the patterns: # content of pytest.ini, tox.ini, or setup.cfg file (replace "pytest" # with "tool:pytest" for setup.cfg) [pytest] - python_files=test_*.py example_*.py + python_files = test_*.py example_*.py .. note:: the ``python_functions`` and ``python_classes`` options has no effect for ``unittest.TestCase`` test discovery because pytest delegates - detection of test case methods to unittest code. + discovery of test case methods to unittest code. Interpreting cmdline arguments as Python packages ----------------------------------------------------- diff --git a/doc/en/reference.rst b/doc/en/reference.rst index 28fc6805a..042df9687 100644 --- a/doc/en/reference.rst +++ b/doc/en/reference.rst @@ -1255,7 +1255,7 @@ passed multiple times. The expected format is ``name=value``. For example:: [pytest] python_files = test_*.py check_*.py example_*.py - By default, pytest will consider any file matching with ``test_*.py`` + By default, pytest will consider any file matching with ``test_*.py`` and ``*_test.py`` globs as a test module.