| 1 | # This extend our general Ruff rules specifically for tests |
| 2 | extend = "../pyproject.toml" |
| 3 | |
| 4 | lint.extend-select = [ |
| 5 | "PT001", # Use @pytest.fixture without parentheses |
| 6 | "PT002", # Configuration for fixture specified via positional args, use kwargs |
| 7 | "PT003", # The scope='function' is implied in @pytest.fixture() |
| 8 | "PT006", # Single parameter in parameterize is a string, multiple a tuple |
| 9 | "PT013", # Found incorrect pytest import, use simple import pytest instead |
| 10 | "PT015", # Assertion always fails, replace with pytest.fail() |
| 11 | "PT021", # use yield instead of request.addfinalizer |
| 12 | "PT022", # No teardown in fixture, replace useless yield with return |
| 13 | ] |
| 14 | |
| 15 | [lint.isort] |
| 16 | known-first-party = [ |
| 17 | "pydeconz", |
| 18 | "tests", |
| 19 | ] |
| 20 | known-third-party = [ |
| 21 | "aiohttp", |
| 22 | "pytest", |
| 23 | ] |
| 24 | forced-separate = [ |
| 25 | "tests", |
| 26 | ] |