-
Notifications
You must be signed in to change notification settings - Fork 124
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
Use Pytest for running tests #726
Conversation
NOTE: Revert this change once the Jenkins environment is updated
|
||
.PHONY : install_test | ||
install_test : ## Test installation was successful | ||
python tests_install.py report | ||
pytest $(PYTEST_JUNIT_ARGS) climada/engine/test/test_cost_benefit.py \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note for the future: we should probably make a better install test. If there is already one around, I would propose to switch now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you have a particular integration test in mind that would be suitable for that?
Looks all very reasonable and useful. However, I cannot gauge the code on a technical level. @emanuel-schmid : could you please have a look and confirm the review? |
# Conflicts: # CHANGELOG.md
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 looks good to me
🙌 |
Changes proposed in this PR:
pytest
for executing tests. This relieves us from relying onXMLRunner
and the testing scripts when executing unit and integration tests. (XMLRunner
cannot be removed from the dependencies yet because it is used in the scripts for testing the notebooks and data API).make
is needed to run the tests exactly as they are in the CI pipeline.NOTE: After review, please remove the line installing the new test dependencies and add these to the Jenkins test environment instead: https://github.com/CLIMADA-project/climada_python/pull/726/files#diff-efc5a58368476423c7df00e553fe2c5ba301550f96c3cc5a970aa9a51c9e4eddR26
PR Author Checklist
develop
)[ ] Tests updatedPR Reviewer Checklist