diff --git a/Dockerfile b/Dockerfile index 745a8e4d..1fe5a1ff 100644 --- a/Dockerfile +++ b/Dockerfile @@ -52,6 +52,12 @@ CMD ["python3", \ "--cov='homeassistant'", \ # Generate an XML report of the code coverage "--cov-report=xml", \ + # Generate an HTML report of the code coverage + "--cov-report=html", \ + # Print a summary of the code coverage in the console + "--cov-report=term", \ + # Print logs in color + "--color=yes", \ # Print a count of test results in the console "-o", "console_output_style=count", \ # Run tests in the 'tests/components/adaptive_lighting' directory diff --git a/tests/README.md b/tests/README.md index 01b47047..2034ed70 100644 --- a/tests/README.md +++ b/tests/README.md @@ -9,12 +9,6 @@ To run the tests using the Docker image, navigate to the `adaptive-lighting` rep docker run -v $(pwd):/app basnijholt/adaptive-lighting:latest ``` -and to show the logs with colors use: - -```bash -docker run -v $(pwd):/app -e 'PYTEST_ADDOPTS="--color=yes"' basnijholt/adaptive-lighting:latest -``` - This command will download the Docker image from [the adaptive-lighting Docker Hub repo](https://hub.docker.com/r/basnijholt/adaptive-lighting) and run the tests. If you prefer to build the image yourself, use the following command: