Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
[tool.black]
line-length = 109

#[tool.pytest.ini_options]
#asyncio_mode = "auto"
#asyncio_default_fixture_loop_scope = "function"

[tool.ruff]
target-version = "py313"
line-length = 109
Expand Down
6 changes: 5 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,14 @@ asyncio_default_fixture_loop_scope = function
testpaths = tests
norecursedirs = .git
log_level=INFO
# -p no:respx lets Home Assistant install its httpx alias before respx is imported
addopts =
-p no:respx
--strict-markers
--asyncio-mode=auto
# third-party deprecation warnings raised at import time; not fixable in pyscript
filterwarnings =
ignore:Inheritance class HomeAssistantApplication from web.Application is discouraged:DeprecationWarning:homeassistant\.components\.http\.server
ignore:'asyncio.iscoroutinefunction' is deprecated:DeprecationWarning:backoff\._.*

[mypy]
python_version = 3.14
Expand Down
9 changes: 9 additions & 0 deletions tests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@ python -m pip install -r tests/requirements_test.txt
pre-commit install
```

If you are upgrading an existing virtual environment to Home Assistant 2026.11 or later, you must
first uninstall the old `pytest-homeassistant-custom-component` package, which has been replaced by
`pytest-homeassistant`. Its pytest plugin still loads if it is installed, and it fails with
Home Assistant 2026.11+:
```bash
venv/bin/pip uninstall -y pytest-homeassistant-custom-component
python -m pip install -r tests/requirements_test.txt
```

To submit PRs you will want to fork the repository, and follow the steps above on your
forked repository. Once you have pushed your changes to the fork (which should run the
pre-commit hooks), you can go ahead and submit a PR.
Expand Down
7 changes: 0 additions & 7 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@
from homeassistant.core import HomeAssistant
from homeassistant.setup import async_setup_component


@pytest.fixture(autouse=True)
def auto_enable_custom_integrations(enable_custom_integrations):
"""Enable custom integrations in all tests."""
yield


_UNSET = object()


Expand Down
Loading