-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
-r requirements.txt | ||
|
||
coverage==7.5.0 | ||
pytest==8.2.0 | ||
pytest-cov==5.0.0 | ||
pytest-aiohttp==1.0.5 | ||
pytest-asyncio==0.23.6 | ||
pytest-homeassistant-custom-component==0.13.132 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[tool:pytest] | ||
testpaths = tests | ||
norecursedirs = .git | ||
addopts = | ||
--strict-markers | ||
--cov=custom_components/teslafi | ||
filterwarnings= | ||
ignore:.*plugin.py:pytest.PytestDeprecationWarning | ||
asyncio_mode = auto |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
"""Tests for TeslaFi integration""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import pytest | ||
|
||
pytest_plugins = "pytest_homeassistant_custom_component" | ||
|
||
# This fixture enables loading custom integrations in all tests. | ||
# Remove to enable selective use of this fixture | ||
@pytest.fixture(autouse=True) | ||
def auto_enable_custom_integrations(enable_custom_integrations): | ||
yield |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
"""Test component setup.""" | ||
|
||
from homeassistant.setup import async_setup_component | ||
|
||
from custom_components.teslafi.const import DOMAIN | ||
|
||
async def test_async_setup(hass): | ||
"""Test the component gets setup.""" | ||
assert await async_setup_component(hass, DOMAIN, {}) is True |