-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Closed
Labels
type: bugproblem that needs to be addressedproblem that needs to be addressedtype: regressionindicates a problem that was introduced in a release which was working previouslyindicates a problem that was introduced in a release which was working previously
Description
This issue might be more of a question, but I would like to be sure if this is expected behaviour.
Running the following test
import pytest
@pytest.mark.foo
def test_mark():
pass
with pytest >= 4.0 and -k foo
succeeds
$ pytest -k foo
================================= test session starts =================================
platform linux2 -- Python 2.7.15rc1, pytest-4.0.2, py-1.7.0, pluggy-0.8.1
rootdir: /home/.../pytest_mark_sample, inifile:
collected 1 item
test_mark.py . [100%]
============================== 1 passed in 0.01 seconds ===============================
but the similar execution with pytest >= 4.1 fails
$ pytest -k foo
================================= test session starts =================================
platform linux2 -- Python 2.7.15rc1, pytest-4.1.1, py-1.7.0, pluggy-0.8.1
rootdir: /home/.../pytest_mark_sample, inifile:
collected 1 item / 1 deselected
============================ 1 deselected in 0.00 seconds =============================
When -k
is replaced with -m
both versions works fine.
Metadata
Metadata
Assignees
Labels
type: bugproblem that needs to be addressedproblem that needs to be addressedtype: regressionindicates a problem that was introduced in a release which was working previouslyindicates a problem that was introduced in a release which was working previously