Skip to content
Discussion options

You must be logged in to vote

You might want to read more about parametrizing test functions in order to understand that example.

Based on that, imagine a test_mod.py like

import pytest

@pytest.mark.parametrize("a, b", [("x1", "y2"), ("v3", "w4")])
def test_func(a, b):
    ...

which will result in two test cases:

test_mod.py::test_func[x1-y2]
test_mod.py::test_func[v3-w4]

and the shown invocation will run the first one only.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by 1p1e3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants