[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
commit-queue at webkit.org
commit-queue at webkit.org
Wed Dec 22 12:05:47 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 036aba86ec0d670afd908e6f8d1082a3d3026851
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Sat Aug 14 02:16:42 2010 +0000
2010-08-13 Mihai Parparita <mihaip at chromium.org>
Reviewed by Dimitri Glazkov.
Form state restore tests fail on GTK build with r65340
https://bugs.webkit.org/show_bug.cgi?id=43998
Move form submits (and rest of test) to run during onload, to make sure
that the submit generates a history entry.
* fast/forms/state-restore-to-non-autocomplete-form.html:
* fast/forms/state-restore-to-non-edited-controls.html:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@65348 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 2b5fbcf..a8a1f3e 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -2,6 +2,19 @@
Reviewed by Dimitri Glazkov.
+ Form state restore tests fail on GTK build with r65340
+ https://bugs.webkit.org/show_bug.cgi?id=43998
+
+ Move form submits (and rest of test) to run during onload, to make sure
+ that the submit generates a history entry.
+
+ * fast/forms/state-restore-to-non-autocomplete-form.html:
+ * fast/forms/state-restore-to-non-edited-controls.html:
+
+2010-08-13 Mihai Parparita <mihaip at chromium.org>
+
+ Reviewed by Dimitri Glazkov.
+
Session history should skip over JS redirects
https://bugs.webkit.org/show_bug.cgi?id=42861
diff --git a/LayoutTests/fast/forms/state-restore-to-non-autocomplete-form.html b/LayoutTests/fast/forms/state-restore-to-non-autocomplete-form.html
index dee5c37..377e32d 100644
--- a/LayoutTests/fast/forms/state-restore-to-non-autocomplete-form.html
+++ b/LayoutTests/fast/forms/state-restore-to-non-autocomplete-form.html
@@ -4,7 +4,7 @@
<link rel="stylesheet" href="../../fast/js/resources/js-test-style.css">
<script src="../../fast/js/resources/js-test-pre.js"></script>
</head>
-<body>
+<body onload="runTest()">
<p>Test to NOT restore form state to a form with autocomplete=off.</p>
<div id="console"></div>
@@ -24,34 +24,37 @@
<script>
-var parent = document.getElementById('parent');
-var state = document.getElementById('emptyOnFirstVisit');
-if (!state.value) {
- // First visit.
- if (window.layoutTestController)
- layoutTestController.waitUntilDone();
- state.value = 'visited';
-
- document.getElementById('input1').value = 'value1';
- document.getElementById('textarea1').value = 'nice';
- document.getElementById('select1').value = 'Windows';
- document.getElementById('input2').value = 'value2';
- document.getElementById('textarea2').value = 'good';
- document.getElementById('select2').value = 'BSD';
- // Submit form in a timeout to make sure that we create a new back/forward list item.
- setTimeout(function() {document.getElementById('form2').submit();}, 0);
-} else {
- // Second visit.
- debug('Controls in the first form should have their default values:');
- shouldBe('document.getElementById("input1").value', '""');
- shouldBe('document.getElementById("textarea1").value', '""');
- shouldBe('document.getElementById("select1").value', '"Mac"');
- debug('Controls in the second form should have edited values:');
- shouldBe('document.getElementById("input2").value', '"value2"');
- shouldBe('document.getElementById("textarea2").value', '"good"');
- shouldBe('document.getElementById("select2").value', '"BSD"');
- if (window.layoutTestController)
- layoutTestController.notifyDone();
-}
+function runTest()
+{
+ var parent = document.getElementById('parent');
+ var state = document.getElementById('emptyOnFirstVisit');
+ if (!state.value) {
+ // First visit.
+ if (window.layoutTestController)
+ layoutTestController.waitUntilDone();
+ state.value = 'visited';
+
+ document.getElementById('input1').value = 'value1';
+ document.getElementById('textarea1').value = 'nice';
+ document.getElementById('select1').value = 'Windows';
+ document.getElementById('input2').value = 'value2';
+ document.getElementById('textarea2').value = 'good';
+ document.getElementById('select2').value = 'BSD';
+ // Submit form in a timeout to make sure that we create a new back/forward list item.
+ setTimeout(function() {document.getElementById('form2').submit();}, 0);
+ } else {
+ // Second visit.
+ debug('Controls in the first form should have their default values:');
+ shouldBe('document.getElementById("input1").value', '""');
+ shouldBe('document.getElementById("textarea1").value', '""');
+ shouldBe('document.getElementById("select1").value', '"Mac"');
+ debug('Controls in the second form should have edited values:');
+ shouldBe('document.getElementById("input2").value', '"value2"');
+ shouldBe('document.getElementById("textarea2").value', '"good"');
+ shouldBe('document.getElementById("select2").value', '"BSD"');
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+ }
+ }
</script>
</body>
diff --git a/LayoutTests/fast/forms/state-restore-to-non-edited-controls.html b/LayoutTests/fast/forms/state-restore-to-non-edited-controls.html
index b3b25bd..c75ecf6 100644
--- a/LayoutTests/fast/forms/state-restore-to-non-edited-controls.html
+++ b/LayoutTests/fast/forms/state-restore-to-non-edited-controls.html
@@ -4,7 +4,7 @@
<link rel="stylesheet" href="../../fast/js/resources/js-test-style.css">
<script src="../../fast/js/resources/js-test-pre.js"></script>
</head>
-<body>
+<body onload="runTest()">
<p>Test to NOT save state for non-edited controls</p>
<div id="console"></div>
@@ -27,34 +27,37 @@ function makeForm(parent, buttonValue, hiddenValue, imageValue, resetValue, subm
+ '</form>';
}
-var parent = document.getElementById('parent');
-var state = document.getElementById('emptyOnFirstVisit');
-if (!state.value) {
- // First visit.
- if (window.layoutTestController)
- layoutTestController.waitUntilDone();
- state.value = 'visited';
- makeForm(parent, '1', '1', '1', '1', '1', '1', '1', '1');
-
- document.getElementById('text1').value = 'edit';
- // Submit form in a timeout to make sure that we create a new back/forward list item.
- setTimeout(function() {document.getElementById('form1').submit();}, 0);
-} else {
- // Second visit.
- makeForm(parent, '2', '2', '2', '2', '2', '2', '2', '2');
-
- shouldBe('document.getElementById("button").value', '"2"');
- shouldBe('document.getElementById("hidden").value', '"2"');
- shouldBe('document.getElementById("image").value', '"2"');
- shouldBe('document.getElementById("reset").value', '"2"');
- shouldBe('document.getElementById("submit1").value', '"2"');
- shouldBe('document.getElementById("text1").value', '"edit"');
- shouldBe('document.getElementById("text2").value', '"2"');
- shouldBe('document.getElementById("textarea").value', '"2"');
-
- parent.innerHTML = '';
- if (window.layoutTestController)
- layoutTestController.notifyDone();
+function runTest()
+{
+ var parent = document.getElementById('parent');
+ var state = document.getElementById('emptyOnFirstVisit');
+ if (!state.value) {
+ // First visit.
+ if (window.layoutTestController)
+ layoutTestController.waitUntilDone();
+ state.value = 'visited';
+ makeForm(parent, '1', '1', '1', '1', '1', '1', '1', '1');
+
+ document.getElementById('text1').value = 'edit';
+ // Submit form in a timeout to make sure that we create a new back/forward list item.
+ setTimeout(function() {document.getElementById('form1').submit();}, 0);
+ } else {
+ // Second visit.
+ makeForm(parent, '2', '2', '2', '2', '2', '2', '2', '2');
+
+ shouldBe('document.getElementById("button").value', '"2"');
+ shouldBe('document.getElementById("hidden").value', '"2"');
+ shouldBe('document.getElementById("image").value', '"2"');
+ shouldBe('document.getElementById("reset").value', '"2"');
+ shouldBe('document.getElementById("submit1").value', '"2"');
+ shouldBe('document.getElementById("text1").value', '"edit"');
+ shouldBe('document.getElementById("text2").value', '"2"');
+ shouldBe('document.getElementById("textarea").value', '"2"');
+
+ parent.innerHTML = '';
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+ }
}
</script>
</body>
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list