-
Notifications
You must be signed in to change notification settings - Fork 284
Open
Description
Summary
If we cd to contentcuration and run pytest -s (to show stdout) we see hundreds of
***** Loading Constants *****
Site: 3 constants saved (2 new)
License: 9 constants saved (9 new)
ContentKind: 7 constants saved (7 new)
FileFormat: 14 constants saved (14 new)
FormatPreset: 22 constants saved (22 new)
Language: 248 constants saved (248 new)
************ DONE. ************
Category
Select one: TEST PERF
How to reproduce
# yarn run services in one tab
# in another tab
pipenv shell
cd contentcuration
pytest -s
Potential fix
replace https://github.com/learningequality/studio/blob/develop/contentcuration/contentcuration/tests/base.py#L47-L50
and https://github.com/learningequality/studio/blob/develop/contentcuration/contentcuration/tests/base.py#L80-L82 etc
with somethin like setUpModule and tearDownModule:
https://docs.python.org/3/library/unittest.html#setupmodule-and-teardownmodule
Real-life consequences
Tests will run a little faster on devs' machines and in CI.
Reactions are currently unavailable