[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
andersca at apple.com
andersca at apple.com
Wed Dec 22 11:17:05 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit c9b3088a77f7e0169e46329a092fe99d6201aeed
Author: andersca at apple.com <andersca at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Fri Jul 16 18:22:41 2010 +0000
LayoutTests/http/tests/cookies/multiple-cookies.html sometimes fails because the cookies are returned in a different order
https://bugs.webkit.org/show_bug.cgi?id=42095
Reviewed by Alexey Proskuryakov.
Normalize the cookie strings by splitting them into an array, sorting the array and then joining back.
* http/tests/cookies/multiple-cookies-expected.txt:
* http/tests/cookies/resources/cookies-test-pre.js:
(normalizeCookie):
(testCookies):
* websocket/tests/httponly-cookie-expected.txt:
* websocket/tests/httponly-cookie.pl:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@63565 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 597e47b..16d35da 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,5 +1,21 @@
2010-07-16 Anders Carlsson <andersca at apple.com>
+ Reviewed by Alexey Proskuryakov.
+
+ LayoutTests/http/tests/cookies/multiple-cookies.html sometimes fails because the cookies are returned in a different order
+ https://bugs.webkit.org/show_bug.cgi?id=42095
+
+ Normalize the cookie strings by splitting them into an array, sorting the array and then joining back.
+
+ * http/tests/cookies/multiple-cookies-expected.txt:
+ * http/tests/cookies/resources/cookies-test-pre.js:
+ (normalizeCookie):
+ (testCookies):
+ * websocket/tests/httponly-cookie-expected.txt:
+ * websocket/tests/httponly-cookie.pl:
+
+2010-07-16 Anders Carlsson <andersca at apple.com>
+
Reviewed by Simon Fraser.
Remove fast/dynamic/flash-replacement-test.html
diff --git a/LayoutTests/http/tests/cookies/multiple-cookies-expected.txt b/LayoutTests/http/tests/cookies/multiple-cookies-expected.txt
index ba67725..35b58c1 100644
--- a/LayoutTests/http/tests/cookies/multiple-cookies-expected.txt
+++ b/LayoutTests/http/tests/cookies/multiple-cookies-expected.txt
@@ -5,8 +5,8 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
Check setting several cookies without clearing.
PASS cookie is 'test=foobar'.
-PASS cookie is 'test=foobar; test2=foobar'.
-PASS cookie is 'test=foobar; test2=foobar; test3=foobar'.
+PASS cookie is 'test2=foobar; test=foobar'.
+PASS cookie is 'test2=foobar; test3=foobar; test=foobar'.
PASS successfullyParsed is true
TEST COMPLETE
diff --git a/LayoutTests/http/tests/cookies/resources/cookies-test-pre.js b/LayoutTests/http/tests/cookies/resources/cookies-test-pre.js
index da8e3a5..80b0ff1 100644
--- a/LayoutTests/http/tests/cookies/resources/cookies-test-pre.js
+++ b/LayoutTests/http/tests/cookies/resources/cookies-test-pre.js
@@ -172,6 +172,13 @@ function setCookies(cookie)
}
}
+// Normalize a cookie string
+function normalizeCookie(cookie)
+{
+ // Split the cookie string, sort it and then put it back together.
+ return cookie.split('; ').sort().join('; ');
+}
+
// We get the cookies throught an XMLHttpRequest.
function testCookies(result)
{
@@ -179,6 +186,11 @@ function testCookies(result)
xhr.open("GET", "resources/getCookies.cgi", false);
xhr.send(null);
var cookie = xhr.getResponseHeader("HTTP_COOKIE") == null ? '"null"' : xhr.getResponseHeader("HTTP_COOKIE");
+
+ // Normalize the cookie strings.
+ result = normalizeCookie(result);
+ cookie = normalizeCookie(cookie);
+
if (cookie === result)
testPassed("cookie is '" + cookie + "'.");
else
diff --git a/LayoutTests/websocket/tests/httponly-cookie-expected.txt b/LayoutTests/websocket/tests/httponly-cookie-expected.txt
index 37907aa..7b92ec3 100644
--- a/LayoutTests/websocket/tests/httponly-cookie-expected.txt
+++ b/LayoutTests/websocket/tests/httponly-cookie-expected.txt
@@ -4,7 +4,7 @@ On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
WebSocket open
WebSocket closed
-PASS cookie is "WK-websocket-test=1; WK-websocket-test-httponly=1"
+PASS cookie is "WK-websocket-test-httponly=1; WK-websocket-test=1"
PASS successfullyParsed is true
TEST COMPLETE
diff --git a/LayoutTests/websocket/tests/httponly-cookie.pl b/LayoutTests/websocket/tests/httponly-cookie.pl
index 066d0c8..f0a5e2f 100755
--- a/LayoutTests/websocket/tests/httponly-cookie.pl
+++ b/LayoutTests/websocket/tests/httponly-cookie.pl
@@ -23,9 +23,17 @@ if (window.layoutTestController) {
var cookie;
+// Normalize a cookie string
+function normalizeCookie(cookie)
+{
+ // Split the cookie string, sort it and then put it back together.
+ return cookie.split('; ').sort().join('; ');
+}
+
function endTest()
{
- shouldBe("cookie", '"WK-websocket-test=1; WK-websocket-test-httponly=1"');
+ cookie = normalizeCookie(cookie);
+ shouldBe("cookie", '"WK-websocket-test-httponly=1; WK-websocket-test=1"');
isSuccessfullyParsed();
if (window.layoutTestController)
layoutTestController.notifyDone();
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list