[webkit-changes] cvs commit: LayoutTests/fast/dom
undetectable-document-all-expected.txt
undetectable-document-all.html
Anders
andersca at opensource.apple.com
Thu Dec 29 00:22:09 PST 2005
andersca 05/12/29 00:22:09
Modified: . ChangeLog
Added: fast/dom undetectable-document-all-expected.txt
undetectable-document-all.html
Log:
2005-12-28 Anders Carlsson <andersca at mac.com>
Reviewed by Maciej.
- Add test for http://bugzilla.opendarwin.org/show_bug.cgi?id=6268
Add undetectable document.all
* fast/dom/undetectable-document-all-expected.txt: Added.
* fast/dom/undetectable-document-all.html: Added.
Revision Changes Path
1.197 +10 -0 LayoutTests/ChangeLog
Index: ChangeLog
===================================================================
RCS file: /cvs/root/LayoutTests/ChangeLog,v
retrieving revision 1.196
retrieving revision 1.197
diff -u -r1.196 -r1.197
--- ChangeLog 28 Dec 2005 19:02:00 -0000 1.196
+++ ChangeLog 29 Dec 2005 08:22:08 -0000 1.197
@@ -1,3 +1,13 @@
+2005-12-28 Anders Carlsson <andersca at mac.com>
+
+ Reviewed by Maciej.
+
+ - Add test for http://bugzilla.opendarwin.org/show_bug.cgi?id=6268
+ Add undetectable document.all
+
+ * fast/dom/undetectable-document-all-expected.txt: Added.
+ * fast/dom/undetectable-document-all.html: Added.
+
2005-12-28 Mitz Pettel <opendarwin.org at mitzpettel.com>
Reviewed by Eric, landed by ap.
1.1 LayoutTests/fast/dom/undetectable-document-all-expected.txt
Index: undetectable-document-all-expected.txt
===================================================================
This tests that document.all should be undetectable, and that it should be possible to set document.all to something else. If this test is successful, the text "SUCCESS" should be shown below.
document.all: [object HTMLCollection]
SUCCESS!
1.1 LayoutTests/fast/dom/undetectable-document-all.html
Index: undetectable-document-all.html
===================================================================
<html>
<head>
<script>
function debug(str) {
var c = document.getElementById('console')
c.innerHTML += (str + "<br>")
}
function runTests() {
if (window.layoutTestController)
layoutTestController.dumpAsText();
debug('document.all: ' + document.all)
if (document.all) {
debug('FAILURE: document.all should evaluate to false')
return;
}
if (!document.all) {
// Do nothing
} else {
debug('FAILURE: document.all should evaluate to false')
return;
}
if (document.all != undefined) {
debug('FAILURE: document.all != undefined should evaluate to false ')
return;
}
if (undefined != document.all) {
debug('FAILURE: undefined != document.all should evaluate to false ')
return;
}
if (document.all != null) {
debug('FAILURE: document.all != null should evaluate to false')
return;
}
if (null != document.all) {
debug('FAILURE: null != document.all should evaluate to false')
return;
}
// Try replacing document.all with something else
document.all = { 'foo': 42}
if (document.all.foo != 42) {
debug('FAILURE: replacing document.all did not work')
return;
}
// Delete new document.all
delete(document.all)
if (document.all.foo != undefined) {
debug('FAILURE: deleting replace document.all did not work')
return;
}
debug('SUCCESS!')
}
</script>
</head>
<body onload="runTests();">
This tests that document.all should be undetectable, and that it should be possible to set document.all to something else. If this test is successful, the text "SUCCESS" should be shown below.
<pre id="console"></pre>
</body>
</html>
More information about the webkit-changes
mailing list