Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GH-177: Update tests #183

Merged
merged 11 commits into from
Nov 6, 2018
Merged

GH-177: Update tests #183

merged 11 commits into from
Nov 6, 2018

Conversation

tabergma
Copy link
Collaborator

@tabergma tabergma commented Nov 1, 2018

  • Get rid of TRAVIS env
  • Per default only "fast" tests are executed when running pytest
  • To run all test you have to execute pytest --runslow
  • Update all tests to use pathlib.

closes #177

@tabergma tabergma changed the title GH-177: GH-177: Update tests Nov 1, 2018


@pytest.mark.slow
def test_train_load_use_classifier(results_base_path, tasks_base_path):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do the integration tests really need to be skipped on travis? They only make small models and are important for catching lots of errors.

Copy link
Collaborator

@alanakbik alanakbik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps remove @pytest.mark.slow from the integration tests? Its good to skip the tests for loading all the models and embeddings (i.e. test_embeddings.py) since they are too big, but the training, loading and saving steps should be tested in different variations since they caused lots of errors in the last release.

@tabergma
Copy link
Collaborator Author

tabergma commented Nov 6, 2018

Update: Travis runs unit and integration test on a pull request. On a normal push just the unit tests are executed. Slow tests (such as test_embeddings.py) are not executed at all on Travis.

To run only unit tests: pytest
To run unit + integration tests: pytest --runintegration
To run unit + slow tests: pytest --runslow

@alanakbik alanakbik merged commit 97a6c4c into master Nov 6, 2018
@alanakbik
Copy link
Collaborator

Great work, thanks!

@tabergma tabergma deleted the GH-177-tests branch November 6, 2018 13:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Get rid of TRAVIS environment variable
2 participants