Migrate tests to pytest paradigm by azmeuk · Pull Request #813 · authlib/authlib
What kind of change does this PR introduce?
This migrates all the tests from the unittest paradigm to the pytest paradigm:
- Use pytest fixtures instead of setUp/tearDown. This allowed a bit of factorization.
- Use test functions instead of TestCase classes.
- Long test files have been split.
- Django and Flask authorization server config loading part has been moved to dedicated
load_configmethods.
This makes the unit tests a lot more legible, and a bit shorter. There are still 748 tests as before.
Follow-up to #746
Checklist
- The commits follow the conventional commits specification.
- You ran the linters with
prek. - You reached 100% of code coverage on the code you edited, without abusive use of
pragma: no cover
- You consent that the copyright of your pull request source code belongs to Authlib's author.