diff --git a/pyproject.toml b/pyproject.toml index 17fb6307710..9919a3c8f39 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -659,6 +659,9 @@ ignore = [ "PLR2004", # Magic value used in comparison, consider replacing {value} with a constant variable "PLW2901", # Outer {outer_kind} variable {name} overwritten by inner {inner_kind} target "PT004", # Fixture {fixture} does not return anything, add leading underscore + "PT011", # pytest.raises({exception}) is too broad, set the `match` parameter or use a more specific exception + "PT012", # `pytest.raises()` block should contain a single simple statement + "PT018", # Assertion should be broken down into multiple parts "SIM102", # Use a single if statement instead of nested if statements "SIM108", # Use ternary operator {contents} instead of if-else-block "SIM115", # Use context handler for opening files @@ -683,10 +686,6 @@ ignore = [ "PLE0605", # temporarily disabled - "PT011", - "PT018", - "PT012", - "PT023", "PT019" ] @@ -704,6 +703,7 @@ voluptuous = "vol" [tool.ruff.lint.flake8-pytest-style] fixture-parentheses = false +mark-parentheses = false [tool.ruff.lint.flake8-tidy-imports.banned-api] "async_timeout".msg = "use asyncio.timeout instead" diff --git a/tests/components/mqtt_statestream/test_init.py b/tests/components/mqtt_statestream/test_init.py index d8abb7158bd..9798477945c 100644 --- a/tests/components/mqtt_statestream/test_init.py +++ b/tests/components/mqtt_statestream/test_init.py @@ -100,7 +100,7 @@ async def test_setup_and_stop_waits_for_ha( # We use xfail with this test because there is an unhandled exception # in a background task in this test. # The exception is raised by mqtt.async_publish. -@pytest.mark.xfail() +@pytest.mark.xfail async def test_startup_no_mqtt( hass: HomeAssistant, caplog: pytest.LogCaptureFixture ) -> None: