diff options
| author | beidson@apple.com <beidson@apple.com@bbb929c8-8fbe-4397-9dbb-9b2b20218538> | 2009-12-03 20:59:59 +0000 |
|---|---|---|
| committer | beidson@apple.com <beidson@apple.com@bbb929c8-8fbe-4397-9dbb-9b2b20218538> | 2009-12-03 20:59:59 +0000 |
| commit | 05643d1821f7598ac51b8078b3738748a11b0142 (patch) | |
| tree | ff9da93083c09bfb1ace599f6237e4d77ecbc2b4 | |
| parent | 80d381697a3636e4b80c438bfe32746e8958f4e0 (diff) | |
| download | chromium_src-05643d1821f7598ac51b8078b3738748a11b0142.zip chromium_src-05643d1821f7598ac51b8078b3738748a11b0142.tar.gz chromium_src-05643d1821f7598ac51b8078b3738748a11b0142.tar.bz2 | |
Rubberstamped by Sam Weinig.
Fix my absolute URL snafu by outputting only the last path component for these URLs,
which is all that is relevant.
* fast/loader/stateobjects/document-destroyed-navigate-back-expected.txt:
* fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll-expected.txt:
* fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html:
* fast/loader/stateobjects/document-destroyed-navigate-back.html:
* fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange-expected.txt:
* fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html:
git-svn-id: svn://svn.chromium.org/blink/trunk@51653 bbb929c8-8fbe-4397-9dbb-9b2b20218538
7 files changed, 64 insertions, 34 deletions
diff --git a/third_party/WebKit/LayoutTests/ChangeLog b/third_party/WebKit/LayoutTests/ChangeLog index 0893237..31c0edb 100644 --- a/third_party/WebKit/LayoutTests/ChangeLog +++ b/third_party/WebKit/LayoutTests/ChangeLog @@ -1,3 +1,17 @@ +2009-12-03 Brady Eidson <beidson@apple.com> + + Rubberstamped by Sam Weinig. + + Fix my absolute URL snafu by outputting only the last path component for these URLs, + which is all that is relevant. + + * fast/loader/stateobjects/document-destroyed-navigate-back-expected.txt: + * fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll-expected.txt: + * fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html: + * fast/loader/stateobjects/document-destroyed-navigate-back.html: + * fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange-expected.txt: + * fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html: + 2009-12-03 Oliver Hunt <oliver@apple.com> Reviewed by Dan Bernstein. diff --git a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-expected.txt b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-expected.txt index 23fc936..57a2ccd 100644 --- a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-expected.txt +++ b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-expected.txt @@ -5,10 +5,10 @@ ALERT: State popped - SecondEntry (type string) ALERT: Navigating back... main frame - has 1 onunload handler(s) ALERT: History length is 2 -ALERT: window.location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back.html?SecondEntryShouldNeverBeReactivated +ALERT: Last path component of location is document-destroyed-navigate-back.html?SecondEntryShouldNeverBeReactivated main frame - has 1 onunload handler(s) ALERT: History length is 1 -ALERT: window.location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back.html?FirstEntryShouldNeverBeReactivated +ALERT: Last path component of location is document-destroyed-navigate-back.html?FirstEntryShouldNeverBeReactivated ALERT: Test completed This test: -Builds up a list of state object entries. @@ -17,6 +17,6 @@ This test: -Navigates back to the state object entries and verifies the popstate event is not fired. History length is 1 -window.location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back.html?FirstEntryShouldNeverBeReactivated +Last path component of location is document-destroyed-navigate-back.html?FirstEntryShouldNeverBeReactivated Test completed diff --git a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll-expected.txt b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll-expected.txt index 9a76bb2..74708e8 100644 --- a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll-expected.txt +++ b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll-expected.txt @@ -1,14 +1,14 @@ main frame - has 1 onunload handler(s) ALERT: History length is 2 ALERT: State popped - FirstEntry (type string) -ALERT: hashChanged - location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html#FirstEntry +ALERT: hashChanged - Last path component of location is document-destroyed-navigate-back-with-fragment-scroll.html#FirstEntry ALERT: State popped - SecondEntry (type string) -ALERT: hashChanged - location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html#SecondEntry +ALERT: hashChanged - Last path component of location is document-destroyed-navigate-back-with-fragment-scroll.html#SecondEntry ALERT: Navigating back... main frame - has 1 onunload handler(s) ALERT: History length is 2 -ALERT: window.location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html#SecondEntryShouldNeverBeReactivated -ALERT: hashChanged - location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html#FirstEntryShouldNeverBeReactivated +ALERT: Last path component of location is document-destroyed-navigate-back-with-fragment-scroll.html#SecondEntryShouldNeverBeReactivated +ALERT: hashChanged - Last path component of location is document-destroyed-navigate-back-with-fragment-scroll.html#FirstEntryShouldNeverBeReactivated ALERT: Test completed This test: -Builds up a list of state object entries with fragment URL. @@ -17,7 +17,7 @@ This test: -Navigates back to the state object entries and verifies the popstate event is not fired. History length is 2 -window.location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html#SecondEntryShouldNeverBeReactivated -hashChanged - location is file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html#FirstEntryShouldNeverBeReactivated +Last path component of location is document-destroyed-navigate-back-with-fragment-scroll.html#SecondEntryShouldNeverBeReactivated +hashChanged - Last path component of location is document-destroyed-navigate-back-with-fragment-scroll.html#FirstEntryShouldNeverBeReactivated Test completed diff --git a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html index 4444358..ee49914 100644 --- a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html +++ b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html @@ -24,10 +24,15 @@ function endTest(msg) layoutTestController.notifyDone(); } +function lastPathComponent() +{ + return window.location.href.split('/').pop(); +} + function runSecondStageOfTest() { log("History length is " + history.length); - log("window.location is " + window.location); + log("Last path component of location is " + lastPathComponent()); sessionStorage.stage = 3; history.back(); } @@ -35,7 +40,7 @@ function runSecondStageOfTest() function runThirdStageOfTest() { log("History length is " + history.length); - log("window.location is " + window.location); + log("Last path component of location is " + lastPathComponent()); endTest("Test completed"); } @@ -76,7 +81,8 @@ function statePopped() function hashChanged() { - log("hashChanged - location is " + window.location); + log("hashChanged - Last path component of location is " + lastPathComponent()); + if (window.location.hash == "#FirstEntryShouldNeverBeReactivated") endTest("Test completed"); } diff --git a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back.html b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back.html index d910249..13277de 100644 --- a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back.html +++ b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/document-destroyed-navigate-back.html @@ -24,10 +24,15 @@ function endTest(msg) layoutTestController.notifyDone(); } +function lastPathComponent() +{ + return window.location.href.split('/').pop(); +} + function runSecondStageOfTest() { log("History length is " + history.length); - log("window.location is " + window.location); + log("Last path component of location is " + lastPathComponent()); sessionStorage.stage = 3; history.back(); } @@ -35,7 +40,7 @@ function runSecondStageOfTest() function runThirdStageOfTest() { log("History length is " + history.length); - log("window.location is " + window.location); + log("Last path component of location is " + lastPathComponent()); endTest("Test completed"); } diff --git a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange-expected.txt b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange-expected.txt index a4cb868..b72eb1c 100644 --- a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange-expected.txt +++ b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange-expected.txt @@ -1,34 +1,34 @@ This test pushes a series of state objects with different URLs and fragment identifiers meant to test the hashChange event as states are popped. -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withsomeotherquery -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withsomeotherquery# +State popped with event null (type object) and last path component some-other.html?withsomeotherquery +State popped with event null (type object) and last path component some-other.html?withsomeotherquery# Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withsomeotherquery +State popped with event null (type object) and last path component some-other.html?withsomeotherquery Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withsomeotherquery#somehash +State popped with event null (type object) and last path component some-other.html?withsomeotherquery#somehash Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withsomeotherquery#someotherhash +State popped with event null (type object) and last path component some-other.html?withsomeotherquery#someotherhash Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withquery#someotherhash -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withquery# +State popped with event null (type object) and last path component some-other.html?withquery#someotherhash +State popped with event null (type object) and last path component some-other.html?withquery# Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withquery#somehash +State popped with event null (type object) and last path component some-other.html?withquery#somehash Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withquery +State popped with event null (type object) and last path component some-other.html?withquery Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withquery# +State popped with event null (type object) and last path component some-other.html?withquery# Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html?withquery +State popped with event null (type object) and last path component some-other.html?withquery Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/some-other.html -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html# -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html# -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html#otherhash +State popped with event null (type object) and last path component some-other.html +State popped with event null (type object) and last path component pushstate-with-fragment-urls-and-hashchange.html# +State popped with event null (type object) and last path component pushstate-with-fragment-urls-and-hashchange.html# +State popped with event null (type object) and last path component pushstate-with-fragment-urls-and-hashchange.html#otherhash Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html#hash +State popped with event null (type object) and last path component pushstate-with-fragment-urls-and-hashchange.html#hash Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html# +State popped with event null (type object) and last path component pushstate-with-fragment-urls-and-hashchange.html# Hash change fired -State popped with event null (type object) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html# -State popped with event OriginalEntry (type string) and location file:///Volumes/Data/svn/OpenSource/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html +State popped with event null (type object) and last path component pushstate-with-fragment-urls-and-hashchange.html# +State popped with event OriginalEntry (type string) and last path component pushstate-with-fragment-urls-and-hashchange.html diff --git a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html index a148687..bbfc316c 100644 --- a/third_party/WebKit/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html +++ b/third_party/WebKit/LayoutTests/fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html @@ -39,9 +39,14 @@ function runTest() history.back(); } +function lastPathComponent() +{ + return window.location.href.split('/').pop(); +} + function statePopped() { - log("State popped with event " + event.state + " (type " + typeof event.state + ") and location " + window.location); + log("State popped with event " + event.state + " (type " + typeof event.state + ") and last path component " + lastPathComponent()); if (event.state != "OriginalEntry") history.back(); else if (window.layoutTestController) |
