New tests to replace view_test runtime: 15->0.125s #114
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Previously, the 8 tests in view_test were taking 12 seconds to run. By removing the dependency on the DecisionTestCase, and the user of the test client, the run time has been
dramatically reduced.
If we could do this on all the tests, the test suite would drop in run time to under 1s!!
NOTE - this includes three failing tests. One looks like a bug in the code, the other two would round out the tests but are much easier done with a small code change in views.py
Once we've code-reviewed this, we probably want to get the tests passing before we merge.