From f71108680b30848e48e0a1f7a6cef7fa37ec46b1 Mon Sep 17 00:00:00 2001 From: wolfbeast Date: Sun, 22 Dec 2019 23:48:40 +0100 Subject: Issue #1118 - Part 6: Fix various tests that are no longer correct. The behavior change of document.open() requires these tests to be changed to account for the new spec behavior. --- .../traverse_the_history_write_after_load_1-1.html | 5 +---- .../traverse_the_history_write_after_load_1.html | 5 ++--- .../the-location-interface/reload_document_open_write-1.html | 7 ++++++- .../history/the-location-interface/reload_document_open_write.html | 6 +++--- 4 files changed, 12 insertions(+), 11 deletions(-) (limited to 'testing/web-platform/tests/html') diff --git a/testing/web-platform/tests/html/browsers/history/the-history-interface/traverse_the_history_write_after_load_1-1.html b/testing/web-platform/tests/html/browsers/history/the-history-interface/traverse_the_history_write_after_load_1-1.html index af0118a01..945c8d81f 100644 --- a/testing/web-platform/tests/html/browsers/history/the-history-interface/traverse_the_history_write_after_load_1-1.html +++ b/testing/web-platform/tests/html/browsers/history/the-history-interface/traverse_the_history_write_after_load_1-1.html @@ -5,11 +5,8 @@ opener.pages.push(2); onload = function() { setTimeout(function() { - document.write("3 diff --git a/testing/web-platform/tests/html/browsers/history/the-history-interface/traverse_the_history_write_after_load_1.html b/testing/web-platform/tests/html/browsers/history/the-history-interface/traverse_the_history_write_after_load_1.html index c2c31e76f..404d61d0c 100644 --- a/testing/web-platform/tests/html/browsers/history/the-history-interface/traverse_the_history_write_after_load_1.html +++ b/testing/web-platform/tests/html/browsers/history/the-history-interface/traverse_the_history_write_after_load_1.html @@ -11,12 +11,11 @@ function() { check_result = t.step_func( function() { - if (pages.length < 4) { + if (pages.length < 3) { setTimeout(check_result, 500); return } - //The pass condition here is based on the idea that the spec is wrong and browsers are right - assert_array_equals(pages, [2, 3, 2, 3], "Pages opened during history navigation"); + assert_array_equals(pages, [2, 3, 1], "Pages opened during history navigation"); t.done(); } ) diff --git a/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html b/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html index 1c5a1db8f..e1a2e811c 100644 --- a/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html +++ b/testing/web-platform/tests/html/browsers/history/the-location-interface/reload_document_open_write-1.html @@ -3,11 +3,16 @@