---
source: crates/ruff_linter/src/rules/flake8_pytest_style/mod.rs
---
PT023 [*] Use `@pytest.mark.foo()` over `@pytest.mark.foo`
  --> PT023.py:17:1
   |
17 | @pytest.mark.foo
   | ^^^^^^^^^^^^^^^^
18 | def test_something():
19 |     pass
   |
help: Add parentheses
   |
16 |
   - @pytest.mark.foo
17 + @pytest.mark.foo()
18 | def test_something():
   |

PT023 [*] Use `@pytest.mark.foo()` over `@pytest.mark.foo`
  --> PT023.py:22:1
   |
22 | @pytest.mark.foo
   | ^^^^^^^^^^^^^^^^
23 | class TestClass:
24 |     def test_something():
   |
help: Add parentheses
   |
21 |
   - @pytest.mark.foo
22 + @pytest.mark.foo()
23 | class TestClass:
   |

PT023 [*] Use `@pytest.mark.foo()` over `@pytest.mark.foo`
  --> PT023.py:29:5
   |
28 | class TestClass:
29 |     @pytest.mark.foo
   |     ^^^^^^^^^^^^^^^^
30 |     def test_something():
31 |         pass
   |
help: Add parentheses
   |
28 | class TestClass:
   -     @pytest.mark.foo
29 +     @pytest.mark.foo()
30 |     def test_something():
   |

PT023 [*] Use `@pytest.mark.foo()` over `@pytest.mark.foo`
  --> PT023.py:35:5
   |
34 | class TestClass:
35 |     @pytest.mark.foo
   |     ^^^^^^^^^^^^^^^^
36 |     class TestNestedClass:
37 |         def test_something():
   |
help: Add parentheses
   |
34 | class TestClass:
   -     @pytest.mark.foo
35 +     @pytest.mark.foo()
36 |     class TestNestedClass:
   |

PT023 [*] Use `@pytest.mark.foo()` over `@pytest.mark.foo`
  --> PT023.py:43:9
   |
41 | class TestClass:
42 |     class TestNestedClass:
43 |         @pytest.mark.foo
   |         ^^^^^^^^^^^^^^^^
44 |         def test_something():
45 |             pass
   |
help: Add parentheses
   |
42 |     class TestNestedClass:
   -         @pytest.mark.foo
43 +         @pytest.mark.foo()
44 |         def test_something():
   |
