diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1fa1c66d..093c3020 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -75,7 +75,7 @@ repos: hooks: - id: pytest name: Run integration tests before push - entry: .venv/bin/pytest -m integration_test + entry: .venv/bin/pytest -m pre_push_test language: script stages: [push] pass_filenames: false diff --git a/pyproject.toml b/pyproject.toml index 9a7f47b5..3c66bd91 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ extension-pkg-allow-list = "wandb" [tool.pytest.ini_options] markers = [ - "integration_test: Tests run on push. Should be as minimal as possible", + "pre_push_test: Tests run on push. Should be as minimal as possible to maintain fast push speeds.", ] [tool.isort] diff --git a/tests/test_train_model.py b/tests/test_train_model.py index 40533a2d..b82ab4eb 100644 --- a/tests/test_train_model.py +++ b/tests/test_train_model.py @@ -18,9 +18,9 @@ def test_main(model_name): main(cfg) -@pytest.mark.integration_test +@pytest.mark.pre_push_test def test_integration_test(): - """test main using a variety of model.""" + """test main using the logistic model. Used for quickly testing functions before a push.""" with initialize(version_base=None, config_path="../src/psycopt2d/config/"): cfg = compose( config_name="integration_testing.yaml", @@ -28,6 +28,7 @@ def test_integration_test(): ) main(cfg) + def test_crossvalidation(): """Test crossvalidation.""" with initialize(version_base=None, config_path="../src/psycopt2d/config/"):