зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1451904 [wpt PR 10339] - Fix the |name| of PerformanceNavigationTiming, a=testonly
Automatic update from web-platform-testsFix the |name| of PerformanceNavigationTiming Previously, the |name| of a PerformanceNavigationTiming entry was the initial URL (the request URL). After this CL, it is the response URL, so for example a url of the form 'redirect?location=newLoc' will have 'newLoc' as the |name|. Bug: 797465 Change-Id: Icab53ad8027d066422562c82bcf0354c264fea40 Reviewed-on: https://chromium-review.googlesource.com/996579 Reviewed-by: Yoav Weiss <yoav@yoav.ws> Commit-Queue: Nicolás Peña Moreno <npm@chromium.org> Cr-Commit-Position: refs/heads/master@{#548773} wpt-commits: a0091fbff26091db1fd4b6ca07d9512edf7e6a95 wpt-pr: 10339 wpt-commits: a0091fbff26091db1fd4b6ca07d9512edf7e6a95 wpt-pr: 10339
This commit is contained in:
Родитель
bc0cf6e4c7
Коммит
7e6effcb0e
|
@ -578068,7 +578068,7 @@
|
|||
"testharness"
|
||||
],
|
||||
"navigation-timing/nav2_test_redirect_server.html": [
|
||||
"fab304c2f896c156d3374073c8f870219f3e0246",
|
||||
"788929e77d0f3979aeb5e05892ec069aeed6fb02",
|
||||
"testharness"
|
||||
],
|
||||
"navigation-timing/nav2_test_redirect_xserver.html": [
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<script>
|
||||
|
||||
function verifyTimingEventOrder(eventOrder, timingEntry) {
|
||||
for (var i = 0; i < eventOrder.length - 1; i++) {
|
||||
for (let i = 0; i < eventOrder.length - 1; i++) {
|
||||
assert_true(timingEntry[eventOrder[i]] < timingEntry[eventOrder[i + 1]],
|
||||
"Expected " + eventOrder[i] + " to be no greater than " + eventOrder[i + 1] + ".");
|
||||
}
|
||||
|
@ -19,11 +19,13 @@
|
|||
|
||||
function onload_test()
|
||||
{
|
||||
var frame_performance = document.getElementById("frameContext").contentWindow.performance;
|
||||
assert_equals(frame_performance.getEntriesByType("navigation")[0].type,
|
||||
const frame_performance = document.getElementById("frameContext").contentWindow.performance;
|
||||
const navigation_entry = frame_performance.getEntriesByType("navigation")[0];
|
||||
assert_equals(navigation_entry.type,
|
||||
"navigate",
|
||||
"Expected navigation type to be navigate.");
|
||||
assert_equals(frame_performance.getEntriesByType("navigation")[0].redirectCount, 1, "Expected redirectCount to be 1.");
|
||||
assert_equals(navigation_entry.redirectCount, 1, "Expected redirectCount to be 1.");
|
||||
assert_equals(navigation_entry.name, 'http://' + document.location.host + '/navigation-timing/resources/blank_page_green.html');
|
||||
|
||||
var timgingEvents = [
|
||||
'startTime',
|
||||
|
|
Загрузка…
Ссылка в новой задаче