-
Notifications
You must be signed in to change notification settings - Fork 107
Minor improvements in testing, builds and pipeline #707
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
Conversation
- Adding flake8 description - Adding typing info for parameters - fixing minor flake8 issues.
@@ -290,7 +290,12 @@ def run(self): | |||
'mypy', | |||
'pytest', | |||
'requests==2.*', | |||
'coverage' | |||
'coverage', | |||
'pytest-sugar', |
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.
Just curious, I don't see these packages are used anywhere in the code, are they pytest extensions and will be executed automatically?
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.
pytest-sugar
-> If you run pytest locally, this helps to present the tests better
pytest-cov
-> This changes the "coverage" to use pytest-coverage - better in tracking coverages. The pipeline scripts have been updated to use this. Eg:
pytest --instafail --cov=./azure_functions_worker --cov-report xml --cov-branch --cov-append tests/endtoend
pytest-xdist
-> This can run the tests parallel, but the catch currently is that the tests rely on things from other tests (or depend on things which others are also changing at the same time, we need to improve it)
pytest-randomly
-> This runs the tests randomly - exposes the ordering issues in tests, if any.
pytest-instafail
-> shows failures and errors instantly instead of waiting until the end of test session, good for running when trying locally.
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.
include: | ||
- dev | ||
- master | ||
- release/* |
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.
So this change will make us running the release/* branch everynight. Do you suggest moving the previous releases into releases/ancient/* branches 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.
I set up the branch patterns using the best practices as recommended by AzDevops. We can change the daily runs to not target release branches.
Description
This PR adds the following:
--instafail
to print out the stdout statements immediately.__init__()
to help in static analysis - [Improvement] Adding types to function/method parameters to help with static analysis #704.Fixes #704
PR information
Quality of Code and Contribution Guidelines