diff --git a/crates/ruff_linter/resources/test/fixtures/flake8_pytest_style/PT010.py b/crates/ruff_linter/resources/test/fixtures/flake8_pytest_style/PT010.py index e6cc58cbc3..4191976043 100644 --- a/crates/ruff_linter/resources/test/fixtures/flake8_pytest_style/PT010.py +++ b/crates/ruff_linter/resources/test/fixtures/flake8_pytest_style/PT010.py @@ -9,3 +9,15 @@ def test_ok(): def test_error(): with pytest.raises(UnicodeError): pass + +def test_match_only(): + with pytest.raises(match="some error message"): + pass + +def test_check_only(): + with pytest.raises(check=lambda e: True): + pass + +def test_match_and_check(): + with pytest.raises(match="some error message", check=lambda e: True): + pass