Reformat Server-Timing headers to updated W3C spec. - #1211
Merged
matthiask merged 1 commit intoDec 20, 2019
Merged
Conversation
Contributor
|
Thanks for the fix. Are you up for adding a test? |
Member
Author
|
Ah, I didn't realize that entire function has no test. I'll add one for that. |
tim-schilling
commented
Dec 11, 2019
| def test_middleware(self): | ||
| response = self.client.get("/execute_sql/") | ||
| self.assertEqual(response.status_code, 200) | ||
| self.assertContains(response, "djDebug") |
Member
Author
There was a problem hiding this comment.
This caused the test to fail until the views returned a response containing </body>.
jdufresne
reviewed
Dec 12, 2019
| r'CachePanel_total_time;dur=0;desc="Cache 0 Calls"', | ||
| ] | ||
| for expected in expected_partials: | ||
| re.compile(expected).search(server_timing) |
Contributor
There was a problem hiding this comment.
This is missing the assert.
Member
Author
There was a problem hiding this comment.
Cripes. Thanks for catching that.
matthiask
approved these changes
Dec 12, 2019
Fixed basic integration tests. When there was no </body> tag the toolbar's middleware exited earlier and was never inserted.
Member
Author
|
Rebased on master. |
Codecov Report
@@ Coverage Diff @@
## master #1211 +/- ##
==========================================
+ Coverage 86.2% 86.41% +0.21%
==========================================
Files 25 25
Lines 1428 1428
Branches 204 204
==========================================
+ Hits 1231 1234 +3
+ Misses 143 141 -2
+ Partials 54 53 -1
Continue to review full report at Codecov.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Closes #1209