2023-01-27 10:10:29 +00:00
|
|
|
# This extend our general Ruff rules specifically for tests
|
|
|
|
extend = "../pyproject.toml"
|
|
|
|
|
|
|
|
extend-select = [
|
|
|
|
"PT001", # Use @pytest.fixture without parentheses
|
2023-02-08 09:50:53 +00:00
|
|
|
"PT002", # Configuration for fixture specified via positional args, use kwargs
|
|
|
|
"PT003", # The scope='function' is implied in @pytest.fixture()
|
2023-02-15 13:09:50 +00:00
|
|
|
"PT006", # Single parameter in parameterize is a string, multiple a tuple
|
2023-01-27 10:10:29 +00:00
|
|
|
"PT013", # Found incorrect pytest import, use simple import pytest instead
|
|
|
|
"PT015", # Assertion always fails, replace with pytest.fail()
|
2023-01-27 16:14:04 +00:00
|
|
|
"PT021", # use yield instead of request.addfinalizer
|
2023-01-27 12:57:06 +00:00
|
|
|
"PT022", # No teardown in fixture, replace useless yield with return
|
2023-06-08 21:43:56 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
[isort]
|
|
|
|
known-first-party = [
|
|
|
|
"homeassistant",
|
|
|
|
"tests",
|
|
|
|
"script",
|
|
|
|
]
|
|
|
|
known-third-party = [
|
|
|
|
"syrupy",
|
|
|
|
"pytest",
|
|
|
|
"voluptuous",
|
|
|
|
"pylint",
|
|
|
|
]
|
|
|
|
forced-separate = [
|
|
|
|
"tests",
|
2023-01-27 10:10:29 +00:00
|
|
|
]
|