diff --git a/app-history/navigate-event/navigate-appHistory-back-cross-document.html b/app-history/navigate-event/navigate-appHistory-back-cross-document.html index da68ea4765ed69..2be9cb9b889ace 100644 --- a/app-history/navigate-event/navigate-appHistory-back-cross-document.html +++ b/app-history/navigate-event/navigate-appHistory-back-cross-document.html @@ -11,7 +11,7 @@ i.onload = t.step_func(() => { i.contentWindow.appHistory.onnavigate = t.step_func_done(e => { assert_equals(e.navigationType, "traverse"); - assert_true(e.cancelable); + assert_false(e.cancelable); assert_false(e.canTransition); assert_false(e.userInitiated); assert_false(e.hashChange); diff --git a/app-history/navigate-event/navigate-appHistory-back-same-document.html b/app-history/navigate-event/navigate-appHistory-back-same-document.html index b4bbd3718964a8..acc71ad3fe2cda 100644 --- a/app-history/navigate-event/navigate-appHistory-back-same-document.html +++ b/app-history/navigate-event/navigate-appHistory-back-same-document.html @@ -11,7 +11,7 @@ appHistory.navigate("#foo").committed.then(t.step_func(() => { appHistory.onnavigate = t.step_func_done(e => { assert_equals(e.navigationType, "traverse"); - assert_true(e.cancelable); + assert_false(e.cancelable); assert_true(e.canTransition); assert_false(e.userInitiated); assert_true(e.hashChange); diff --git a/app-history/navigate-event/navigate-history-back-after-fragment.html b/app-history/navigate-event/navigate-history-back-after-fragment.html index 54791d898642bf..f0a423a47b43b5 100644 --- a/app-history/navigate-event/navigate-history-back-after-fragment.html +++ b/app-history/navigate-event/navigate-history-back-after-fragment.html @@ -12,7 +12,7 @@ appHistory.onnavigate = t.step_func_done(e => { assert_equals(e.navigationType, "traverse"); - assert_true(e.cancelable); + assert_false(e.cancelable); assert_true(e.canTransition); assert_false(e.userInitiated); assert_true(e.hashChange); diff --git a/app-history/navigate-event/navigate-history-back-after-pushState.html b/app-history/navigate-event/navigate-history-back-after-pushState.html index 3d94855e799d31..40c41ee3b7098c 100644 --- a/app-history/navigate-event/navigate-history-back-after-pushState.html +++ b/app-history/navigate-event/navigate-history-back-after-pushState.html @@ -12,7 +12,7 @@ appHistory.onnavigate = t.step_func_done(e => { assert_equals(e.navigationType, "traverse"); - assert_true(e.cancelable); + assert_false(e.cancelable); assert_true(e.canTransition); assert_false(e.userInitiated); assert_false(e.hashChange); diff --git a/app-history/navigate-event/navigate-history-back-cross-document.html b/app-history/navigate-event/navigate-history-back-cross-document.html new file mode 100644 index 00000000000000..c6c8322a35ace2 --- /dev/null +++ b/app-history/navigate-event/navigate-history-back-cross-document.html @@ -0,0 +1,31 @@ + + + + + diff --git a/app-history/navigate/return-value/goTo-cross-document-preventDefault.html b/app-history/navigate/return-value/goTo-cross-document-preventDefault.html index a7571a7caf7116..9c2301728deef4 100644 --- a/app-history/navigate/return-value/goTo-cross-document-preventDefault.html +++ b/app-history/navigate/return-value/goTo-cross-document-preventDefault.html @@ -20,8 +20,10 @@ assert_equals(i.contentWindow.appHistory.entries().length, 2); assert_equals(i.contentWindow.appHistory.current, i.contentWindow.appHistory.entries()[1]); + // This will be a noop, because navigate events are uncancelable for traversals. i.contentWindow.appHistory.onnavigate = e => e.preventDefault(); - await assertBothRejectDOM(t, i.contentWindow.appHistory.goTo(key), "AbortError", i.contentWindow); -}, "goTo() promise rejection when preventDefault()ing the navigate event (cross-document)"); + assertNeverSettles(t, i.contentWindow.appHistory.goTo(key), i.contentWindow); + await new Promise(resolve => i.onload = () => t.step_timeout(resolve, 0)); +}, "goTo() promise never settle when preventDefault()ing the navigate event (cross-document)");