Fix: Log in real time during pytest execution

This commit is contained in:
tsukumi
2024-09-23 11:39:10 +09:00
parent 5ca6e184d7
commit 53777e315e
2 changed files with 8 additions and 8 deletions

2
.gitignore vendored
View File

@@ -2,7 +2,7 @@ __pycache__/
venv/ venv/
.venv/ .venv/
dist/ dist/
.coverage .coverage*
.ipynb_checkpoints/ .ipynb_checkpoints/
.ruff_cache/ .ruff_cache/

View File

@@ -81,11 +81,11 @@ dependencies = [
features = ["torch"] features = ["torch"]
[tool.hatch.envs.test.scripts] [tool.hatch.envs.test.scripts]
# Usage: `hatch run test:test` # Usage: `hatch run test:test`
test = "pytest tests/test_main.py::test_synthesize_cpu" test = "pytest -s tests/test_main.py::test_synthesize_cpu"
# Usage: `hatch run test:test-cuda` # Usage: `hatch run test:test-cuda`
test-cuda = "pytest tests/test_main.py::test_synthesize_cuda" test-cuda = "pytest -s tests/test_main.py::test_synthesize_cuda"
# Usage: `hatch run test:coverage` # Usage: `hatch run test:coverage`
test-cov = "coverage run -m pytest tests/test_main.py::test_synthesize_cpu" test-cov = "coverage run -m pytest -s tests/test_main.py::test_synthesize_cpu"
# Usage: `hatch run test:cov-report` # Usage: `hatch run test:cov-report`
cov-report = ["- coverage combine", "coverage report"] cov-report = ["- coverage combine", "coverage report"]
# Usage: `hatch run test:cov` # Usage: `hatch run test:cov`
@@ -104,13 +104,13 @@ dependencies = [
] ]
[tool.hatch.envs.test-onnx.scripts] [tool.hatch.envs.test-onnx.scripts]
# Usage: `hatch run test-onnx:test` # Usage: `hatch run test-onnx:test`
test = "pytest tests/test_main.py::test_synthesize_onnx_cpu" test = "pytest -s tests/test_main.py::test_synthesize_onnx_cpu"
# Usage: `hatch run test-onnx:test-cuda` # Usage: `hatch run test-onnx:test-cuda`
test-cuda = "pytest tests/test_main.py::test_synthesize_onnx_cuda" test-cuda = "pytest -s tests/test_main.py::test_synthesize_onnx_cuda"
# Usage: `hatch run test-onnx:test-directml` # Usage: `hatch run test-onnx:test-directml`
test-directml = "pytest tests/test_main.py::test_synthesize_onnx_directml" test-directml = "pytest -s tests/test_main.py::test_synthesize_onnx_directml"
# Usage: `hatch run test-onnx:coverage` # Usage: `hatch run test-onnx:coverage`
test-cov = "coverage run -m pytest tests/test_main.py::test_synthesize_onnx_cpu" test-cov = "coverage run -m pytest -s tests/test_main.py::test_synthesize_onnx_cpu"
# Usage: `hatch run test-onnx:cov-report` # Usage: `hatch run test-onnx:cov-report`
cov-report = ["- coverage combine", "coverage report"] cov-report = ["- coverage combine", "coverage report"]
# Usage: `hatch run test-onnx:cov` # Usage: `hatch run test-onnx:cov`