File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -44,12 +44,10 @@ Use ``""`` instead of ``''`` in expression when running this on Windows
44
44
45
45
.. _nodeids :
46
46
47
- **Run tests by node ids **
47
+ **Run tests by collection arguments **
48
48
49
- Each collected test is assigned a unique ``nodeid `` which consist of the module file path followed
50
- by specifiers like class names and function names separated by ``:: `` characters,
51
- and parameters from parametrization in ``[...] ``.
52
- You can use the same syntax to match tests relative to the working directory.
49
+ Pass the module filename relative to the working directory, followed by specifiers like the class name and function name
50
+ separated by ``:: `` characters, and parameters from parameterization enclosed in ``[] ``.
53
51
54
52
To run a specific test within a module:
55
53
@@ -69,6 +67,12 @@ Specifying a specific test method:
69
67
70
68
pytest tests/test_mod.py::TestClass::test_method
71
69
70
+ Specifying a specific parametrization of a test:
71
+
72
+ .. code-block :: bash
73
+
74
+ pytest tests/test_mod.py::test_func[x1,y2]
75
+
72
76
**Run tests by marker expressions **
73
77
74
78
.. code-block :: bash
You can’t perform that action at this time.
0 commit comments