diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index b3610473..05c055f8 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -42,6 +42,6 @@ jobs: run: pip list - name: Test with pytest run: | - pytest -s tests + pytest -s --cov=terratorch -v --cov-report term-missing tests diff --git a/pyproject.toml b/pyproject.toml index 7c7ad447..13ac84cb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -69,9 +69,11 @@ dev = [ "mkdocstrings[python]", "mike" # for building docs with versions ] + test = [ - "coverage", - "pytest" + "pytest", + "pytest-coverage", + "coverage-badge" ] mmseg = [ diff --git a/tests/test_finetune.py b/tests/test_finetune.py index 5bf52069..e30a6337 100644 --- a/tests/test_finetune.py +++ b/tests/test_finetune.py @@ -24,7 +24,7 @@ def setup_and_cleanup(model_name): shutil.rmtree(os.path.join("tests", "all_ecos_random")) @pytest.mark.parametrize("model_name", ["prithvi_eo_v1_100", "prithvi_eo_v2_300", "prithvi_swin_B", "prithvi_swin_L", "prithvi_eo_v2_600"]) -@pytest.mark.parametrize("case", ["fit", "test", "validate"]) +@pytest.mark.parametrize("case", ["fit", "test", "validate", "compute_statistics"]) def test_finetune_multiple_backbones(model_name, case): command_list = [case, "-c", f"tests/resources/configs/manufactured-finetune_{model_name}.yaml"] _ = build_lightning_cli(command_list)