forked from cds-snc/notification-api
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
Fix pytest dependency conflict #299
Labels
Comments
philherbert
pushed a commit
that referenced
this issue
Dec 31, 2020
Stopped 2 fixtures from calling other fixtures as functions and causing errors.
philherbert
pushed a commit
that referenced
this issue
Dec 31, 2020
This will be used to stop us needing to call the `sample_service_whitelist` fixture as a function.
philherbert
pushed a commit
that referenced
this issue
Dec 31, 2020
philherbert
pushed a commit
that referenced
this issue
Dec 31, 2020
These fixtures were both calling other fixtures as functions and being called as functions in the tests. Rewriting the tests to make them Pytest 4 compatible means we are no longer using `sample_template_without_letter_permission`, so this has been deleted.
philherbert
pushed a commit
that referenced
this issue
Dec 31, 2020
Since Pytest 5, `ExceptionInfo` objects (returned by `pytest.raises`) now have the same `str` representation as `repr`. This means that `str(e)` now needs to be changed to `str(e.value)`. pytest-dev/pytest#5412
philherbert
pushed a commit
that referenced
this issue
Dec 31, 2020
Stopped some the fixtures in conftest.py from calling other fixtures as functions to make them Pytest 4 compliant.
philherbert
pushed a commit
that referenced
this issue
Dec 31, 2020
philherbert
added a commit
that referenced
this issue
Dec 31, 2020
philherbert
added a commit
that referenced
this issue
Dec 31, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Value Statement
As a VANotify developer
I want to ensure that my dependencies are up to date
So that I can make use of new features and security patches
Acceptance Criteria
WHEN I run
pip install -r requirements_for_text.txt
THEN I don't get any dependency conflicts
Checklist
Assumptions
Additional Info/Resources
Running
pip install -r requirements_for_text.txt
without--use-deprecated=legacy-resolver
returns the following error:To resolve this error, we have to upgrade
pytest
to5.0
. However, doing this breaks a looot of tests - for example,tests.app.service.test_rest.test_get_detailed_service
:See this documentation for a description of the deprecated behaviour.
Out of Scope
Open Questions
The text was updated successfully, but these errors were encountered: