Bug 1460590 part 2 - Fix buggy tests. r=jgraham

Test 67.js was expecting us to only parse out one server-timing-metric,
and ignore "junk" after. But, according to the spec, we are only to
ignore junk up to the point where we see either (1) another metric, or
(2) a server-timing-param. The header sent has a param (dur=123.4), and
we were parsing that correctly.

Test 68.js was similar, but this time there was another metric (comma-
separated) in the header, which we correctly parsed. The test expected
us to ignore it as "junk".

MozReview-Commit-ID: 9nBhQ7nAdhX

--HG--
extra : rebase_source : 28af453b5a3bb035ec6d00895afa99efeffc9c65
This commit is contained in:
Nicholas Hurley 2018-06-01 11:39:50 -07:00
Родитель 7a9f6d6eac
Коммит cf590c4942
3 изменённых файлов: 2 добавлений и 9 удалений

Просмотреть файл

@ -1,10 +1,3 @@
[server_timing_header-parsing.https.html]
[Untitled]
expected: FAIL
[67.js - duration (0 ?== 123.4)]
expected: FAIL
[68.js - count (2 ?== 1)]
expected: FAIL

Просмотреть файл

@ -1 +1 @@
testServerTiming(document.currentScript, [{"name":"metric"}])
testServerTiming(document.currentScript, [{"name":"metric","dur":123.4}])

Просмотреть файл

@ -1 +1 @@
testServerTiming(document.currentScript, [{"name":"metric1"}])
testServerTiming(document.currentScript, [{"name":"metric1"},{"name":"metric2"}])