+2006-01-08 Maciej Stachowiak <mjs@apple.com>
+
+ Reviewed by Eric.
+
+ - Update JavaScript tests so they use KDE style
+ http://bugzilla.opendarwin.org/show_bug.cgi?id=6441
+
+ * fast/js/Plug-ins-expected.checksum: Removed.
+ * fast/js/Plug-ins-expected.png: Removed.
+ * fast/js/Plug-ins-expected.txt: Removed.
+ * fast/js/Plug-ins.html: Removed.
+ * fast/js/activation-proto-expected.txt:
+ * fast/js/activation-proto.html:
+ * fast/js/array-every-expected.txt:
+ * fast/js/array-every.html:
+ * fast/js/array-float-delete-expected.txt:
+ * fast/js/array-float-delete.html:
+ * fast/js/array-special-accessors-should-ignore-items-expected.txt: Removed.
+ * fast/js/array-special-accessors-should-ignore-items.html: Removed.
+ * fast/js/assign-expected.txt:
+ * fast/js/assign.html:
+ * fast/js/char-at-expected.txt:
+ * fast/js/char-at.html:
+ * fast/js/code-serialize-paren-expected.txt:
+ * fast/js/code-serialize-paren.html:
+ * fast/js/const-expected.txt:
+ * fast/js/const.html:
+ * fast/js/cyclic-ref-toString-expected.txt:
+ * fast/js/cyclic-ref-toString.html:
+ * fast/js/date-DST-pre-1970-expected.txt:
+ * fast/js/date-DST-pre-1970.html:
+ * fast/js/date-big-constructor-expected.txt:
+ * fast/js/date-big-constructor.html:
+ * fast/js/date-big-setdate-expected.txt:
+ * fast/js/date-big-setdate.html:
+ * fast/js/date-big-setmonth-expected.txt:
+ * fast/js/date-big-setmonth.html:
+ * fast/js/date-negative-setmonth-expected.txt:
+ * fast/js/date-negative-setmonth.html:
+ * fast/js/date-parse-comments-test-expected.txt:
+ * fast/js/date-parse-comments-test.html:
+ * fast/js/date-parse-test-expected.txt:
+ * fast/js/date-parse-test.html:
+ * fast/js/date-preserve-milliseconds-expected.txt:
+ * fast/js/date-preserve-milliseconds.html:
+ * fast/js/declaration-in-block-expected.txt:
+ * fast/js/declaration-in-block.html:
+ * fast/js/delete-syntax-expected.txt:
+ * fast/js/delete-syntax.html:
+ * fast/js/eval-var-decl-expected.txt:
+ * fast/js/eval-var-decl.html:
+ * fast/js/exception-linenums-expected.txt:
+ * fast/js/exception-linenums.html:
+ * fast/js/for-in-to-text-expected.txt:
+ * fast/js/for-in-to-text.html:
+ * fast/js/global-opener-function-expected.txt: Removed.
+ * fast/js/global-opener-function.html: Removed.
+ * fast/js/has-own-property-expected.txt:
+ * fast/js/has-own-property.html:
+ * fast/js/integer-extremes-expected.txt:
+ * fast/js/integer-extremes.html:
+ * fast/js/isPrototypeOf-expected.txt: Added.
+ * fast/js/isPrototypeOf.html: Added.
+ * fast/js/kde/Array-expected.txt:
+ * fast/js/kde/Array.html:
+ * fast/js/kde/Boolean-expected.txt:
+ * fast/js/kde/Boolean.html:
+ * fast/js/kde/Date-expected.txt:
+ * fast/js/kde/Date.html:
+ * fast/js/kde/Error-expected.txt:
+ * fast/js/kde/Error.html:
+ * fast/js/kde/GlobalObject-expected.txt:
+ * fast/js/kde/GlobalObject.html:
+ * fast/js/kde/Number-expected.txt:
+ * fast/js/kde/Number.html:
+ * fast/js/kde/Object-expected.txt:
+ * fast/js/kde/Object.html:
+ * fast/js/kde/Prototype-expected.txt:
+ * fast/js/kde/Prototype.html:
+ * fast/js/kde/RegExp-expected.txt:
+ * fast/js/kde/RegExp.html:
+ * fast/js/kde/StringObject-expected.txt:
+ * fast/js/kde/StringObject.html:
+ * fast/js/kde/assignments-expected.txt:
+ * fast/js/kde/assignments.html:
+ * fast/js/kde/cast-expected.txt:
+ * fast/js/kde/cast.html:
+ * fast/js/kde/comment-1-expected.txt:
+ * fast/js/kde/comment-1.html:
+ * fast/js/kde/comment-2-expected.txt:
+ * fast/js/kde/comment-2.html:
+ * fast/js/kde/completion-expected.txt:
+ * fast/js/kde/completion.html:
+ * fast/js/kde/conditional-expected.txt:
+ * fast/js/kde/conditional.html:
+ * fast/js/kde/const-expected.txt:
+ * fast/js/kde/const.html:
+ * fast/js/kde/constructor_length-expected.txt:
+ * fast/js/kde/constructor_length.html:
+ * fast/js/kde/crash-1-expected.txt:
+ * fast/js/kde/crash-1.html:
+ * fast/js/kde/crash-2-expected.txt:
+ * fast/js/kde/crash-2.html:
+ * fast/js/kde/delete-expected.txt:
+ * fast/js/kde/delete.html:
+ * fast/js/kde/empty-expected.txt:
+ * fast/js/kde/empty.html:
+ * fast/js/kde/encode_decode_uri-expected.txt:
+ * fast/js/kde/encode_decode_uri.html:
+ * fast/js/kde/eval-expected.txt:
+ * fast/js/kde/eval.html:
+ * fast/js/kde/evil-n-expected.txt:
+ * fast/js/kde/evil-n.html:
+ * fast/js/kde/exception_propagation-expected.txt:
+ * fast/js/kde/exception_propagation.html:
+ * fast/js/kde/exceptions-expected.txt:
+ * fast/js/kde/exceptions.html:
+ * fast/js/kde/function-expected.txt:
+ * fast/js/kde/function.html:
+ * fast/js/kde/function_arguments-expected.txt:
+ * fast/js/kde/function_arguments.html:
+ * fast/js/kde/function_constructor-expected.txt:
+ * fast/js/kde/function_constructor.html:
+ * fast/js/kde/function_length-expected.txt:
+ * fast/js/kde/function_length.html:
+ * fast/js/kde/garbage-n-expected.txt:
+ * fast/js/kde/garbage-n.html:
+ * fast/js/kde/inbuilt_function_proto-expected.txt:
+ * fast/js/kde/inbuilt_function_proto.html:
+ * fast/js/kde/inbuilt_function_tostring-expected.txt:
+ * fast/js/kde/inbuilt_function_tostring.html:
+ * fast/js/kde/iteration-expected.txt:
+ * fast/js/kde/iteration.html:
+ * fast/js/kde/j-comment-3-expected.txt:
+ * fast/js/kde/j-comment-3.html:
+ * fast/js/kde/j-comment-4-expected.txt:
+ * fast/js/kde/j-comment-4.html:
+ * fast/js/kde/literals-expected.txt:
+ * fast/js/kde/literals.html:
+ * fast/js/kde/math-expected.txt:
+ * fast/js/kde/math.html:
+ * fast/js/kde/md5-1-expected.txt:
+ * fast/js/kde/md5-1.html:
+ * fast/js/kde/md5-2-expected.txt:
+ * fast/js/kde/md5-2.html:
+ * fast/js/kde/object_prototype-expected.txt:
+ * fast/js/kde/object_prototype.html:
+ * fast/js/kde/object_prototype_tostring-expected.txt:
+ * fast/js/kde/object_prototype_tostring.html:
+ * fast/js/kde/operators-expected.txt:
+ * fast/js/kde/operators.html:
+ * fast/js/kde/parse-expected.txt:
+ * fast/js/kde/parse.html:
+ * fast/js/kde/prototype_length-expected.txt:
+ * fast/js/kde/prototype_length.html:
+ * fast/js/kde/prototype_proto-expected.txt:
+ * fast/js/kde/prototype_proto.html:
+ * fast/js/kde/resources/TEMPLATE-n.html: Added.
+ * fast/js/kde/resources/TEMPLATE.html: Added.
+ * fast/js/kde/resources/base.js: Removed.
+ * fast/js/kde/resources/inbuilt_function_tostring.js:
+ * fast/js/kde/resources/shell.js: Removed.
+ * fast/js/kde/scope-expected.txt:
+ * fast/js/kde/scope.html:
+ * fast/js/kde/statements-expected.txt:
+ * fast/js/kde/statements.html:
+ * fast/js/kde/string-1-n-expected.txt:
+ * fast/js/kde/string-1-n.html:
+ * fast/js/kde/string-2-n-expected.txt:
+ * fast/js/kde/string-2-n.html:
+ * fast/js/kde/var_decl_init-expected.txt:
+ * fast/js/kde/var_decl_init.html:
+ * fast/js/location-assign-expected.txt: Removed.
+ * fast/js/location-assign.html: Removed.
+ * fast/js/named-function-expression-expected.txt:
+ * fast/js/named-function-expression.html:
+ * fast/js/objc-big-method-name-expected.txt: Removed.
+ * fast/js/objc-big-method-name.html: Removed.
+ * fast/js/object-by-name-or-id-expected.txt: Removed.
+ * fast/js/object-by-name-or-id.html: Removed.
+ * fast/js/object-prototype-constructor-expected.txt:
+ * fast/js/object-prototype-constructor.html:
+ * fast/js/object-prototype-toLocaleString-expected.txt:
+ * fast/js/object-prototype-toLocaleString.html:
+ * fast/js/postfix-syntax-expected.txt:
+ * fast/js/postfix-syntax.html:
+ * fast/js/prefix-syntax-expected.txt:
+ * fast/js/prefix-syntax.html:
+ * fast/js/property-getters-and-setters-expected.txt:
+ * fast/js/property-getters-and-setters.html:
+ * fast/js/propertyIsEnumerable-expected.txt: Added.
+ * fast/js/propertyIsEnumerable.html: Added.
+ * fast/js/regexp-caching-expected.txt:
+ * fast/js/regexp-extended-characters-crash-expected.txt:
+ * fast/js/regexp-extended-characters-crash.html:
+ * fast/js/regexp-extended-characters-match-expected.txt:
+ * fast/js/regexp-extended-characters-match.html:
+ * fast/js/regexp-lastindex-expected.txt:
+ * fast/js/regexp-lastindex.html:
+ * fast/js/replace-child-siblings-expected.txt: Removed.
+ * fast/js/replace-child-siblings.html: Removed.
+ * fast/js/resources/TEMPLATE.html: Added.
+ * fast/js/resources/activation-proto.js: Added.
+ * fast/js/resources/array-every.js: Added.
+ * fast/js/resources/array-float-delete.js: Added.
+ * fast/js/resources/assign.js: Added.
+ * fast/js/resources/char-at.js: Added.
+ * fast/js/resources/child.html: Removed.
+ * fast/js/resources/code-serialize-paren.js: Added.
+ * fast/js/resources/const.js: Added.
+ * fast/js/resources/cyclic-ref-toString.js: Added.
+ * fast/js/resources/date-DST-pre-1970.js: Added.
+ * fast/js/resources/date-big-constructor.js: Added.
+ * fast/js/resources/date-big-setdate.js: Added.
+ * fast/js/resources/date-big-setmonth.js: Added.
+ * fast/js/resources/date-negative-setmonth.js: Added.
+ * fast/js/resources/date-parse-comments-test.js: Added.
+ * fast/js/resources/date-parse-test.js: Added.
+ * fast/js/resources/date-preserve-milliseconds.js: Added.
+ * fast/js/resources/declaration-in-block.js: Added.
+ * fast/js/resources/delete-syntax.js: Added.
+ * fast/js/resources/eval-var-decl.js: Added.
+ * fast/js/resources/exception-linenums.js: Added.
+ * fast/js/resources/for-in-to-text.js: Added.
+ * fast/js/resources/has-own-property.js: Added.
+ * fast/js/resources/integer-extremes.js: Added.
+ * fast/js/resources/isPrototypeOf.js: Added.
+ * fast/js/resources/js-test-post-n.js: Added.
+ * fast/js/resources/js-test-post.js: Added.
+ * fast/js/resources/js-test-pre.js: Added.
+ * fast/js/resources/js-test-style.css: Added.
+ * fast/js/resources/named-function-expression.js: Added.
+ * fast/js/resources/new-location.html: Removed.
+ * fast/js/resources/object-prototype-constructor.js: Added.
+ * fast/js/resources/object-prototype-toLocaleString.js: Added.
+ * fast/js/resources/postfix-syntax.js: Added.
+ * fast/js/resources/prefix-syntax.js: Added.
+ * fast/js/resources/property-getters-and-setters.js: Added.
+ * fast/js/resources/propertyIsEnumerable.js: Added.
+ * fast/js/resources/regexp-extended-characters-crash.js: Added.
+ * fast/js/resources/regexp-extended-characters-match.js: Added.
+ * fast/js/resources/regexp-lastindex.js: Added.
+ * fast/js/resources/slash-lineterminator-parse.js: Added.
+ * fast/js/resources/string-from-char-code.js: Added.
+ * fast/js/resources/string-index-overflow.js: Added.
+ * fast/js/resources/string-replace-2.js: Added.
+ * fast/js/resources/string-slice-abnormal-values.js: Added.
+ * fast/js/resources/string-split-ignore-case.js: Added.
+ * fast/js/resources/string_replace.js: Added.
+ * fast/js/resources/toString-overrides.js: Added.
+ * fast/js/resources/toString-stack-overflow.js: Added.
+ * fast/js/resources/typeof-syntax.js: Added.
+ * fast/js/slash-lineterminator-parse-expected.txt:
+ * fast/js/slash-lineterminator-parse.html:
+ * fast/js/string-from-char-code-expected.txt:
+ * fast/js/string-from-char-code.html:
+ * fast/js/string-index-overflow-expected.txt:
+ * fast/js/string-index-overflow.html:
+ * fast/js/string-replace-2-expected.txt:
+ * fast/js/string-replace-2.html:
+ * fast/js/string-slice-abnormal-values-expected.txt:
+ * fast/js/string-slice-abnormal-values.html:
+ * fast/js/string-split-ignore-case-expected.txt:
+ * fast/js/string-split-ignore-case.html:
+ * fast/js/string_replace-expected.txt:
+ * fast/js/string_replace.html:
+ * fast/js/toString-overrides-expected.txt:
+ * fast/js/toString-overrides.html:
+ * fast/js/toString-stack-overflow-expected.txt:
+ * fast/js/toString-stack-overflow.html:
+ * fast/js/typeof-syntax-expected.txt:
+ * fast/js/typeof-syntax.html:
+
+ - move DOM tests from fast/js to fast/dom
+
+ * fast/dom/HTMLDocument/object-by-name-or-id-expected.txt: Added.
+ * fast/dom/HTMLDocument/object-by-name-or-id.html: Added.
+ * fast/dom/Window/Plug-ins-expected.checksum: Added.
+ * fast/dom/Window/Plug-ins-expected.png: Added.
+ * fast/dom/Window/Plug-ins-expected.txt: Added.
+ * fast/dom/Window/Plug-ins.html: Added.
+ * fast/dom/Window/global-opener-function-expected.txt: Added.
+ * fast/dom/Window/global-opener-function.html: Added.
+ * fast/dom/array-special-accessors-should-ignore-items-expected.txt: Added.
+ * fast/dom/array-special-accessors-should-ignore-items.html: Added.
+ * fast/dom/location-assign-expected.txt: Added.
+ * fast/dom/location-assign.html: Added.
+ * fast/dom/objc-big-method-name-expected.txt: Added.
+ * fast/dom/objc-big-method-name.html: Added.
+ * fast/dom/replace-child-siblings-expected.txt: Added.
+ * fast/dom/replace-child-siblings.html: Added.
+ * fast/dom/resources/child.html: Added.
+ * fast/dom/resources/new-location.html: Added.
+ * fast/dom/resources/xmlhttprequest-get-data.xml: Added.
+ * fast/dom/test-prototypes-expected.txt: Added.
+ * fast/dom/test-prototypes.html: Added.
+ * fast/dom/window-object-cross-frame-calls-expected.txt: Added.
+ * fast/dom/window-object-cross-frame-calls.html: Added.
+ * fast/dom/xmlhttprequest-get-expected.txt: Added.
+ * fast/dom/xmlhttprequest-get.xhtml: Added.
+
2006-01-08 Timothy Hatcher <timothy@apple.com>
Rubber stamped by Eric.
This test checks that activation objects (the local scope for a function) don't have the special __proto__ property that lets you get and set a normal object's prototype. This is important because the impossibility of swizzling activation object prototype chains allows various optimizations.
-On success, you will see a series of "PASS" messages.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS (function() { __proto__.testVariable = 'found'; return window.testVariable; })() is 'found'
+PASS successfullyParsed is true
+
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<style>
-.pass {
- font-weight: bold;
- color: green;
-}
-.fail {
- font-weight: bold;
- color: red;
-}
-#console {
- white-space: pre-wrap;
-}
-</style>
-
-<script src="kde/resources/base.js"></script>
-<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.getElementById("console").innerHTML += '<span class="pass">PASS</span> ' + msg + "<br>";
-}
-
-function testFailed(msg)
-{
- document.getElementById("console").innerHTML += '<span class="fail">FAIL</span> ' + msg + "</span><br>";
-}
-
-function debug(a)
-{
- document.getElementById("console").innerHTML += "<p>" + a + "</p>";
-}
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
<body>
-<p>This test checks that activation objects (the local scope for a
-function) don't have the special __proto__ property that lets you get
-and set a normal object's prototype. This is important because the
-impossibility of swizzling activation object prototype chains allows
-various optimizations.</p>
-<p>On success, you will see a series of "PASS" messages.</p>
-
-<div id="console">
-</div>
-<script>
-shouldBe("(function() { __proto__.testVariable = 'found'; return window.testVariable; })()", "'found'");
-</script>
-
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/activation-proto.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
</html>
-1.0 Single Argument Testing
-The following tests every with one argument, the callback. It should print whether the arrays [12, 5, 8, 130, 44] and [12, 54, 18, 130, 44] solely contain numbers >= to 10 (false and true, respectively).
+This test checks the behavior of the every() method on Array objects.
-false
-true
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-2.0 Two Argument Testing
-The following tests every with two arguments, the callback and the applied "this" object. It should print whether the arrays [12, 5, 11, 130, 44] and [12, 54, 18, 130, 44] solely contain numbers >= to 11 (false and true, respectively).
-false
-true
+1.0 Single Argument Testing
+PASS [12, 5, 8, 130, 44].every(isBigEnough) is false
+PASS [12, 54, 18, 130, 44].every(isBigEnough) is true
+
+2.0 Two Argument Testing
+PASS [12, 5, 10, 130, 44].every(isBigEnough, predicate) is false
+PASS [12, 54, 18, 130, 44].every(isBigEnough, predicate) is true
3.0 Array Mutation Tests
-These tests the affects of array mutation during execution of every.
3.1 Array Element Removal
-This test is equivalent to 1.0, with the exception that it removes elements from the array on each visit. The first test should thus yield "false" and the second test "true", since non-existing properties are not checked.
-
-false
-true
-
-3.3 Array Element Addition
-This test is equivalent to 1.0, with that it test whether elements are >= 131 and it adds elements greater than 131 to the end of the list. However, both results should be false since every uses the original length to create the range it iterates over.
-
-false
-false
+PASS [12, 5, 8, 130, 44].every(isBigEnoughAndPop) is false
+PASS [12, 54, 18, 130, 44].every(isBigEnoughAndPop) is true
3.2 Array Element Changing
-This test is equivalent to 1.0, with the exception that it changes elements in the array to be < 10 in reverse order. These elements should appear in their mutated form when reached by every, and thus both tests should result in "false".
+PASS [12, 5, 8, 130, 44].every(isBigEnoughAndChange) is false
+PASS [12, 54, 18, 130, 44].every(isBigEnoughAndChange) is false
-false
-false
+3.3 Array Element Addition
+PASS [12, 5, 8, 130, 44].every(isBigEnoughAndPush) is false
+PASS [12, 54, 18, 130, 44].every(isBigEnoughAndPush) is false
4.0 Exception Test
-This test uses a function that throws an exception, and thus halts the execution of every. There should be an exception string printed twice.
-
-exception from function
-exception from function
-
-5.0 Wrong Type for Callback Test This test sends in incorrect types for the callback parameter of every. An exception should be thrown in each case. There should be 6 type errors (and no crashes!):
-
-TypeError: Type error
-TypeError: Type error
-TypeError: Type error
-TypeError: Type error
-TypeError: Type error
-TypeError: Type error
-
-6.0 Early Abortion ("Short Circuiting") This test is nearly identical to 1.0, except that it prints upon every call to the designated callback function. Since every aborts as soon as it finds one element that does not qualify, the first array should print only twice, and the second all 5 times.
-
-Testing element 12...
-Testing element 5...
-Done with first array.
-Testing element 12...
-Testing element 54...
-Testing element 18...
-Testing element 130...
-Testing element 44...
-Done with second array.
+PASS [12, 5, 8, 130, 44].every(isBigEnoughAndException) threw exception exception from function.
+PASS [12, 54, 18, 130, 44].every(isBigEnoughAndException) threw exception exception from function.
+
+5.0 Wrong Type for Callback Test
+PASS [12, 5, 8, 130, 44].every(5) threw exception TypeError: Type error.
+PASS [12, 5, 8, 130, 44].every('wrong') threw exception TypeError: Type error.
+PASS [12, 5, 8, 130, 44].every(new Object()) threw exception TypeError: Type error.
+PASS [12, 5, 8, 130, 44].every(null) threw exception TypeError: Type error.
+PASS [12, 5, 8, 130, 44].every(undefined) threw exception TypeError: Type error.
+PASS [12, 5, 8, 130, 44].every() threw exception TypeError: Type error.
+
+6.0 Early Exit ("Short Circuiting")
+PASS [12, 5, 8, 130, 44].every(isBigEnoughShortCircuit) is false
+PASS accumulator.toString() is [12, 5].toString()
+PASS [12, 54, 18, 130, 44].every(isBigEnoughShortCircuit) is true
+PASS accumulator.toString() is [12, 54, 18, 130, 44].toString()
+PASS successfullyParsed is true
+
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<script type="text/javascript">
-
-function print(str) {
- document.writeln(str+"<br/>");
-}
-
-if (window.layoutTestController) layoutTestController.dumpAsText();
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
<body>
-1.0 Single Argument Testing<br/>
-The following tests every with one argument, the callback. It should print whether the arrays [12, 5, 8, 130, 44] and [12, 54, 18, 130, 44] solely contain numbers >= to 10 (false and true, respectively).<br/><br/>
-<script>
-function isBigEnough(element, index, array) {
- return (element >= 10);
-}
-
-print([12, 5, 8, 130, 44].every(isBigEnough));
-print([12, 54, 18, 130, 44].every(isBigEnough));
-</script>
-<br/>
-
-2.0 Two Argument Testing<br/>
-The following tests every with two arguments, the callback and the applied "this" object. It should print whether the arrays [12, 5, 11, 130, 44] and [12, 54, 18, 130, 44] solely contain numbers >= to 11 (false and true, respectively).<br/><br/>
-<script>
- var predicate = {
- comparison: 11,
- isBigEnough: function(s) {
- return (s >= comparison);
- }
- };
-
- print([12, 5, 10, 130, 44].every(isBigEnough), predicate);
- print([12, 54, 18, 130, 44].every(isBigEnough), predicate);
-
-</script>
-<br/>
-
-3.0 Array Mutation Tests<br/>
-These tests the affects of array mutation during execution of every.<br/><br/>
-3.1 Array Element Removal<br/>
-This test is equivalent to 1.0, with the exception that it removes elements from the array on each visit. The first test should thus yield "false" and the second test "true", since non-existing properties are not checked.<br/><br/>
-
-<script>
-function isBigEnoughAndPop(element, index, array) {
- array.pop();
- return (element >= 10);
-}
-
-print([12, 5, 8, 130, 44].every(isBigEnoughAndPop));
-print([12, 54, 18, 130, 44].every(isBigEnoughAndPop));
-</script>
-<br/>
-
-3.3 Array Element Addition<br/>
-This test is equivalent to 1.0, with that it test whether elements are >= 131 and it adds elements greater than 131 to the end of the list. However, both results should be false since every uses the original length to create the range it iterates over.<br/><br/>
-<script>
-function isBigEnoughAndPush(element, index, array) {
- array.push(131);
- return (element >= 131);
-}
-
-print([12, 5, 8, 130, 44].every(isBigEnoughAndPush));
-print([12, 54, 18, 130, 44].every(isBigEnoughAndPush));
-</script>
-<br/>
-
-3.2 Array Element Changing<br/>
-This test is equivalent to 1.0, with the exception that it changes elements in the array to be < 10 in reverse order. These elements should appear in their mutated form when reached by every, and thus both tests should result in "false".<br/><br/>
-<script>
-function isBigEnoughAndChange(element, index, array) {
- array[array.length-1-index]= 5;
- return (element >= 10);
-}
-
-print([12, 5, 8, 130, 44].every(isBigEnoughAndChange));
-print([12, 54, 18, 130, 44].every(isBigEnoughAndChange));
-</script>
-<br/>
-4.0 Exception Test<br/>
-This test uses a function that throws an exception, and thus halts the execution of every. There should be an exception string printed twice.<br/><br/>
-<script>
-function isBigEnoughAndException(element, index, array) {
- if(index==1) throw "exception from function";
- return (element >= 10);
-}
-
-try { [12, 5, 8, 130, 44].every(isBigEnoughAndException); }
-catch (e) { print(e); }
-
-try { [12, 54, 18, 130, 44].every(isBigEnoughAndException); }
-catch (e) { print(e); }
-
-</script>
-<br/>
-5.0 Wrong Type for Callback Test
-This test sends in incorrect types for the callback parameter of every. An exception should be thrown in each case. There should be 6 type errors (and no crashes!):<br/><br/>
-<script>
-
-try { [12, 5, 8, 130, 44].every(5) }
-catch (e) { print(e); }
-
-try { [12, 5, 8, 130, 44].every("wrong"); }
-catch (e) { print(e); }
-
-try { [12, 5, 8, 130, 44].every(new Object()); }
-catch (e) { print(e); }
-
-try { [12, 5, 8, 130, 44].every(null); }
-catch (e) { print(e); }
-
-try { [12, 5, 8, 130, 44].every(undefined); }
-catch (e) { print(e) }
-
-try { [12, 5, 8, 130, 44].every(); }
-catch (e) { print(e); }
-
-</script>
-<br/>
-6.0 Early Abortion ("Short Circuiting")
-This test is nearly identical to 1.0, except that it prints upon every call to the designated callback function. Since every aborts as soon as it finds one element that does not qualify, the first array should print only twice, and the second all 5 times.<br/><br/>
-<script>
-function isBigEnoughShortCircuit(element, index, array) {
- print("Testing element "+element+"...");
- return (element >= 10);
-}
-
-[12, 5, 8, 130, 44].every(isBigEnoughShortCircuit);
-print("Done with first array.");
-[12, 54, 18, 130, 44].every(isBigEnoughShortCircuit);
-print("Done with second array.");
-</script>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/array-every.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
-</html>
\ No newline at end of file
+</html>
This test checks for regression against 6234: Can delete array index property incorrectly.
-On success, you will see a series of "PASS" messages.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
PASS a[1] is "before"
+PASS successfullyParsed is true
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
<body>
-<p>This test checks for regression against <a href="http://bugzilla.opendarwin.org/show_bug.cgi?id=6234">6234: Can delete array index property incorrectly.</a></p>
-<p>On success, you will see a series of "PASS" messages.</p>
-
-<script src="kde/resources/base.js"></script>
-<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
-</script>
-
-<pre>
-<script>
-var a = new Array();
-a[1] = "before";
-a['1.0'] = "after";
-delete a['1.0'];
-shouldBe("a[1]", '"before"');
-</script>
-</pre>
-
-</body>
\ No newline at end of file
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/array-float-delete.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
+</html>
-This test checks whether various forms of assignment expression are allowed. It should print the numbers 1-10 on separate lines, and nothing else (besides this paragraph).
-
-
-1
-2
-3
-4
-5
-6
-7
-8
-9
-10
+This test checks whether various forms of assignment expression are allowed.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS x = 1; x is 1
+PASS window.x = 2; x is 2
+PASS window["x"] = 3; x is 3
+PASS (x) = 4; x is 4
+PASS (window.x) = 5; x is 5
+PASS (window["x"]) = 6; x is 6
+PASS y, x = 7; x is 7
+PASS ((x)) = 8; x is 8
+PASS ((window.x)) = 9; x is 9
+PASS ((window["x"])) = 10; x is 10
+PASS (y, x) = "FAIL"; threw exception SyntaxError: Parse error.
+PASS (true ? x : y) = "FAIL"; threw exception SyntaxError: Parse error.
+PASS x++ = "FAIL"; threw exception SyntaxError: Parse error.
+PASS successfullyParsed is true
+
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
<body>
-<p>
-This test checks whether various forms of assignment expression are
-allowed. It should print the numbers 1-10 on separate lines, and
-nothing else (besides this paragraph).
-<p>
-<hr>
-<pre id="console">
-</pre>
-<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function log(s)
-{
- document.getElementById('console').innerHTML += s + '<br>';
-}
-
-var x = 0;
-var y = 0;
-
-try { eval ('x = 1; log(x);'); } catch (e) {}
-try { eval ('window.x = 2; log(x);'); } catch (e) {}
-try { eval ('window["x"] = 3; log(x);'); } catch (e) {}
-try { eval ('(x) = 4; log(x);'); } catch (e) {}
-try { eval ('(window.x) = 5; log(x);'); } catch (e) {}
-try { eval ('(window["x"]) = 6; log(x);'); } catch (e) {}
-try { eval ('y, x = 7; log(x);'); } catch (e) {}
-try { eval ('((x)) = 8; log(x);'); } catch (e) {}
-try { eval ('((window.x)) = 9; log(x);'); } catch (e) {}
-try { eval ('((window["x"])) = 10; log(x);'); } catch (e) {}
-try { eval ('(y, x) = "FAIL"; log(x);'); } catch (e) {}
-try { eval ('(true ? x : y) = "FAIL"; log(x);'); } catch (e) {}
-try { eval ('x++ = "FAIL"; log(x);'); } catch (e) {}
-
-</script>
-
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/assign.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
+</html>
-"", omitted: "", NaN
-"", undefined: "", NaN
-"", 0: "", NaN
-"", null: "", NaN
-"", false: "", NaN
-"", true: "", NaN
-"", 0: "", NaN
-"", 0.1: "", NaN
-"", 999: "", NaN
-"", Infinity: "", NaN
-"", -1: "", NaN
-"", -Infinity: "", NaN
-"", NaN: "", NaN
-"x", omitted: "x", 120
-"x", undefined: "x", 120
-"x", 0: "x", 120
-"x", null: "x", 120
-"x", false: "x", 120
-"x", true: "", NaN
-"x", 0: "x", 120
-"x", 0.1: "x", 120
-"x", 999: "", NaN
-"x", Infinity: "", NaN
-"x", -1: "", NaN
-"x", -Infinity: "", NaN
-"x", NaN: "", NaN
-"xy", omitted: "x", 120
-"xy", undefined: "x", 120
-"xy", 0: "x", 120
-"xy", null: "x", 120
-"xy", false: "x", 120
-"xy", true: "y", 121
-"xy", 0: "x", 120
-"xy", 0.1: "x", 120
-"xy", 999: "", NaN
-"xy", Infinity: "", NaN
-"xy", -1: "", NaN
-"xy", -Infinity: "", NaN
-"xy", NaN: "", NaN
+This is a test of the charAt and charCodeAt string functions.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS "".charAt() is ""
+PASS "".charCodeAt() is NaN.
+PASS "".charAt(undefined) is ""
+PASS "".charCodeAt(undefined) is NaN.
+PASS "".charAt(0) is ""
+PASS "".charCodeAt(0) is NaN.
+PASS "".charAt(null) is ""
+PASS "".charCodeAt(null) is NaN.
+PASS "".charAt(false) is ""
+PASS "".charCodeAt(false) is NaN.
+PASS "".charAt(true) is ""
+PASS "".charCodeAt(true) is NaN.
+PASS "".charAt(0) is ""
+PASS "".charCodeAt(0) is NaN.
+PASS "".charAt(0.1) is ""
+PASS "".charCodeAt(0.1) is NaN.
+PASS "".charAt(999) is ""
+PASS "".charCodeAt(999) is NaN.
+PASS "".charAt(Infinity) is ""
+PASS "".charCodeAt(Infinity) is NaN.
+PASS "".charAt(-1) is ""
+PASS "".charCodeAt(-1) is NaN.
+PASS "".charAt(-Infinity) is ""
+PASS "".charCodeAt(-Infinity) is NaN.
+PASS "".charAt(NaN) is ""
+PASS "".charCodeAt(NaN) is NaN.
+PASS "x".charAt() is "x"
+PASS "x".charCodeAt() is 120
+PASS "x".charAt(undefined) is "x"
+PASS "x".charCodeAt(undefined) is 120
+PASS "x".charAt(0) is "x"
+PASS "x".charCodeAt(0) is 120
+PASS "x".charAt(null) is "x"
+PASS "x".charCodeAt(null) is 120
+PASS "x".charAt(false) is "x"
+PASS "x".charCodeAt(false) is 120
+PASS "x".charAt(true) is ""
+PASS "x".charCodeAt(true) is NaN.
+PASS "x".charAt(0) is "x"
+PASS "x".charCodeAt(0) is 120
+PASS "x".charAt(0.1) is "x"
+PASS "x".charCodeAt(0.1) is 120
+PASS "x".charAt(999) is ""
+PASS "x".charCodeAt(999) is NaN.
+PASS "x".charAt(Infinity) is ""
+PASS "x".charCodeAt(Infinity) is NaN.
+PASS "x".charAt(-1) is ""
+PASS "x".charCodeAt(-1) is NaN.
+PASS "x".charAt(-Infinity) is ""
+PASS "x".charCodeAt(-Infinity) is NaN.
+PASS "x".charAt(NaN) is ""
+PASS "x".charCodeAt(NaN) is NaN.
+PASS "xy".charAt() is "x"
+PASS "xy".charCodeAt() is 120
+PASS "xy".charAt(undefined) is "x"
+PASS "xy".charCodeAt(undefined) is 120
+PASS "xy".charAt(0) is "x"
+PASS "xy".charCodeAt(0) is 120
+PASS "xy".charAt(null) is "x"
+PASS "xy".charCodeAt(null) is 120
+PASS "xy".charAt(false) is "x"
+PASS "xy".charCodeAt(false) is 120
+PASS "xy".charAt(true) is "y"
+PASS "xy".charCodeAt(true) is 121
+PASS "xy".charAt(0) is "x"
+PASS "xy".charCodeAt(0) is 120
+PASS "xy".charAt(0.1) is "x"
+PASS "xy".charCodeAt(0.1) is 120
+PASS "xy".charAt(999) is ""
+PASS "xy".charCodeAt(999) is NaN.
+PASS "xy".charAt(Infinity) is ""
+PASS "xy".charCodeAt(Infinity) is NaN.
+PASS "xy".charAt(-1) is ""
+PASS "xy".charCodeAt(-1) is NaN.
+PASS "xy".charAt(-Infinity) is ""
+PASS "xy".charCodeAt(-Infinity) is NaN.
+PASS "xy".charAt(NaN) is ""
+PASS "xy".charCodeAt(NaN) is NaN.
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
-<script>
-
-function test() {
-
- var undefined;
-
- var cases = [
- ["", "omitted"],
- ["", undefined],
- ["", 0],
- ["", null],
- ["", false],
- ["", true],
- ["", 0.0],
- ["", 0.1],
- ["", 999],
- ["", 1/0],
- ["", -1],
- ["", -1/0],
- ["", 0/0],
-
- ["x", "omitted"],
- ["x", undefined],
- ["x", 0],
- ["x", null],
- ["x", false],
- ["x", true],
- ["x", 0.0],
- ["x", 0.1],
- ["x", 999],
- ["x", 1/0],
- ["x", -1],
- ["x", -1/0],
- ["x", 0/0],
-
- ["xy", "omitted"],
- ["xy", undefined],
- ["xy", 0],
- ["xy", null],
- ["xy", false],
- ["xy", true],
- ["xy", 0.0],
- ["xy", 0.1],
- ["xy", 999],
- ["xy", 1/0],
- ["xy", -1],
- ["xy", -1/0],
- ["xy", 0/0],
- ];
-
- for (var i = 0; i < cases.length; ++i)
- {
- var item = cases[i];
- if (item[1] == "omitted") {
- var string = item[0].charAt();
- var code = item[0].charCodeAt();
- } else {
- var string = item[0].charAt(item[1]);
- var code = item[0].charCodeAt(item[1]);
- }
-
- var item0String = item[0];
- if (typeof item0String == "string")
- item0String = '"' + item0String + '"';
- var item1String = item[1];
- if (typeof item1String == "string" && item[1] != "omitted")
- item1String = '"' + item1String + '"';
- var message = item0String + ', ' + item1String + ': "' + string + '", ' + code;
-
- var div = document.createElement('div');
- div.innerHTML = message;
- document.body.appendChild(div);
- }
-
-}
-
-if (window.layoutTestController) {
- layoutTestController.dumpAsText();
-}
-
-</script>
-
-<body onload="test()">
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/char-at.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
+</html>
-This test checks whether converting function code to a string preserves semantically significant parentheses. The results should say PASS.
-PASS
+This test checks whether converting function code to a string preserves semantically significant parentheses.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS (function () { return (x + y) * z; }).toString().search('return.*\(') < 0 is true
+PASS successfullyParsed is true
+
+TEST COMPLETE
-<body>
-<div> This test checks whether converting function code to a
-string preserves semantically significant parentheses. The results
-should say PASS.
-</div>
-<hr>
-
-<div id="console">
-</dic>
-
-<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function log(s)
-{
- document.getElementById("console").innerHTML += s + "<br>";
-}
-
-var functionStr = (function () { return (x + y) * z; }).toString();
-
-if (functionStr.search('return.*\\(') < 0) {
- log("FAIL (functionStr == \"" + functionStr + "\")");
-} else {
- log("PASS");
-}
-
-</script>
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/code-serialize-paren.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
+</html>
-This test checks that const declarations in JavaScript work and are readonly. The text below should say RIGHT twice.
+This test checks that const declarations in JavaScript work and are readonly.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS x is "RIGHT"
+PASS y is "RIGHT"
+PASS successfullyParsed is true
+
+TEST COMPLETE
-RIGHT
-RIGHT
-<div>
-This test checks that const declarations in JavaScript work and are readonly. The text below should say RIGHT twice.
-</div>
-<br>
-<div>
-<script>
-if (window.layoutTestController) {
- layoutTestController.dumpAsText();
-}
-
-try {
- const x = "RIGHT";
- x = "WRONG";
- document.write(x);
-} catch (exc) {
- document.write("EXCEPTION");
-}
-</script>
-</div>
-<div>
-<script>
-try {
- const x = "RIGHT", y = "RIGHT";
- y = "WRONG";
- document.write(y);
-} catch (exc) {
- document.write("EXCEPTION");
-}
-</script>
-</div>
\ No newline at end of file
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/const.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
+</html>
This will test Array.toString with circular references. If an element contains a reference to itself or one of its children (at any depth) contains a reference to it, it will be skipped. This can result in either a trailing ',' (if the self reference is at the end of the array) or ',,' if the self reference is contained at some mid point in the array.
-Array Contents Expected Output Actual Output
-[1, 2, self] 1,2, 1,2,
-[1, 2, [3, 4, parent]] 1,2,3,4, 1,2,3,4,
-[1, 2, [3, 4, parent], 5] 1,2,3,4,,5 1,2,3,4,,5
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS ary1.toString() is '1,2,'
+PASS ary1.toString() is '1,2,3,4,'
+PASS ary1.toString() is '1,2,3,4,,5'
+PASS successfullyParsed is true
+
+TEST COMPLETE
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<title>test cyclic references and Array.toString</title>
-<script language="javascript">
-function init(){
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
- var ary1=[1,2];
- ary1.push(ary1);
- document.getElementById("r0c1").firstChild.nodeValue = ary1;
- ary1=[1,2];
- var ary2=[3,4];
- ary1.push(ary2);
- ary2.push(ary1);
- document.getElementById("r1c1").firstChild.nodeValue = ary1;
- ary1.push(5);
- document.getElementById("r2c1").firstChild.nodeValue = ary1;
-}
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-<body onload="init()">
- This will test Array.toString with circular references. If an element contains a reference to
- itself or one of its children (at any depth) contains a reference to it, it will be skipped.
- This can result in either a trailing ',' (if the self reference is at the end of the array) or ',,'
- if the self reference is contained at some mid point in the array.
- <table cellpadding="2" cellspacing="2" border="1">
- <tbody>
- <tr>
- <td>Array Contents</td><td>Expected Output</td><td>Actual Output</td>
- </tr>
- <tr>
- <td>[1, 2, self]</td><td id="r0c0">1,2,</td><td id="r0c1"> </td>
- </tr>
- <tr>
- <td>[1, 2, [3, 4, parent]]</td><td id="r1c0">1,2,3,4,</td><td id="r1c1"> </td>
- </tr>
- <tr>
- <td>[1, 2, [3, 4, parent], 5]</td><td id="r2c0">1,2,3,4,,5</td><td id="r2c1"> </td>
- </tr>
- </tbody>
- </table>
-<div id='console'/>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/cyclic-ref-toString.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
-</html>
\ No newline at end of file
+</html>
-This tests the DST status in dates earlier than 1970-01-01 00:00 UTC. Regardless of your time zone, it should not fail.
+This tests the DST status in dates earlier than 1970-01-01 00:00 UTC. Regardless of your time zone, it should not fail. This tests time zones: US/Pacific, US/Central, US/Mountain, US/Eastern, CET, Asia/Jerusalem and NZ.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS (new Date(1970, 0, 1)).getHours() is 0
+PASS (new Date(1969, 8, 1)).getHours() is 0
+PASS (new Date(1969, 9, 28)).getHours() is 0
+PASS successfullyParsed is true
+
+TEST COMPLETE
-SUCCESS! (This tests time zones: US/Pacific, US/Central, US/Mountain, US/Eastern, CET, Asia/Jerusalem and NZ.)
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<script>
-function print(message) {
- var paragraph = document.createElement("p");
- paragraph.appendChild(document.createTextNode(message));
- document.getElementById("console").appendChild(paragraph);
-}
-
-function test() {
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
-
- var dates = [
- new Date(1970, 0, 1), // fails in NZ
- new Date(1969, 8, 1), // fails in CET, Asia/Jerusalem
- new Date(1969, 9, 28), // fails in US/Eastern, Mountain, Pacific, Central
- ];
- while (d = dates.shift()) {
- if (d.getHours() != 0) {
- print("FAILED: " + d);
- break;
- }
- }
- if (!d)
- print("SUCCESS! (This tests time zones: US/Pacific, US/Central, US/Mountain, US/Eastern, CET, Asia/Jerusalem and NZ.)");
-}
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-<body onload="test();">
-<p>This tests the DST status in dates earlier than 1970-01-01 00:00 UTC. Regardless of your time zone, it should not fail.</p>
-<hr>
-<div id='console'/>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/date-DST-pre-1970.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
</html>
-This test case checks that months greater than 11 are handled correctly when passed to the Date constructor and the Date.UTC function. The ECMA 262 specification says that months > 11 should be treated as month % 12 and the year as year + floor(month / 12). The expected output on success is "Success!" below. On failure a list of differences between expected and actual output will be shown.
+This test case checks that months greater than 11 are handled correctly when passed to the Date constructor and the Date.UTC function. The ECMA 262 specification says that months > 11 should be treated as month % 12 and the year as year + floor(month / 12).
-Success!
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-0"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-1"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-2"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-3"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-4"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-5"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-6"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-7"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-8"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-9"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-10"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2005-11"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-0"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-1"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-2"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-3"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-4"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-5"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-6"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-7"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-8"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-9"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-10"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2006-11"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-0"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-1"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-2"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-3"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-4"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-5"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-6"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-7"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-8"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-9"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-10"
+PASS d.getFullYear() + "-" + d.getMonth(); is "2007-11"
+PASS Date.UTC(2005, 0, 1) is 1104537600000
+PASS Date.UTC(2005, 1, 1) is 1107216000000
+PASS Date.UTC(2005, 2, 1) is 1109635200000
+PASS Date.UTC(2005, 3, 1) is 1112313600000
+PASS Date.UTC(2005, 4, 1) is 1114905600000
+PASS Date.UTC(2005, 5, 1) is 1117584000000
+PASS Date.UTC(2005, 6, 1) is 1120176000000
+PASS Date.UTC(2005, 7, 1) is 1122854400000
+PASS Date.UTC(2005, 8, 1) is 1125532800000
+PASS Date.UTC(2005, 9, 1) is 1128124800000
+PASS Date.UTC(2005, 10, 1) is 1130803200000
+PASS Date.UTC(2005, 11, 1) is 1133395200000
+PASS Date.UTC(2005, 12, 1) is 1136073600000
+PASS Date.UTC(2005, 13, 1) is 1138752000000
+PASS Date.UTC(2005, 14, 1) is 1141171200000
+PASS Date.UTC(2005, 15, 1) is 1143849600000
+PASS Date.UTC(2005, 16, 1) is 1146441600000
+PASS Date.UTC(2005, 17, 1) is 1149120000000
+PASS Date.UTC(2005, 18, 1) is 1151712000000
+PASS Date.UTC(2005, 19, 1) is 1154390400000
+PASS Date.UTC(2005, 20, 1) is 1157068800000
+PASS Date.UTC(2005, 21, 1) is 1159660800000
+PASS Date.UTC(2005, 22, 1) is 1162339200000
+PASS Date.UTC(2005, 23, 1) is 1164931200000
+PASS Date.UTC(2005, 24, 1) is 1167609600000
+PASS Date.UTC(2005, 25, 1) is 1170288000000
+PASS Date.UTC(2005, 26, 1) is 1172707200000
+PASS Date.UTC(2005, 27, 1) is 1175385600000
+PASS Date.UTC(2005, 28, 1) is 1177977600000
+PASS Date.UTC(2005, 29, 1) is 1180656000000
+PASS Date.UTC(2005, 30, 1) is 1183248000000
+PASS Date.UTC(2005, 31, 1) is 1185926400000
+PASS Date.UTC(2005, 32, 1) is 1188604800000
+PASS Date.UTC(2005, 33, 1) is 1191196800000
+PASS Date.UTC(2005, 34, 1) is 1193875200000
+PASS Date.UTC(2005, 35, 1) is 1196467200000
+PASS successfullyParsed is true
+
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <head>
- <title>Test Case: Verify that months greater than 11 are handled correctly in Date constructor and Date.UTC</title>
- </head>
- <body>
- <p>
- This test case checks that months greater than 11 are handled correctly when passed to the Date constructor and the
- Date.UTC function. The ECMA 262 specification says that months > 11 should be treated as month % 12 and the year
- as year + floor(month / 12). The expected output on success is "Success!" below. On failure a list of differences
- between expected and actual output will be shown.
- </p>
-
- <div id="console">
-
- </div>
- <script type="text/javascript">
- if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
- var failures = 0;
-
- function write(msg) {
- var n = document.createElement("div");
- n.appendChild(document.createTextNode(msg));
- document.getElementById("console").appendChild(n);
- }
-
- function expect(expected, input, actual) {
- if (expected != actual) {
- write("Expected " + expected + " for " + input + " but got " + actual);
- failures++;
- }
- }
-
- var expectedUTC = [1104537600000, 1107216000000, 1109635200000, 1112313600000,
- 1114905600000, 1117584000000, 1120176000000, 1122854400000,
- 1125532800000, 1128124800000, 1130803200000, 1133395200000,
- 1136073600000, 1138752000000, 1141171200000, 1143849600000,
- 1146441600000, 1149120000000, 1151712000000, 1154390400000,
- 1157068800000, 1159660800000, 1162339200000, 1164931200000,
- 1167609600000, 1170288000000, 1172707200000, 1175385600000,
- 1177977600000, 1180656000000, 1183248000000, 1185926400000,
- 1188604800000, 1191196800000, 1193875200000, 1196467200000];
-
- for (var i = 0; i < 36; i++) {
- var d = new Date(2005, i, 1);
- var input = 2005 + "-" + i;
- var expected = 2005 + Math.floor(i / 12) + "-" + (i % 12);
- var actual = d.getFullYear() + "-" + d.getMonth();
- expect(expected, input, actual);
- }
-
- for (var i = 0; i < 36; i++) {
- var u = Date.UTC(2005, i, 1);
- var input = 2005 + "-" + i;
- expect(expectedUTC[i], input, u);
- }
-
- if (! failures)
- write("Success!");
- </script>
- </body>
-</html>
\ No newline at end of file
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/date-big-constructor.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
+</html>
This test checks for regression against: 3381 Date.prototype.setDate() incorrect for values >=128.
-If the test passes, "Success" will be printed below.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS d.valueOf() - curValue is millisecondsPerDay
+PASS successfullyParsed is true
+
+TEST COMPLETE
-Success!
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<title>JavaScript Date tests -- setDate for values >= 128</title>
-<script type='text/javascript' charset='utf-8'>
-function print(message) {
- var paragraph = document.createElement("p");
- paragraph.appendChild(document.createTextNode(message));
- document.getElementById("console").appendChild(paragraph);
-}
-
-function test() {
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
-
- var validVars = false;
- var curValue;
- var success = true;
- var millisecondsPerDay = 1000 * 60 * 60 * 24;
-
- for (var i = 120; i < 130; i++) {
- var d = new Date(0);
- d.setDate(i);
-
- if (validVars &&
- d.valueOf() - curValue != millisecondsPerDay) {
- success = false;
- break;
- }
-
- curValue = d.valueOf();
- validVars = true;
- }
-
- if (success)
- print("Success!");
- else
- print("Failure!");
-}
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-<body onload="test();">
-<p>
-This test checks for regression against: <a href="http://bugzilla.opendarwin.org/show_bug.cgi?id=3381">
-3381 Date.prototype.setDate() incorrect for values >=128.</a>
-</p>
-<p>If the test passes, "Success" will be printed below.</p>
-<hr>
-<div id='console'/ style="font-family: courier; font-size: 12">
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/date-big-setdate.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
</html>
-This test checks for a regression against http://bugzilla.opendarwin.org/show_bug.cgi?id=4781 Date.setMonth fails with big values due to overflow.
+This test checks for a regression against Date.setMonth fails with big values due to overflow.
-If the test passes, you will see a "PASSED" message below.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS d.valueOf() is new Date(1980, 8, 1).valueOf()
+PASS successfullyParsed is true
+
+TEST COMPLETE
-PASSED: date is Mon Sep 01 1980
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<script>
-function print(message) {
- var paragraph = document.createElement("p");
- paragraph.appendChild(document.createTextNode(message));
- document.getElementById("console").appendChild(paragraph);
-}
-
-function test() {
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
-
- var d = new Date(1970, 0, 1);
- var status = "FAILED: ";
- d.setMonth(128);
- if (d.valueOf() == new Date(1980, 8, 1).valueOf()) {
- status = "PASSED: ";
- }
- print(status + "date is " + d.toDateString());
-}
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-<body onload="test();">
-<p>This test checks for a regression against <i>http://bugzilla.opendarwin.org/show_bug.cgi?id=4781 Date.setMonth fails with big values due to overflow</i>.</p>
-<p>If the test passes, you will see a "PASSED" message below.</p>
-<hr>
-<div id='console'/>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/date-big-setmonth.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
</html>
-This test checks for a regression against http://bugzilla.opendarwin.org/show_bug.cgi?id=5280 Date.setMonth fails with negative values.
+This test checks for a regression against Date.setMonth fails with negative values.
-If the test passes, you will see a "PASSED" message below.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS d.valueOf() is new Date(2004, 9, 15).valueOf()
+PASS successfullyParsed is true
+
+TEST COMPLETE
-PASSED: date is Fri Oct 15 2004
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<script>
-function print(message) {
- var paragraph = document.createElement("p");
- paragraph.appendChild(document.createTextNode(message));
- document.getElementById("console").appendChild(paragraph);
-}
-
-function test() {
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
-
- var d = new Date(2005, 6, 15);
- var status = "FAILED: ";
- d.setMonth(-3);
- if (d.valueOf() == new Date(2004, 9, 15).valueOf()) {
- status = "PASSED: ";
- }
- print(status + "date is " + d.toDateString());
-}
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-<body onload="test();">
-<p>This test checks for a regression against <i>http://bugzilla.opendarwin.org/show_bug.cgi?id=5280 Date.setMonth fails with negative values</i>.</p>
-<p>If the test passes, you will see a "PASSED" message below.</p>
-<hr>
-<div id='console'/>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/date-negative-setmonth.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
</html>
-Testing complete. No failures.
+test of JavaScript date parsing (comments in parentheses)
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS Date.parse("Dec ((27) 26 (24)) 25 1995 1:30 PM UTC") is 819898200000
+PASS Date.parse("DEC ((27) 26 (24)) 25 1995 1:30 PM UTC") is 819898200000
+PASS Date.parse("dec ((27) 26 (24)) 25 1995 1:30 pm utc") is 819898200000
+PASS Date.parse("Dec 25 1995 1:30 PM UTC (") is 819898200000
+PASS Date.parse("DEC 25 1995 1:30 PM UTC (") is 819898200000
+PASS Date.parse("dec 25 1995 1:30 pm utc (") is 819898200000
+PASS Date.parse("Dec 25 1995 1:30 (PM)) UTC") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 (PM)) UTC") is NaN.
+PASS Date.parse("dec 25 1995 1:30 (pm)) utc") is NaN.
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) GMT (EST)") is 819849600000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) GMT (EST)") is 819849600000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) gmt (est)") is 819849600000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996)") is 819878400000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996)") is 819878400000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996)") is 819878400000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 (1:40) GMT (EST)") is 819855000000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 1:30 (1:40) GMT (EST)") is 819855000000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 1:30 (1:40) gmt (est)") is 819855000000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 (1:40)") is 819883800000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 1:30 (1:40)") is 819883800000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 1:30 (1:40)") is 819883800000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 ") is 819883800000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 1:30 ") is 819883800000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 1:30 ") is 819883800000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 AM (1:40 PM) GMT (EST)") is 819855000000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 1:30 AM (1:40 PM) GMT (EST)") is 819855000000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 1:30 am (1:40 pm) gmt (est)") is 819855000000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 AM (1:40 PM)") is 819883800000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 1:30 AM (1:40 PM)") is 819883800000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 1:30 am (1:40 pm)") is 819883800000
+PASS Date.parse("Dec 25 1995 1:30( )AM (PM)") is NaN.
+PASS Date.parse("DEC 25 1995 1:30( )AM (PM)") is NaN.
+PASS Date.parse("dec 25 1995 1:30( )am (pm)") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 AM (PM)") is 819883800000
+PASS Date.parse("DEC 25 1995 1:30 AM (PM)") is 819883800000
+PASS Date.parse("dec 25 1995 1:30 am (pm)") is 819883800000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 13:30 (13:40) GMT (PST)") is 819898200000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 13:30 (13:40) GMT (PST)") is 819898200000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 13:30 (13:40) gmt (pst)") is 819898200000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 13:30 (13:40)") is 819927000000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 13:30 (13:40)") is 819927000000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 13:30 (13:40)") is 819927000000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 13:30 (13:40) 1995 (1996)") is 819927000000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 13:30 (13:40) 1995 (1996)") is 819927000000
+PASS Date.parse("(nov) dec (24) 25 (26) 13:30 (13:40) 1995 (1996)") is 819927000000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 13:30 (13:40) ") is 819927000000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 13:30 (13:40) ") is 819927000000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 13:30 (13:40) ") is 819927000000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 (1:40) PM (AM) GMT (PST)") is 819898200000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 1:30 (1:40) PM (AM) GMT (PST)") is 819898200000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 1:30 (1:40) pm (am) gmt (pst)") is 819898200000
+PASS Date.parse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 (1:40) PM (AM)") is 819927000000
+PASS Date.parse("(NOV) DEC (24) 25 (26) 1995 (1996) 1:30 (1:40) PM (AM)") is 819927000000
+PASS Date.parse("(nov) dec (24) 25 (26) 1995 (1996) 1:30 (1:40) pm (am)") is 819927000000
+PASS Date.parse("Dec 25 1995 1:30(AM)PM") is NaN.
+PASS Date.parse("DEC 25 1995 1:30(AM)PM") is NaN.
+PASS Date.parse("dec 25 1995 1:30(am)pm") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 (AM)PM ") is 819927000000
+PASS Date.parse("DEC 25 1995 1:30 (AM)PM ") is 819927000000
+PASS Date.parse("dec 25 1995 1:30 (am)pm ") is 819927000000
+PASS Date.parse("Dec 25 1995 (PDT)UTC(PST)") is 819849600000
+PASS Date.parse("DEC 25 1995 (PDT)UTC(PST)") is 819849600000
+PASS Date.parse("dec 25 1995 (pdt)utc(pst)") is 819849600000
+PASS Date.parse("Dec 25 1995 (PDT)UT(PST)") is 819849600000
+PASS Date.parse("DEC 25 1995 (PDT)UT(PST)") is 819849600000
+PASS Date.parse("dec 25 1995 (pdt)ut(pst)") is 819849600000
+PASS Date.parse("Dec 25 1995 (UTC)PST(GMT)") is 819878400000
+PASS Date.parse("DEC 25 1995 (UTC)PST(GMT)") is 819878400000
+PASS Date.parse("dec 25 1995 (utc)pst(gmt)") is 819878400000
+PASS Date.parse("Dec 25 1995 (UTC)PDT(GMT)") is 819874800000
+PASS Date.parse("DEC 25 1995 (UTC)PDT(GMT)") is 819874800000
+PASS Date.parse("dec 25 1995 (utc)pdt(gmt)") is 819874800000
+PASS Date.parse("Dec 25 1995 1:30 (PDT)UTC(PST)") is 819855000000
+PASS Date.parse("DEC 25 1995 1:30 (PDT)UTC(PST)") is 819855000000
+PASS Date.parse("dec 25 1995 1:30 (pdt)utc(pst)") is 819855000000
+PASS Date.parse("Dec 25 1995 1:30 (PDT)UT(PST)") is 819855000000
+PASS Date.parse("DEC 25 1995 1:30 (PDT)UT(PST)") is 819855000000
+PASS Date.parse("dec 25 1995 1:30 (pdt)ut(pst)") is 819855000000
+PASS Date.parse("Dec 25 1995 1:30 (UTC)PST(GMT)") is 819883800000
+PASS Date.parse("DEC 25 1995 1:30 (UTC)PST(GMT)") is 819883800000
+PASS Date.parse("dec 25 1995 1:30 (utc)pst(gmt)") is 819883800000
+PASS Date.parse("Dec 25 1995 1:30 (UTC)PDT(GMT)") is 819880200000
+PASS Date.parse("DEC 25 1995 1:30 (UTC)PDT(GMT)") is 819880200000
+PASS Date.parse("dec 25 1995 1:30 (utc)pdt(gmt)") is 819880200000
+PASS Date.parse("Dec 25 1995 1:30 (AM) PM (PST) UTC") is 819898200000
+PASS Date.parse("DEC 25 1995 1:30 (AM) PM (PST) UTC") is 819898200000
+PASS Date.parse("dec 25 1995 1:30 (am) pm (pst) utc") is 819898200000
+PASS Date.parse("Dec 25 1995 1:30 PM (AM) (PST) UT") is 819898200000
+PASS Date.parse("DEC 25 1995 1:30 PM (AM) (PST) UT") is 819898200000
+PASS Date.parse("dec 25 1995 1:30 pm (am) (pst) ut") is 819898200000
+PASS Date.parse("Dec 25 1995 1:30 PM (AM) (UTC) PST") is 819927000000
+PASS Date.parse("DEC 25 1995 1:30 PM (AM) (UTC) PST") is 819927000000
+PASS Date.parse("dec 25 1995 1:30 pm (am) (utc) pst") is 819927000000
+PASS Date.parse("Dec 25 1995 1:30 (AM) PM PDT (UTC)") is 819923400000
+PASS Date.parse("DEC 25 1995 1:30 (AM) PM PDT (UTC)") is 819923400000
+PASS Date.parse("dec 25 1995 1:30 (am) pm pdt (utc)") is 819923400000
+PASS Date.parse("Dec 25 1995 XXX (GMT)") is NaN.
+PASS Date.parse("DEC 25 1995 XXX (GMT)") is NaN.
+PASS Date.parse("dec 25 1995 xxx (gmt)") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 XXX (GMT)") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 XXX (GMT)") is NaN.
+PASS Date.parse("dec 25 1995 1:30 xxx (gmt)") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 U(TC)") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 U(TC)") is NaN.
+PASS Date.parse("dec 25 1995 1:30 u(tc)") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 V(UTC)") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 V(UTC)") is NaN.
+PASS Date.parse("dec 25 1995 1:30 v(utc)") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 (UTC)W") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 (UTC)W") is NaN.
+PASS Date.parse("dec 25 1995 1:30 (utc)w") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 (GMT)X") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 (GMT)X") is NaN.
+PASS Date.parse("dec 25 1995 1:30 (gmt)x") is NaN.
+PASS Date.parse("Dec 25 1995 0:30 (PM) GMT") is 819851400000
+PASS Date.parse("DEC 25 1995 0:30 (PM) GMT") is 819851400000
+PASS Date.parse("dec 25 1995 0:30 (pm) gmt") is 819851400000
+PASS Date.parse("Dec 25 1995 (1)0:30 AM GMT") is 819851400000
+PASS Date.parse("DEC 25 1995 (1)0:30 AM GMT") is 819851400000
+PASS Date.parse("dec 25 1995 (1)0:30 am gmt") is 819851400000
+PASS Date.parse("Dec 25 1995 (1)0:30 PM GMT") is 819894600000
+PASS Date.parse("DEC 25 1995 (1)0:30 PM GMT") is 819894600000
+PASS Date.parse("dec 25 1995 (1)0:30 pm gmt") is 819894600000
+PASS Date.parse("Anf(Dec) 25 1995 GMT") is NaN.
+PASS Date.parse("ANF(DEC) 25 1995 GMT") is NaN.
+PASS Date.parse("anf(dec) 25 1995 gmt") is NaN.
+PASS Date.parse("(Sat) Wed (Nov) Dec (Nov) 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("(SAT) WED (NOV) DEC (NOV) 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("(sat) wed (nov) dec (nov) 25 1995 1:30 gmt") is 819855000000
+PASS Date.parse("Wed (comment 1) (comment 2) Dec 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("WED (COMMENT 1) (COMMENT 2) DEC 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("wed (comment 1) (comment 2) dec 25 1995 1:30 gmt") is 819855000000
+PASS Date.parse("Wed(comment 1) (comment 2) Dec 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("WED(COMMENT 1) (COMMENT 2) DEC 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("wed(comment 1) (comment 2) dec 25 1995 1:30 gmt") is 819855000000
+PASS Date.parse("We(comment 1) (comment 2) Dec 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("WE(COMMENT 1) (COMMENT 2) DEC 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("we(comment 1) (comment 2) dec 25 1995 1:30 gmt") is 819855000000
+PASS successfullyParsed is true
+
+TEST COMPLETE
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
-
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
-
<head>
-<meta http-equiv="content-type" content="text/html; charset=UTF-8">
-<title>test of JavaScript date parsing (comments in parentheses)</title>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-
<body>
-
-<script type="text/javascript">
-
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-// --------
-
-// Helper functions.
-
-function call(functionName, parameter)
-{
- try {
- result = eval(functionName + "(parameter)");
- } catch (e) {
- result = "exception";
- }
- return result;
-}
-
-// --------
-
-// Run tests.
-
-var failureCount = 0;
-
-function test(functionName, parameter, desiredResult)
-{
- var result = call(functionName, parameter);
- if (result != desiredResult && !(isNaN(result) && isNaN(desiredResult))) {
- var s = "called " + functionName + " on " + parameter + " and got " + result + " instead of " + desiredResult;
- document.writeln("<p>" + s + "</p>");
- failureCount += 1;
- return 0;
- }
- return 1;
-}
-
-function testDateParse(date, numericResult)
-{
- if (test("Date.parse", date, numericResult)) {
- test("Date.parse", date.toUpperCase(), numericResult);
- test("Date.parse", date.toLowerCase(), numericResult);
- }
-}
-
-var o = Date.parse(" Dec 25 1995 1:30 ") - Date.parse(" Dec 25 1995 1:30 GMT ");
-
-testDateParse("Dec ((27) 26 (24)) 25 1995 1:30 PM UTC", 819898200000);
-testDateParse("Dec 25 1995 1:30 PM UTC (", 819898200000);
-testDateParse("Dec 25 1995 1:30 (PM)) UTC", NaN);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) GMT (EST)", 819849600000);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996)", 819849600000 + o);
-
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 (1:40) GMT (EST)", 819855000000);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 (1:40)", 819855000000 + o);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 ", 819855000000 + o);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 AM (1:40 PM) GMT (EST)", 819855000000);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 AM (1:40 PM)", 819855000000 + o);
-testDateParse("Dec 25 1995 1:30( )AM (PM)", NaN);
-testDateParse("Dec 25 1995 1:30 AM (PM)", 819855000000 + o);
-
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 13:30 (13:40) GMT (PST)", 819898200000);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 13:30 (13:40)", 819898200000 + o);
-testDateParse('(Nov) Dec (24) 25 (26) 13:30 (13:40) 1995 (1996)', 819898200000 + o);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 13:30 (13:40) ", 819898200000 + o);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 (1:40) PM (AM) GMT (PST)", 819898200000);
-testDateParse("(Nov) Dec (24) 25 (26) 1995 (1996) 1:30 (1:40) PM (AM)", 819898200000 + o);
-testDateParse("Dec 25 1995 1:30(AM)PM", NaN);
-testDateParse("Dec 25 1995 1:30 (AM)PM ", 819898200000 + o);
-
-testDateParse("Dec 25 1995 (PDT)UTC(PST)", 819849600000);
-testDateParse("Dec 25 1995 (PDT)UT(PST)", 819849600000);
-testDateParse("Dec 25 1995 (UTC)PST(GMT)", 819878400000);
-testDateParse("Dec 25 1995 (UTC)PDT(GMT)", 819874800000);
-
-testDateParse("Dec 25 1995 1:30 (PDT)UTC(PST)", 819855000000);
-testDateParse("Dec 25 1995 1:30 (PDT)UT(PST)", 819855000000);
-testDateParse("Dec 25 1995 1:30 (UTC)PST(GMT)", 819883800000);
-testDateParse("Dec 25 1995 1:30 (UTC)PDT(GMT)", 819880200000);
-
-testDateParse("Dec 25 1995 1:30 (AM) PM (PST) UTC", 819898200000);
-testDateParse("Dec 25 1995 1:30 PM (AM) (PST) UT", 819898200000);
-testDateParse("Dec 25 1995 1:30 PM (AM) (UTC) PST", 819927000000);
-testDateParse("Dec 25 1995 1:30 (AM) PM PDT (UTC)", 819923400000);
-
-testDateParse("Dec 25 1995 XXX (GMT)", NaN);
-testDateParse("Dec 25 1995 1:30 XXX (GMT)", NaN);
-
-testDateParse("Dec 25 1995 1:30 U(TC)", NaN);
-testDateParse("Dec 25 1995 1:30 V(UTC)", NaN);
-testDateParse("Dec 25 1995 1:30 (UTC)W", NaN);
-testDateParse("Dec 25 1995 1:30 (GMT)X", NaN);
-
-testDateParse("Dec 25 1995 0:30 (PM) GMT", 819851400000);
-testDateParse("Dec 25 1995 (1)0:30 AM GMT", 819851400000);
-testDateParse("Dec 25 1995 (1)0:30 PM GMT", 819894600000);
-
-testDateParse("Anf(Dec) 25 1995 GMT", NaN);
-
-testDateParse("(Sat) Wed (Nov) Dec (Nov) 25 1995 1:30 GMT", 819855000000);
-testDateParse("Wed (comment 1) (comment 2) Dec 25 1995 1:30 GMT", 819855000000);
-testDateParse("Wed(comment 1) (comment 2) Dec 25 1995 1:30 GMT", 819855000000);
-testDateParse("We(comment 1) (comment 2) Dec 25 1995 1:30 GMT", 819855000000);
-
-// --------
-
-// Summarize.
-
-var failuresMessage;
-if (failureCount) {
- failuresMessage = failureCount + " tests failed.";
-} else {
- failuresMessage = "No failures.";
-}
-document.writeln("<p>Testing complete. " + failuresMessage + "</p>");
-
-// --------
-
-</script>
-
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/date-parse-comments-test.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
-
</html>
-Testing complete. No failures.
+Test of JavaScript date parsing.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS Date.parse("Dec 25 1995 GMT") is 819849600000
+PASS Date.parse("DEC 25 1995 GMT") is 819849600000
+PASS Date.parse("dec 25 1995 gmt") is 819849600000
+PASS Date.parse("Dec 25 1995") is 819878400000
+PASS Date.parse("DEC 25 1995") is 819878400000
+PASS Date.parse("dec 25 1995") is 819878400000
+PASS Date.parse("Dec 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("DEC 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("dec 25 1995 1:30 gmt") is 819855000000
+PASS Date.parse("Dec 25 1995 1:30") is 819883800000
+PASS Date.parse("DEC 25 1995 1:30") is 819883800000
+PASS Date.parse("dec 25 1995 1:30") is 819883800000
+PASS Date.parse("Dec 25 1995 1:30 ") is 819883800000
+PASS Date.parse("DEC 25 1995 1:30 ") is 819883800000
+PASS Date.parse("dec 25 1995 1:30 ") is 819883800000
+PASS Date.parse("Dec 25 1995 1:30 AM GMT") is 819855000000
+PASS Date.parse("DEC 25 1995 1:30 AM GMT") is 819855000000
+PASS Date.parse("dec 25 1995 1:30 am gmt") is 819855000000
+PASS Date.parse("Dec 25 1995 1:30 AM") is 819883800000
+PASS Date.parse("DEC 25 1995 1:30 AM") is 819883800000
+PASS Date.parse("dec 25 1995 1:30 am") is 819883800000
+PASS Date.parse("Dec 25 1995 1:30AM") is NaN.
+PASS Date.parse("DEC 25 1995 1:30AM") is NaN.
+PASS Date.parse("dec 25 1995 1:30am") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 AM ") is 819883800000
+PASS Date.parse("DEC 25 1995 1:30 AM ") is 819883800000
+PASS Date.parse("dec 25 1995 1:30 am ") is 819883800000
+PASS Date.parse("Dec 25 1995 13:30 GMT") is 819898200000
+PASS Date.parse("DEC 25 1995 13:30 GMT") is 819898200000
+PASS Date.parse("dec 25 1995 13:30 gmt") is 819898200000
+PASS Date.parse("Dec 25 1995 13:30") is 819927000000
+PASS Date.parse("DEC 25 1995 13:30") is 819927000000
+PASS Date.parse("dec 25 1995 13:30") is 819927000000
+PASS Date.parse("Dec 25 13:30 1995") is 819927000000
+PASS Date.parse("DEC 25 13:30 1995") is 819927000000
+PASS Date.parse("dec 25 13:30 1995") is 819927000000
+PASS Date.parse("Dec 25 1995 13:30 ") is 819927000000
+PASS Date.parse("DEC 25 1995 13:30 ") is 819927000000
+PASS Date.parse("dec 25 1995 13:30 ") is 819927000000
+PASS Date.parse("Dec 25 1995 1:30 PM GMT") is 819898200000
+PASS Date.parse("DEC 25 1995 1:30 PM GMT") is 819898200000
+PASS Date.parse("dec 25 1995 1:30 pm gmt") is 819898200000
+PASS Date.parse("Dec 25 1995 1:30 PM") is 819927000000
+PASS Date.parse("DEC 25 1995 1:30 PM") is 819927000000
+PASS Date.parse("dec 25 1995 1:30 pm") is 819927000000
+PASS Date.parse("Dec 25 1995 1:30PM") is NaN.
+PASS Date.parse("DEC 25 1995 1:30PM") is NaN.
+PASS Date.parse("dec 25 1995 1:30pm") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 PM ") is 819927000000
+PASS Date.parse("DEC 25 1995 1:30 PM ") is 819927000000
+PASS Date.parse("dec 25 1995 1:30 pm ") is 819927000000
+PASS Date.parse("Dec 25 1995 UTC") is 819849600000
+PASS Date.parse("DEC 25 1995 UTC") is 819849600000
+PASS Date.parse("dec 25 1995 utc") is 819849600000
+PASS Date.parse("Dec 25 1995 UT") is 819849600000
+PASS Date.parse("DEC 25 1995 UT") is 819849600000
+PASS Date.parse("dec 25 1995 ut") is 819849600000
+PASS Date.parse("Dec 25 1995 PST") is 819878400000
+PASS Date.parse("DEC 25 1995 PST") is 819878400000
+PASS Date.parse("dec 25 1995 pst") is 819878400000
+PASS Date.parse("Dec 25 1995 PDT") is 819874800000
+PASS Date.parse("DEC 25 1995 PDT") is 819874800000
+PASS Date.parse("dec 25 1995 pdt") is 819874800000
+PASS Date.parse("Dec 25 1995 1:30 UTC") is 819855000000
+PASS Date.parse("DEC 25 1995 1:30 UTC") is 819855000000
+PASS Date.parse("dec 25 1995 1:30 utc") is 819855000000
+PASS Date.parse("Dec 25 1995 1:30 UT") is 819855000000
+PASS Date.parse("DEC 25 1995 1:30 UT") is 819855000000
+PASS Date.parse("dec 25 1995 1:30 ut") is 819855000000
+PASS Date.parse("Dec 25 1995 1:30 PST") is 819883800000
+PASS Date.parse("DEC 25 1995 1:30 PST") is 819883800000
+PASS Date.parse("dec 25 1995 1:30 pst") is 819883800000
+PASS Date.parse("Dec 25 1995 1:30 PDT") is 819880200000
+PASS Date.parse("DEC 25 1995 1:30 PDT") is 819880200000
+PASS Date.parse("dec 25 1995 1:30 pdt") is 819880200000
+PASS Date.parse("Dec 25 1995 1:30 PM UTC") is 819898200000
+PASS Date.parse("DEC 25 1995 1:30 PM UTC") is 819898200000
+PASS Date.parse("dec 25 1995 1:30 pm utc") is 819898200000
+PASS Date.parse("Dec 25 1995 1:30 PM UT") is 819898200000
+PASS Date.parse("DEC 25 1995 1:30 PM UT") is 819898200000
+PASS Date.parse("dec 25 1995 1:30 pm ut") is 819898200000
+PASS Date.parse("Dec 25 1995 1:30 PM PST") is 819927000000
+PASS Date.parse("DEC 25 1995 1:30 PM PST") is 819927000000
+PASS Date.parse("dec 25 1995 1:30 pm pst") is 819927000000
+PASS Date.parse("Dec 25 1995 1:30 PM PDT") is 819923400000
+PASS Date.parse("DEC 25 1995 1:30 PM PDT") is 819923400000
+PASS Date.parse("dec 25 1995 1:30 pm pdt") is 819923400000
+PASS Date.parse("Dec 25 1995 XXX") is NaN.
+PASS Date.parse("DEC 25 1995 XXX") is NaN.
+PASS Date.parse("dec 25 1995 xxx") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 XXX") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 XXX") is NaN.
+PASS Date.parse("dec 25 1995 1:30 xxx") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 U") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 U") is NaN.
+PASS Date.parse("dec 25 1995 1:30 u") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 V") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 V") is NaN.
+PASS Date.parse("dec 25 1995 1:30 v") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 W") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 W") is NaN.
+PASS Date.parse("dec 25 1995 1:30 w") is NaN.
+PASS Date.parse("Dec 25 1995 1:30 X") is NaN.
+PASS Date.parse("DEC 25 1995 1:30 X") is NaN.
+PASS Date.parse("dec 25 1995 1:30 x") is NaN.
+PASS Date.parse("Dec 25 1995 0:30 GMT") is 819851400000
+PASS Date.parse("DEC 25 1995 0:30 GMT") is 819851400000
+PASS Date.parse("dec 25 1995 0:30 gmt") is 819851400000
+PASS Date.parse("Dec 25 1995 0:30 AM GMT") is 819851400000
+PASS Date.parse("DEC 25 1995 0:30 AM GMT") is 819851400000
+PASS Date.parse("dec 25 1995 0:30 am gmt") is 819851400000
+PASS Date.parse("Dec 25 1995 0:30 PM GMT") is 819894600000
+PASS Date.parse("DEC 25 1995 0:30 PM GMT") is 819894600000
+PASS Date.parse("dec 25 1995 0:30 pm gmt") is 819894600000
+PASS Date.parse("Dec 25 1995 12:30 AM GMT") is 819851400000
+PASS Date.parse("DEC 25 1995 12:30 AM GMT") is 819851400000
+PASS Date.parse("dec 25 1995 12:30 am gmt") is 819851400000
+PASS Date.parse("Dec 25 1995 12:30 PM GMT") is 819894600000
+PASS Date.parse("DEC 25 1995 12:30 PM GMT") is 819894600000
+PASS Date.parse("dec 25 1995 12:30 pm gmt") is 819894600000
+PASS Date.parse("Dec 25 1995 13:30 AM GMT") is NaN.
+PASS Date.parse("DEC 25 1995 13:30 AM GMT") is NaN.
+PASS Date.parse("dec 25 1995 13:30 am gmt") is NaN.
+PASS Date.parse("Dec 25 1995 13:30 PM GMT") is NaN.
+PASS Date.parse("DEC 25 1995 13:30 PM GMT") is NaN.
+PASS Date.parse("dec 25 1995 13:30 pm gmt") is NaN.
+PASS Date.parse("Anf 25 1995 GMT") is NaN.
+PASS Date.parse("ANF 25 1995 GMT") is NaN.
+PASS Date.parse("anf 25 1995 gmt") is NaN.
+PASS Date.parse("Wed Dec 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("WED DEC 25 1995 1:30 GMT") is 819855000000
+PASS Date.parse("wed dec 25 1995 1:30 gmt") is 819855000000
+PASS Date.parse("Dec 25" + String.fromCharCode(9) + "1995 13:30 GMT") is 819898200000
+PASS Date.parse(("Dec 25" + String.fromCharCode(9) + "1995 13:30 GMT").toUpperCase()) is 819898200000
+PASS Date.parse(("Dec 25" + String.fromCharCode(9) + "1995 13:30 GMT").toLowerCase()) is 819898200000
+PASS Date.parse("Dec 25" + String.fromCharCode(10) + "1995 13:30 GMT") is 819898200000
+PASS Date.parse(("Dec 25" + String.fromCharCode(10) + "1995 13:30 GMT").toUpperCase()) is 819898200000
+PASS Date.parse(("Dec 25" + String.fromCharCode(10) + "1995 13:30 GMT").toLowerCase()) is 819898200000
+PASS successfullyParsed is true
+
+TEST COMPLETE
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
-
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
-
<head>
-<meta http-equiv="content-type" content="text/html; charset=UTF-8">
-<title>test of JavaScript date parsing</title>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-
<body>
-
-<script type="text/javascript">
-
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-// --------
-
-// Helper functions.
-
-function call(functionName, parameter)
-{
- try {
- result = eval(functionName + "(parameter)");
- } catch (e) {
- result = "exception";
- }
- return result;
-}
-
-// --------
-
-// Run tests.
-
-var failureCount = 0;
-
-function test(functionName, parameter, desiredResult)
-{
- var result = call(functionName, parameter);
- if (result != desiredResult && !(isNaN(result) && isNaN(desiredResult))) {
- var s = "called " + functionName + " on " + parameter + " and got " + result + " instead of " + desiredResult;
- document.writeln("<p>" + s + "</p>");
- failureCount += 1;
- return 0;
- }
- return 1;
-}
-
-function testDateParse(date, numericResult)
-{
- if (test("Date.parse", date, numericResult)) {
- test("Date.parse", date.toUpperCase(), numericResult);
- test("Date.parse", date.toLowerCase(), numericResult);
- }
-}
-
-var o = Date.parse(" Dec 25 1995 1:30 ") - Date.parse(" Dec 25 1995 1:30 GMT ");
-
-testDateParse("Dec 25 1995 GMT", 819849600000);
-testDateParse("Dec 25 1995", 819849600000 + o);
-
-testDateParse("Dec 25 1995 1:30 GMT", 819855000000);
-testDateParse("Dec 25 1995 1:30", 819855000000 + o);
-testDateParse("Dec 25 1995 1:30 ", 819855000000 + o);
-testDateParse("Dec 25 1995 1:30 AM GMT", 819855000000);
-testDateParse("Dec 25 1995 1:30 AM", 819855000000 + o);
-testDateParse("Dec 25 1995 1:30AM", NaN);
-testDateParse("Dec 25 1995 1:30 AM ", 819855000000 + o);
-
-testDateParse("Dec 25 1995 13:30 GMT", 819898200000);
-testDateParse("Dec 25 1995 13:30", 819898200000 + o);
-testDateParse('Dec 25 13:30 1995', 819898200000 + o);
-testDateParse("Dec 25 1995 13:30 ", 819898200000 + o);
-testDateParse("Dec 25 1995 1:30 PM GMT", 819898200000);
-testDateParse("Dec 25 1995 1:30 PM", 819898200000 + o);
-testDateParse("Dec 25 1995 1:30PM", NaN);
-testDateParse("Dec 25 1995 1:30 PM ", 819898200000 + o);
-
-testDateParse("Dec 25 1995 UTC", 819849600000);
-testDateParse("Dec 25 1995 UT", 819849600000);
-testDateParse("Dec 25 1995 PST", 819878400000);
-testDateParse("Dec 25 1995 PDT", 819874800000);
-
-testDateParse("Dec 25 1995 1:30 UTC", 819855000000);
-testDateParse("Dec 25 1995 1:30 UT", 819855000000);
-testDateParse("Dec 25 1995 1:30 PST", 819883800000);
-testDateParse("Dec 25 1995 1:30 PDT", 819880200000);
-
-testDateParse("Dec 25 1995 1:30 PM UTC", 819898200000);
-testDateParse("Dec 25 1995 1:30 PM UT", 819898200000);
-testDateParse("Dec 25 1995 1:30 PM PST", 819927000000);
-testDateParse("Dec 25 1995 1:30 PM PDT", 819923400000);
-
-testDateParse("Dec 25 1995 XXX", NaN);
-testDateParse("Dec 25 1995 1:30 XXX", NaN);
-
-testDateParse("Dec 25 1995 1:30 U", NaN);
-testDateParse("Dec 25 1995 1:30 V", NaN);
-testDateParse("Dec 25 1995 1:30 W", NaN);
-testDateParse("Dec 25 1995 1:30 X", NaN);
-
-testDateParse("Dec 25 1995 0:30 GMT", 819851400000);
-testDateParse("Dec 25 1995 0:30 AM GMT", 819851400000);
-testDateParse("Dec 25 1995 0:30 PM GMT", 819894600000);
-testDateParse("Dec 25 1995 12:30 AM GMT", 819851400000);
-testDateParse("Dec 25 1995 12:30 PM GMT", 819894600000);
-testDateParse("Dec 25 1995 13:30 AM GMT", NaN);
-testDateParse("Dec 25 1995 13:30 PM GMT", NaN);
-
-testDateParse("Anf 25 1995 GMT", NaN);
-
-testDateParse("Wed Dec 25 1995 1:30 GMT", 819855000000);
-
-testDateParse("Dec 25" + String.fromCharCode(9) + "1995 13:30 GMT", 819898200000);
-testDateParse("Dec 25" + String.fromCharCode(10) + "1995 13:30 GMT", 819898200000);
-
-// --------
-
-// Summarize.
-
-var failuresMessage;
-if (failureCount) {
- failuresMessage = failureCount + " tests failed.";
-} else {
- failuresMessage = "No failures.";
-}
-document.writeln("<p>Testing complete. " + failuresMessage + "</p>");
-
-// --------
-
-</script>
-
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/date-parse-test.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
-
</html>
The following test checks if an existing milliseconds value gets preserved if a call to setHours(), setMinutes() or setSeconds() does not specify the milliseconds. See http://bugzilla.opendarwin.org/show_bug.cgi?id=3759
-If the test passes, you will see "SUCCESS" messages below.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-SUCCESS: Expected milliseconds: 1 Actual milliseconds: 1
-SUCCESS: Expected milliseconds: 1 Actual milliseconds: 1
+PASS d.getMilliseconds() is 1
+PASS d.getMilliseconds() is 1
+PASS d.getMilliseconds() is 1
+PASS d.getMilliseconds() is 1
+PASS d.getMilliseconds() is 1
+PASS d.getMilliseconds() is 1
+PASS successfullyParsed is true
-SUCCESS: Expected milliseconds: 1 Actual milliseconds: 1
+TEST COMPLETE
-SUCCESS: Expected milliseconds: 1 Actual milliseconds: 1
-
-SUCCESS: Expected milliseconds: 1 Actual milliseconds: 1
-
-SUCCESS: Expected milliseconds: 1 Actual milliseconds: 1
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<title>JavaScript Date tests -- Millisecond Preservation</title>
-<script type='text/javascript' charset='utf-8'>
-function print(message) {
- var paragraph = document.createElement("p");
- paragraph.appendChild(document.createTextNode(message));
- document.getElementById("console").appendChild(paragraph);
-}
-
-function test() {
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
-
- var d = new Date(0);
- var result = "";
-
- // make sure we have a date with ms > 0
- d.setMilliseconds(1);
-
- var oldValue = d.getMilliseconds();
-
- d.setHours(8);
- var newValue = d.getMilliseconds();
- result = (oldValue == newValue) ? "SUCCESS: " : "FAILURE ";
- result += "Expected milliseconds: " + oldValue + " ";
- result += "Actual milliseconds: " + newValue;
- print(result);
-
- d.setHours(8, 30);
- result = (oldValue == newValue) ? "SUCCESS: " : "FAILURE ";
- result += "Expected milliseconds: " + oldValue + " ";
- result += "Actual milliseconds: " + newValue;
- print(result);
-
- d.setHours(8, 30, 40);
- newValue = d.getMilliseconds();
- result = (oldValue == newValue) ? "SUCCESS: " : "FAILURE ";
- result += "Expected milliseconds: " + oldValue + " ";
- result += "Actual milliseconds: " + newValue;
- print(result);
-
- d.setMinutes(45);
- newValue = d.getMilliseconds();
- result = (oldValue == newValue) ? "SUCCESS: " : "FAILURE ";
- result += "Expected milliseconds: " + oldValue + " ";
- result += "Actual milliseconds: " + newValue;
- print(result);
-
- d.setMinutes(45, 40);
- newValue = d.getMilliseconds();
- result = (oldValue == newValue) ? "SUCCESS: " : "FAILURE ";
- result += "Expected milliseconds: " + oldValue + " ";
- result += "Actual milliseconds: " + newValue;
- print(result);
-
- d.setSeconds(50);
- newValue = d.getMilliseconds();
- result = (oldValue == newValue) ? "SUCCESS: " : "FAILURE ";
- result += "Expected milliseconds: " + oldValue + " ";
- result += "Actual milliseconds: " + newValue;
- print(result);
-}
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-<body onload="test();">
-<p>
-The following test checks if an existing milliseconds value gets preserved if a call
-to setHours(), setMinutes() or setSeconds() does not specify the milliseconds.
-See http://bugzilla.opendarwin.org/show_bug.cgi?id=3759
-</p>
-<p>If the test passes, you will see "SUCCESS" messages below.</p>
-<hr>
-<div id='console'/>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/date-preserve-milliseconds.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
</html>
-all is well
+This test checks that declarations in an if block can be seen outside it.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
-<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-if (0) { var b; }
-var a = b;
-document.write("all is well");
-</script>
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/declaration-in-block.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
+</html>
-This test checks whether various forms of delete expression are allowed. It should print the numbers 1-10 on separate lines, and nothing else (besides this paragraph).
+This test checks whether various forms of delete expression are allowed.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
-true
+
+PASS delete x is true
+PASS delete window.x is true
+PASS delete window["x"] is true
+PASS delete (x) is true
+PASS delete (window.x) is true
+PASS delete (window["x"]) is true
+PASS (y, delete x) is true
+PASS delete ((x)) is true
+PASS delete ((window.x)) is true
+PASS delete ((window["x"])) is true
+PASS delete (y, x) is true
+PASS delete (true ? x : y) is true
+PASS delete nonexistent is true
+PASS delete window.nonexistent is true
+PASS delete window["nonexistent"] is true
+PASS delete (nonexistent) is true
+PASS delete (window.nonexistent) is true
+PASS delete (window["nonexistent"]) is true
+PASS delete "x" is true
+PASS delete (2 + 3) is true
+PASS successfullyParsed is true
+
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
<body>
-<p>
-This test checks whether various forms of delete expression are
-allowed. It should print the numbers 1-10 on separate lines, and
-nothing else (besides this paragraph).
-<p>
-<hr>
-<pre id="console">
-</pre>
-<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function log(s)
-{
- document.getElementById('console').innerHTML += s + '<br>';
-}
-
-window.x = 0;
-window.y = 0;
-
-try { eval ('log(delete x);'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete window.x);'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete window["x"]);'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete (x));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete (window.x));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete (window["x"]));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log((y, delete x));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete ((x)));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete ((window.x)));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete ((window["x"])));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete (y, x));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-try { eval ('log(delete (true ? x : y));'); } catch (e) { log("FAIL"); }
-window.x = 0;
-window.y = 0;
-
-try { eval ('log(delete nonexistent)'); } catch (e) { log("FAIL"); }
-try { eval ('log(delete window.nonexistent)'); } catch (e) { log("FAIL"); }
-try { eval ('log(delete window["nonexistent"])'); } catch (e) { log("FAIL");}
-try { eval ('log(delete (nonexistent))'); } catch (e) { log("FAIL");}
-try { eval ('log(delete (window.nonexistent))'); } catch (e) { log("FAIL"); }
-try { eval ('log(delete (window["nonexistent"]))'); } catch (e) { log("FAIL"); }
-
-try { eval ('log(delete "x")'); } catch (e) { log("FAIL"); }
-try { eval ('log(delete (2 + 3))'); } catch (e) { log("FAIL"); }
-
-
-</script>
-
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/delete-syntax.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
+</html>
-This test case checks whether variables cause properties to be defined even before reaching the declaration statement in various cases. It should print true true true false on separate lines.
+This test case checks whether variables cause properties to be defined even before reaching the declaration statement in various cases.
-true
-true
-true
-false
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS hasOwnProperty("foo") is true
+PASS hasOwnProperty("bar") is true
+PASS firstEvalResult is true
+PASS secondEvalResult is false
+PASS successfullyParsed is true
+
+TEST COMPLETE
-<div>
-This test case checks whether variables cause properties to be
-defined even before reaching the declaration statement in various
-cases. It should print true true true false on separate lines.
-</div>
-<br>
-<div>
-<script>
-if (window.layoutTestController) {
- layoutTestController.dumpAsText();
-}
-
-document.write(window.hasOwnProperty('foo') + '<br>');
-var foo = 3;
-
-delete bar;
-document.write(window.hasOwnProperty('bar') + '<br>');
-var bar = 3;
-
-eval("document.write(window.hasOwnProperty('y') + '<br>'); var y = 3;");
-eval("delete x; document.write(window.hasOwnProperty('x') + '<br>'); var x = 3;");
-
-</script>
-</div>
\ No newline at end of file
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/eval-var-decl.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
+</html>
This test exercises the source URL and line number that is embedded in JavaScript exceptions, which is displayed in places like the JavaScript console.
-If the test passes, you should see five exceptions caught below, with the appropriate line number for each (increasing except for the last one).
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-Exception at line 37 with sourceURL set
-Exception at line 45 with sourceURL set
-Exception at line 53 with sourceURL set
-Exception at line 61 with sourceURL set
-Exception at line 13 with sourceURL set
+
+PASS typeof e.sourceURL is "string"
+PASS e.line is 12
+PASS typeof e.sourceURL is "string"
+PASS e.line is 22
+PASS typeof e.sourceURL is "string"
+PASS e.line is 32
+PASS typeof e.sourceURL is "string"
+PASS e.line is 42
+PASS typeof e.sourceURL is "string"
+PASS e.line is 5
+PASS successfullyParsed is true
+
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <head>
- <script type="text/javascript">
- function print(message)
- {
- var paragraph = document.createElement("li");
- paragraph.appendChild(document.createTextNode(message));
- document.getElementById("console").appendChild(paragraph);
- }
-
- function exceptionInFunction()
- {
- throw Exception();
- }
-
- function writeException(e)
- {
- var type = 'unset';
- if (e.sourceURL)
- type = 'set';
-
- print('Exception at line ' + e.line + ' with sourceURL ' + type);
- }
-
- function expectedException()
- {
- print('An exception was expected but not thrown.');
- }
-
- function test() {
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
-
- try {
- // Raises an exception that gets picked up by KJS_CHECKEXCEPTION
- document.documentElement.innerHTML(foo);
- expectedException();
- } catch (e) {
- writeException(e);
- }
-
- try {
- // Raises an exception that gets picked up by KJS_CHECKEXCEPTIONVALUE
- document.documentElement.appendChild('').prefix = '';
- expectedException();
- } catch (e) {
- writeException(e);
- }
-
- try {
- // Raises an exception that gets picked up by KJS_CHECKEXCEPTIONREFERENCE
- document.documentElement.appendChild('').innerHTML = '';
- expectedException();
- } catch (e) {
- writeException(e);
- }
-
- try {
- // Raises an exception that gets picked up by KJS_CHECKEXCEPTIONLIST
- document.getElementById(1());
- expectedException();
- } catch (e) {
- writeException(e);
- }
-
- try {
- // Raises an exception inside a function to check that its line number
- // isn't overwritten in the assignment node.
- var a = exceptionInFunction();
- expectedException();
- } catch (e) {
- writeException(e);
- }
- }
- </script>
- </head>
- <body onload="test()">
- <p>This test exercises the source URL and line number that is embedded in JavaScript exceptions, which is displayed in places like the JavaScript console.</p>
- <p>If the test passes, you should see five exceptions caught below, with the appropriate line number for each (increasing except for the last one).</p>
- <hr>
- <p><ol id=console></ol></p>
- </body>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/exception-linenums.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
</html>
-This tests that JavaScriptCore ForInNodes are converted correctly to text. If this test is successful, part of the text below should say "for (j in index)".
-function test()
-{
- for (j in index)
- {
- testProperty(index[j]);
- }
-}
+This tests that JavaScriptCore ForInNodes are converted correctly to text.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS test.toString().match('for *[(]j *in *index[)]') != null is true
+PASS successfullyParsed is true
+
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
- <script>
- function debug(s) {
- document.getElementById('console').innerHTML += s + '<br>';
- }
-
- function test() {
- for (j in index) {
- testProperty(index[j]);
- }
- }
- function runTests() {
- if (window.layoutTestController)
- layoutTestController.dumpAsText()
- debug(test)
- }
- </script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-<body onLoad="runTests()">
-This tests that JavaScriptCore ForInNodes are converted correctly to text. If this test is successful, part of the text below should say "for (j in index)".
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/for-in-to-text.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
-<pre id="console">
-</pre>
</html>
This test verifies the behaviour of Object.prototype.hasOwnProperty, as documented in ECMA-262 rev3 section 15.2.4.5.
-If the test passes, you should see two 'true' outputs followed by three 'false' outputs.
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-anObject has own property 'foo': true
-aString has own property 'length': true
-anObject has own property 'bar': false
-anObject has own property 'toString': false
-aString has own property 'toString': false
+
+PASS typeof {foo : 'yum'}.hasOwnProperty is "function"
+PASS ({foo : 'yum'}).hasOwnProperty('foo') is true
+PASS ''.hasOwnProperty('length') is true
+PASS ({foo : 'yum'}).hasOwnProperty('bar') is false
+PASS ({foo : 'yum'}).hasOwnProperty('toString') is false
+PASS ''.hasOwnProperty('toString') is false
+PASS successfullyParsed is true
+
+TEST COMPLETE
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <head>
- <title>Test of hasOwnProperty</title>
- <script type="text/javascript">
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
-
- function print(message)
- {
- var paragraph = document.createElement("li");
- paragraph.appendChild(document.createTextNode(message));
- document.getElementById("console").appendChild(paragraph);
- }
-
- function test()
- {
-
- var anObject = {foo : 'yum'};
- var aString = '';
-
- if (anObject.hasOwnProperty)
- {
- print("anObject has own property 'foo': " + anObject.hasOwnProperty('foo'));
- print("aString has own property 'length': " + ''.hasOwnProperty('length'));
- print("anObject has own property 'bar': " + anObject.hasOwnProperty('bar'));
- print("anObject has own property 'toString': " + anObject.hasOwnProperty('toString'));
- print("aString has own property 'toString': " + ''.hasOwnProperty('toString'));
- }
- else
- {
- print("ERROR: ECMAScript hasOwnProperty() method missing!");
- }
- }
- </script>
- </head>
- <body onload="test()">
- <p>This test verifies the behaviour of Object.prototype.hasOwnProperty, as documented in ECMA-262 rev3 section 15.2.4.5.</p>
- <p>If the test passes, you should see two 'true' outputs followed by three 'false' outputs.</p>
- <hr>
- <p><ol id=console></ol></p>
- </body>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/has-own-property.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
</html>
This test verifies that the bit twiddling done in JavaScriptCore's integer machinery works correctly on the current platform.
-Below, you will see a listing of the extremes related to representing integers using a certain number of bits. If the test succeeds, you should see:
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-0, -0, and -1
-max: 2 ^ ([number of bits] - 1) - 1
-min: -(max + 1)
-a corresponding max + 1 and min - 1
--1: -1
-0: 0
-
--0: 0
-
------
+PASS (-1).toString() is "-1"
+PASS (0).toString() is "0"
+PASS (-0).toString() is "0"
bits used to store value: 8
-
-min: -128
-
-min - 1: -129
-
-max: 127
-
-max + 1: 128
-
------
-
+PASS min.toString() is "-128"
+PASS (min - 1).toString() is "-129"
+PASS max.toString() is "127"
+PASS (max + 1).toString() is "128"
bits used to store value: 9
-
-min: -256
-
-min - 1: -257
-
-max: 255
-
-max + 1: 256
-
------
-
+PASS min.toString() is "-256"
+PASS (min - 1).toString() is "-257"
+PASS max.toString() is "255"
+PASS (max + 1).toString() is "256"
bits used to store value: 10
-
-min: -512
-
-min - 1: -513
-
-max: 511
-
-max + 1: 512
-
------
-
+PASS min.toString() is "-512"
+PASS (min - 1).toString() is "-513"
+PASS max.toString() is "511"
+PASS (max + 1).toString() is "512"
bits used to store value: 11
-
-min: -1024
-
-min - 1: -1025
-
-max: 1023
-
-max + 1: 1024
-
------
-
+PASS min.toString() is "-1024"
+PASS (min - 1).toString() is "-1025"
+PASS max.toString() is "1023"
+PASS (max + 1).toString() is "1024"
bits used to store value: 12
-
-min: -2048
-
-min - 1: -2049
-
-max: 2047
-
-max + 1: 2048
-
------
-
+PASS min.toString() is "-2048"
+PASS (min - 1).toString() is "-2049"
+PASS max.toString() is "2047"
+PASS (max + 1).toString() is "2048"
bits used to store value: 13
-
-min: -4096
-
-min - 1: -4097
-
-max: 4095
-
-max + 1: 4096
-
------
-
+PASS min.toString() is "-4096"
+PASS (min - 1).toString() is "-4097"
+PASS max.toString() is "4095"
+PASS (max + 1).toString() is "4096"
bits used to store value: 14
-
-min: -8192
-
-min - 1: -8193
-
-max: 8191
-
-max + 1: 8192
-
------
-
+PASS min.toString() is "-8192"
+PASS (min - 1).toString() is "-8193"
+PASS max.toString() is "8191"
+PASS (max + 1).toString() is "8192"
bits used to store value: 15
-
-min: -16384
-
-min - 1: -16385
-
-max: 16383
-
-max + 1: 16384
-
------
-
+PASS min.toString() is "-16384"
+PASS (min - 1).toString() is "-16385"
+PASS max.toString() is "16383"
+PASS (max + 1).toString() is "16384"
bits used to store value: 16
-
-min: -32768
-
-min - 1: -32769
-
-max: 32767
-
-max + 1: 32768
-
------
-
+PASS min.toString() is "-32768"
+PASS (min - 1).toString() is "-32769"
+PASS max.toString() is "32767"
+PASS (max + 1).toString() is "32768"
bits used to store value: 17
-
-min: -65536
-
-min - 1: -65537
-
-max: 65535
-
-max + 1: 65536
-
------
-
+PASS min.toString() is "-65536"
+PASS (min - 1).toString() is "-65537"
+PASS max.toString() is "65535"
+PASS (max + 1).toString() is "65536"
bits used to store value: 18
-
-min: -131072
-
-min - 1: -131073
-
-max: 131071
-
-max + 1: 131072
-
------
-
+PASS min.toString() is "-131072"
+PASS (min - 1).toString() is "-131073"
+PASS max.toString() is "131071"
+PASS (max + 1).toString() is "131072"
bits used to store value: 19
-
-min: -262144
-
-min - 1: -262145
-
-max: 262143
-
-max + 1: 262144
-
------
-
+PASS min.toString() is "-262144"
+PASS (min - 1).toString() is "-262145"
+PASS max.toString() is "262143"
+PASS (max + 1).toString() is "262144"
bits used to store value: 20
-
-min: -524288
-
-min - 1: -524289
-
-max: 524287
-
-max + 1: 524288
-
------
-
+PASS min.toString() is "-524288"
+PASS (min - 1).toString() is "-524289"
+PASS max.toString() is "524287"
+PASS (max + 1).toString() is "524288"
bits used to store value: 21
-
-min: -1048576
-
-min - 1: -1048577
-
-max: 1048575
-
-max + 1: 1048576
-
------
-
+PASS min.toString() is "-1048576"
+PASS (min - 1).toString() is "-1048577"
+PASS max.toString() is "1048575"
+PASS (max + 1).toString() is "1048576"
bits used to store value: 22
-
-min: -2097152
-
-min - 1: -2097153
-
-max: 2097151
-
-max + 1: 2097152
-
------
-
+PASS min.toString() is "-2097152"
+PASS (min - 1).toString() is "-2097153"
+PASS max.toString() is "2097151"
+PASS (max + 1).toString() is "2097152"
bits used to store value: 23
-
-min: -4194304
-
-min - 1: -4194305
-
-max: 4194303
-
-max + 1: 4194304
-
------
-
+PASS min.toString() is "-4194304"
+PASS (min - 1).toString() is "-4194305"
+PASS max.toString() is "4194303"
+PASS (max + 1).toString() is "4194304"
bits used to store value: 24
-
-min: -8388608
-
-min - 1: -8388609
-
-max: 8388607
-
-max + 1: 8388608
-
------
-
+PASS min.toString() is "-8388608"
+PASS (min - 1).toString() is "-8388609"
+PASS max.toString() is "8388607"
+PASS (max + 1).toString() is "8388608"
bits used to store value: 25
-
-min: -16777216
-
-min - 1: -16777217
-
-max: 16777215
-
-max + 1: 16777216
-
------
-
+PASS min.toString() is "-16777216"
+PASS (min - 1).toString() is "-16777217"
+PASS max.toString() is "16777215"
+PASS (max + 1).toString() is "16777216"
bits used to store value: 26
-
-min: -33554432
-
-min - 1: -33554433
-
-max: 33554431
-
-max + 1: 33554432
-
------
-
+PASS min.toString() is "-33554432"
+PASS (min - 1).toString() is "-33554433"
+PASS max.toString() is "33554431"
+PASS (max + 1).toString() is "33554432"
bits used to store value: 27
-
-min: -67108864
-
-min - 1: -67108865
-
-max: 67108863
-
-max + 1: 67108864
-
------
-
+PASS min.toString() is "-67108864"
+PASS (min - 1).toString() is "-67108865"
+PASS max.toString() is "67108863"
+PASS (max + 1).toString() is "67108864"
bits used to store value: 28
-
-min: -134217728
-
-min - 1: -134217729
-
-max: 134217727
-
-max + 1: 134217728
-
------
-
+PASS min.toString() is "-134217728"
+PASS (min - 1).toString() is "-134217729"
+PASS max.toString() is "134217727"
+PASS (max + 1).toString() is "134217728"
bits used to store value: 29
-
-min: -268435456
-
-min - 1: -268435457
-
-max: 268435455
-
-max + 1: 268435456
-
------
-
+PASS min.toString() is "-268435456"
+PASS (min - 1).toString() is "-268435457"
+PASS max.toString() is "268435455"
+PASS (max + 1).toString() is "268435456"
bits used to store value: 30
-
-min: -536870912
-
-min - 1: -536870913
-
-max: 536870911
-
-max + 1: 536870912
-
------
-
+PASS min.toString() is "-536870912"
+PASS (min - 1).toString() is "-536870913"
+PASS max.toString() is "536870911"
+PASS (max + 1).toString() is "536870912"
bits used to store value: 31
-
-min: -1073741824
-
-min - 1: -1073741825
-
-max: 1073741823
-
-max + 1: 1073741824
-
------
-
+PASS min.toString() is "-1073741824"
+PASS (min - 1).toString() is "-1073741825"
+PASS max.toString() is "1073741823"
+PASS (max + 1).toString() is "1073741824"
bits used to store value: 32
-
-min: -2147483648
-
-min - 1: -2147483649
-
-max: 2147483647
-
-max + 1: 2147483648
-
------
-
+PASS min.toString() is "-2147483648"
+PASS (min - 1).toString() is "-2147483649"
+PASS max.toString() is "2147483647"
+PASS (max + 1).toString() is "2147483648"
bits used to store value: 33
-
-min: -4294967296
-
-min - 1: -4294967297
-
-max: 4294967295
-
-max + 1: 4294967296
-
------
-
+PASS min.toString() is "-4294967296"
+PASS (min - 1).toString() is "-4294967297"
+PASS max.toString() is "4294967295"
+PASS (max + 1).toString() is "4294967296"
bits used to store value: 34
-
-min: -8589934592
-
-min - 1: -8589934593
-
-max: 8589934591
-
-max + 1: 8589934592
-
------
-
+PASS min.toString() is "-8589934592"
+PASS (min - 1).toString() is "-8589934593"
+PASS max.toString() is "8589934591"
+PASS (max + 1).toString() is "8589934592"
bits used to store value: 35
-
-min: -17179869184
-
-min - 1: -17179869185
-
-max: 17179869183
-
-max + 1: 17179869184
-
------
-
+PASS min.toString() is "-17179869184"
+PASS (min - 1).toString() is "-17179869185"
+PASS max.toString() is "17179869183"
+PASS (max + 1).toString() is "17179869184"
bits used to store value: 36
-
-min: -34359738368
-
-min - 1: -34359738369
-
-max: 34359738367
-
-max + 1: 34359738368
-
------
-
+PASS min.toString() is "-34359738368"
+PASS (min - 1).toString() is "-34359738369"
+PASS max.toString() is "34359738367"
+PASS (max + 1).toString() is "34359738368"
bits used to store value: 37
-
-min: -68719476736
-
-min - 1: -68719476737
-
-max: 68719476735
-
-max + 1: 68719476736
-
------
-
+PASS min.toString() is "-68719476736"
+PASS (min - 1).toString() is "-68719476737"
+PASS max.toString() is "68719476735"
+PASS (max + 1).toString() is "68719476736"
bits used to store value: 38
-
-min: -137438953472
-
-min - 1: -137438953473
-
-max: 137438953471
-
-max + 1: 137438953472
-
------
-
+PASS min.toString() is "-137438953472"
+PASS (min - 1).toString() is "-137438953473"
+PASS max.toString() is "137438953471"
+PASS (max + 1).toString() is "137438953472"
bits used to store value: 39
-
-min: -274877906944
-
-min - 1: -274877906945
-
-max: 274877906943
-
-max + 1: 274877906944
-
------
-
+PASS min.toString() is "-274877906944"
+PASS (min - 1).toString() is "-274877906945"
+PASS max.toString() is "274877906943"
+PASS (max + 1).toString() is "274877906944"
bits used to store value: 40
-
-min: -549755813888
-
-min - 1: -549755813889
-
-max: 549755813887
-
-max + 1: 549755813888
-
------
-
+PASS min.toString() is "-549755813888"
+PASS (min - 1).toString() is "-549755813889"
+PASS max.toString() is "549755813887"
+PASS (max + 1).toString() is "549755813888"
bits used to store value: 41
-
-min: -1099511627776
-
-min - 1: -1099511627777
-
-max: 1099511627775
-
-max + 1: 1099511627776
-
------
-
+PASS min.toString() is "-1099511627776"
+PASS (min - 1).toString() is "-1099511627777"
+PASS max.toString() is "1099511627775"
+PASS (max + 1).toString() is "1099511627776"
bits used to store value: 42
-
-min: -2199023255552
-
-min - 1: -2199023255553
-
-max: 2199023255551
-
-max + 1: 2199023255552
-
------
-
+PASS min.toString() is "-2199023255552"
+PASS (min - 1).toString() is "-2199023255553"
+PASS max.toString() is "2199023255551"
+PASS (max + 1).toString() is "2199023255552"
bits used to store value: 43
-
-min: -4398046511104
-
-min - 1: -4398046511105
-
-max: 4398046511103
-
-max + 1: 4398046511104
-
------
-
+PASS min.toString() is "-4398046511104"
+PASS (min - 1).toString() is "-4398046511105"
+PASS max.toString() is "4398046511103"
+PASS (max + 1).toString() is "4398046511104"
bits used to store value: 44
-
-min: -8796093022208
-
-min - 1: -8796093022209
-
-max: 8796093022207
-
-max + 1: 8796093022208
-
------
-
+PASS min.toString() is "-8796093022208"
+PASS (min - 1).toString() is "-8796093022209"
+PASS max.toString() is "8796093022207"
+PASS (max + 1).toString() is "8796093022208"
bits used to store value: 45
-
-min: -17592186044416
-
-min - 1: -17592186044417
-
-max: 17592186044415
-
-max + 1: 17592186044416
-
------
-
+PASS min.toString() is "-17592186044416"
+PASS (min - 1).toString() is "-17592186044417"
+PASS max.toString() is "17592186044415"
+PASS (max + 1).toString() is "17592186044416"
bits used to store value: 46
-
-min: -35184372088832
-
-min - 1: -35184372088833
-
-max: 35184372088831
-
-max + 1: 35184372088832
-
------
-
+PASS min.toString() is "-35184372088832"
+PASS (min - 1).toString() is "-35184372088833"
+PASS max.toString() is "35184372088831"
+PASS (max + 1).toString() is "35184372088832"
bits used to store value: 47
-
-min: -70368744177664
-
-min - 1: -70368744177665
-
-max: 70368744177663
-
-max + 1: 70368744177664
-
------
-
+PASS min.toString() is "-70368744177664"
+PASS (min - 1).toString() is "-70368744177665"
+PASS max.toString() is "70368744177663"
+PASS (max + 1).toString() is "70368744177664"
bits used to store value: 48
-
-min: -140737488355328
-
-min - 1: -140737488355329
-
-max: 140737488355327
-
-max + 1: 140737488355328
-
------
-
+PASS min.toString() is "-140737488355328"
+PASS (min - 1).toString() is "-140737488355329"
+PASS max.toString() is "140737488355327"
+PASS (max + 1).toString() is "140737488355328"
bits used to store value: 49
-
-min: -281474976710656
-
-min - 1: -281474976710657
-
-max: 281474976710655
-
-max + 1: 281474976710656
-
------
-
+PASS min.toString() is "-281474976710656"
+PASS (min - 1).toString() is "-281474976710657"
+PASS max.toString() is "281474976710655"
+PASS (max + 1).toString() is "281474976710656"
bits used to store value: 50
-
-min: -562949953421312
-
-min - 1: -562949953421313
-
-max: 562949953421311
-
-max + 1: 562949953421312
-
------
-
+PASS min.toString() is "-562949953421312"
+PASS (min - 1).toString() is "-562949953421313"
+PASS max.toString() is "562949953421311"
+PASS (max + 1).toString() is "562949953421312"
bits used to store value: 51
-
-min: -1125899906842624
-
-min - 1: -1125899906842625
-
-max: 1125899906842623
-
-max + 1: 1125899906842624
-
------
-
+PASS min.toString() is "-1125899906842624"
+PASS (min - 1).toString() is "-1125899906842625"
+PASS max.toString() is "1125899906842623"
+PASS (max + 1).toString() is "1125899906842624"
bits used to store value: 52
-
-min: -2251799813685248
-
-min - 1: -2251799813685249
-
-max: 2251799813685247
-
-max + 1: 2251799813685248
-
------
-
+PASS min.toString() is "-2251799813685248"
+PASS (min - 1).toString() is "-2251799813685249"
+PASS max.toString() is "2251799813685247"
+PASS (max + 1).toString() is "2251799813685248"
bits used to store value: 53
-
-min: -4503599627370496
-
-min - 1: -4503599627370497
-
-max: 4503599627370495
-
-max + 1: 4503599627370496
-
------
-
+PASS min.toString() is "-4503599627370496"
+PASS (min - 1).toString() is "-4503599627370497"
+PASS max.toString() is "4503599627370495"
+PASS (max + 1).toString() is "4503599627370496"
bits used to store value: 54
-
-min: -9007199254740992
-
-min - 1: -9007199254740992
-
-max: 9007199254740991
-
-max + 1: 9007199254740992
-
------
-
+PASS min.toString() is "-9007199254740992"
+PASS (min - 1).toString() is "-9007199254740992"
+PASS max.toString() is "9007199254740991"
+PASS (max + 1).toString() is "9007199254740992"
bits used to store value: 55
-
-min: -18014398509481984
-
-min - 1: -18014398509481984
-
-max: 18014398509481984
-
-max + 1: 18014398509481984
-
------
-
+PASS min.toString() is "-18014398509481984"
+PASS (min - 1).toString() is "-18014398509481984"
+PASS max.toString() is "18014398509481984"
+PASS (max + 1).toString() is "18014398509481984"
bits used to store value: 56
-
-min: -36028797018963970
-
-min - 1: -36028797018963970
-
-max: 36028797018963970
-
-max + 1: 36028797018963970
-
------
-
+PASS min.toString() is "-36028797018963970"
+PASS (min - 1).toString() is "-36028797018963970"
+PASS max.toString() is "36028797018963970"
+PASS (max + 1).toString() is "36028797018963970"
bits used to store value: 57
-
-min: -72057594037927940
-
-min - 1: -72057594037927940
-
-max: 72057594037927940
-
-max + 1: 72057594037927940
-
------
-
+PASS min.toString() is "-72057594037927940"
+PASS (min - 1).toString() is "-72057594037927940"
+PASS max.toString() is "72057594037927940"
+PASS (max + 1).toString() is "72057594037927940"
bits used to store value: 58
-
-min: -144115188075855870
-
-min - 1: -144115188075855870
-
-max: 144115188075855870
-
-max + 1: 144115188075855870
-
------
-
+PASS min.toString() is "-144115188075855870"
+PASS (min - 1).toString() is "-144115188075855870"
+PASS max.toString() is "144115188075855870"
+PASS (max + 1).toString() is "144115188075855870"
bits used to store value: 59
-
-min: -288230376151711740
-
-min - 1: -288230376151711740
-
-max: 288230376151711740
-
-max + 1: 288230376151711740
-
------
-
+PASS min.toString() is "-288230376151711740"
+PASS (min - 1).toString() is "-288230376151711740"
+PASS max.toString() is "288230376151711740"
+PASS (max + 1).toString() is "288230376151711740"
bits used to store value: 60
-
-min: -576460752303423500
-
-min - 1: -576460752303423500
-
-max: 576460752303423500
-
-max + 1: 576460752303423500
-
------
-
+PASS min.toString() is "-576460752303423500"
+PASS (min - 1).toString() is "-576460752303423500"
+PASS max.toString() is "576460752303423500"
+PASS (max + 1).toString() is "576460752303423500"
bits used to store value: 61
-
-min: -1152921504606847000
-
-min - 1: -1152921504606847000
-
-max: 1152921504606847000
-
-max + 1: 1152921504606847000
-
------
-
+PASS min.toString() is "-1152921504606847000"
+PASS (min - 1).toString() is "-1152921504606847000"
+PASS max.toString() is "1152921504606847000"
+PASS (max + 1).toString() is "1152921504606847000"
bits used to store value: 62
-
-min: -2305843009213694000
-
-min - 1: -2305843009213694000
-
-max: 2305843009213694000
-
-max + 1: 2305843009213694000
-
------
-
+PASS min.toString() is "-2305843009213694000"
+PASS (min - 1).toString() is "-2305843009213694000"
+PASS max.toString() is "2305843009213694000"
+PASS (max + 1).toString() is "2305843009213694000"
bits used to store value: 63
-
-min: -4611686018427388000
-
-min - 1: -4611686018427388000
-
-max: 4611686018427388000
-
-max + 1: 4611686018427388000
-
------
-
+PASS min.toString() is "-4611686018427388000"
+PASS (min - 1).toString() is "-4611686018427388000"
+PASS max.toString() is "4611686018427388000"
+PASS (max + 1).toString() is "4611686018427388000"
bits used to store value: 64
-
-min: -9223372036854776000
-
-min - 1: -9223372036854776000
-
-max: 9223372036854776000
-
-max + 1: 9223372036854776000
-
------
-
+PASS min.toString() is "-9223372036854776000"
+PASS (min - 1).toString() is "-9223372036854776000"
+PASS max.toString() is "9223372036854776000"
+PASS (max + 1).toString() is "9223372036854776000"
bits used to store value: 65
-
-min: -18446744073709552000
-
-min - 1: -18446744073709552000
-
-max: 18446744073709552000
-
-max + 1: 18446744073709552000
-
------
-
+PASS min.toString() is "-18446744073709552000"
+PASS (min - 1).toString() is "-18446744073709552000"
+PASS max.toString() is "18446744073709552000"
+PASS (max + 1).toString() is "18446744073709552000"
bits used to store value: 66
-
-min: -36893488147419103000
-
-min - 1: -36893488147419103000
-
-max: 36893488147419103000
-
-max + 1: 36893488147419103000
-
------
-
+PASS min.toString() is "-36893488147419103000"
+PASS (min - 1).toString() is "-36893488147419103000"
+PASS max.toString() is "36893488147419103000"
+PASS (max + 1).toString() is "36893488147419103000"
bits used to store value: 67
-
-min: -73786976294838210000
-
-min - 1: -73786976294838210000
-
-max: 73786976294838210000
-
-max + 1: 73786976294838210000
-
------
-
+PASS min.toString() is "-73786976294838210000"
+PASS (min - 1).toString() is "-73786976294838210000"
+PASS max.toString() is "73786976294838210000"
+PASS (max + 1).toString() is "73786976294838210000"
bits used to store value: 68
-
-min: -147573952589676410000
-
-min - 1: -147573952589676410000
-
-max: 147573952589676410000
-
-max + 1: 147573952589676410000
-
------
-
+PASS min.toString() is "-147573952589676410000"
+PASS (min - 1).toString() is "-147573952589676410000"
+PASS max.toString() is "147573952589676410000"
+PASS (max + 1).toString() is "147573952589676410000"
bits used to store value: 69
-
-min: -295147905179352830000
-
-min - 1: -295147905179352830000
-
-max: 295147905179352830000
-
-max + 1: 295147905179352830000
-
------
-
+PASS min.toString() is "-295147905179352830000"
+PASS (min - 1).toString() is "-295147905179352830000"
+PASS max.toString() is "295147905179352830000"
+PASS (max + 1).toString() is "295147905179352830000"
bits used to store value: 70
-
-min: -590295810358705700000
-
-min - 1: -590295810358705700000
-
-max: 590295810358705700000
-
-max + 1: 590295810358705700000
-
------
-
+PASS min.toString() is "-590295810358705700000"
+PASS (min - 1).toString() is "-590295810358705700000"
+PASS max.toString() is "590295810358705700000"
+PASS (max + 1).toString() is "590295810358705700000"
bits used to store value: 71
-
-min: -1.1805916207174113e+21
-
-min - 1: -1.1805916207174113e+21
-
-max: 1.1805916207174113e+21
-
-max + 1: 1.1805916207174113e+21
-
------
-
+PASS min.toString() is "-1.1805916207174113e+21"
+PASS (min - 1).toString() is "-1.1805916207174113e+21"
+PASS max.toString() is "1.1805916207174113e+21"
+PASS (max + 1).toString() is "1.1805916207174113e+21"
bits used to store value: 72
-
-min: -2.3611832414348226e+21
-
-min - 1: -2.3611832414348226e+21
-
-max: 2.3611832414348226e+21
-
-max + 1: 2.3611832414348226e+21
-
------
-
+PASS min.toString() is "-2.3611832414348226e+21"
+PASS (min - 1).toString() is "-2.3611832414348226e+21"
+PASS max.toString() is "2.3611832414348226e+21"
+PASS (max + 1).toString() is "2.3611832414348226e+21"
bits used to store value: 73
-
-min: -4.722366482869645e+21
-
-min - 1: -4.722366482869645e+21
-
-max: 4.722366482869645e+21
-
-max + 1: 4.722366482869645e+21
-
------
-
+PASS min.toString() is "-4.722366482869645e+21"
+PASS (min - 1).toString() is "-4.722366482869645e+21"
+PASS max.toString() is "4.722366482869645e+21"
+PASS (max + 1).toString() is "4.722366482869645e+21"
bits used to store value: 74
-
-min: -9.44473296573929e+21
-
-min - 1: -9.44473296573929e+21
-
-max: 9.44473296573929e+21
-
-max + 1: 9.44473296573929e+21
-
------
-
+PASS min.toString() is "-9.44473296573929e+21"
+PASS (min - 1).toString() is "-9.44473296573929e+21"
+PASS max.toString() is "9.44473296573929e+21"
+PASS (max + 1).toString() is "9.44473296573929e+21"
bits used to store value: 75
-
-min: -1.888946593147858e+22
-
-min - 1: -1.888946593147858e+22
-
-max: 1.888946593147858e+22
-
-max + 1: 1.888946593147858e+22
-
------
-
+PASS min.toString() is "-1.888946593147858e+22"
+PASS (min - 1).toString() is "-1.888946593147858e+22"
+PASS max.toString() is "1.888946593147858e+22"
+PASS (max + 1).toString() is "1.888946593147858e+22"
bits used to store value: 76
-
-min: -3.777893186295716e+22
-
-min - 1: -3.777893186295716e+22
-
-max: 3.777893186295716e+22
-
-max + 1: 3.777893186295716e+22
-
------
-
+PASS min.toString() is "-3.777893186295716e+22"
+PASS (min - 1).toString() is "-3.777893186295716e+22"
+PASS max.toString() is "3.777893186295716e+22"
+PASS (max + 1).toString() is "3.777893186295716e+22"
bits used to store value: 77
-
-min: -7.555786372591432e+22
-
-min - 1: -7.555786372591432e+22
-
-max: 7.555786372591432e+22
-
-max + 1: 7.555786372591432e+22
-
------
-
+PASS min.toString() is "-7.555786372591432e+22"
+PASS (min - 1).toString() is "-7.555786372591432e+22"
+PASS max.toString() is "7.555786372591432e+22"
+PASS (max + 1).toString() is "7.555786372591432e+22"
bits used to store value: 78
-
-min: -1.5111572745182865e+23
-
-min - 1: -1.5111572745182865e+23
-
-max: 1.5111572745182865e+23
-
-max + 1: 1.5111572745182865e+23
-
------
-
+PASS min.toString() is "-1.5111572745182865e+23"
+PASS (min - 1).toString() is "-1.5111572745182865e+23"
+PASS max.toString() is "1.5111572745182865e+23"
+PASS (max + 1).toString() is "1.5111572745182865e+23"
bits used to store value: 79
-
-min: -3.022314549036573e+23
-
-min - 1: -3.022314549036573e+23
-
-max: 3.022314549036573e+23
-
-max + 1: 3.022314549036573e+23
-
------
-
+PASS min.toString() is "-3.022314549036573e+23"
+PASS (min - 1).toString() is "-3.022314549036573e+23"
+PASS max.toString() is "3.022314549036573e+23"
+PASS (max + 1).toString() is "3.022314549036573e+23"
bits used to store value: 80
-
-min: -6.044629098073146e+23
-
-min - 1: -6.044629098073146e+23
-
-max: 6.044629098073146e+23
-
-max + 1: 6.044629098073146e+23
-
------
-
+PASS min.toString() is "-6.044629098073146e+23"
+PASS (min - 1).toString() is "-6.044629098073146e+23"
+PASS max.toString() is "6.044629098073146e+23"
+PASS (max + 1).toString() is "6.044629098073146e+23"
bits used to store value: 81
-
-min: -1.2089258196146292e+24
-
-min - 1: -1.2089258196146292e+24
-
-max: 1.2089258196146292e+24
-
-max + 1: 1.2089258196146292e+24
-
------
-
+PASS min.toString() is "-1.2089258196146292e+24"
+PASS (min - 1).toString() is "-1.2089258196146292e+24"
+PASS max.toString() is "1.2089258196146292e+24"
+PASS (max + 1).toString() is "1.2089258196146292e+24"
bits used to store value: 82
-
-min: -2.4178516392292583e+24
-
-min - 1: -2.4178516392292583e+24
-
-max: 2.4178516392292583e+24
-
-max + 1: 2.4178516392292583e+24
-
------
-
+PASS min.toString() is "-2.4178516392292583e+24"
+PASS (min - 1).toString() is "-2.4178516392292583e+24"
+PASS max.toString() is "2.4178516392292583e+24"
+PASS (max + 1).toString() is "2.4178516392292583e+24"
bits used to store value: 83
-
-min: -4.835703278458517e+24
-
-min - 1: -4.835703278458517e+24
-
-max: 4.835703278458517e+24
-
-max + 1: 4.835703278458517e+24
-
------
-
-bits used to store value: 84
-
-min: -9.671406556917033e+24
-
-min - 1: -9.671406556917033e+24
-
-max: 9.671406556917033e+24
-
-max + 1: 9.671406556917033e+24
-
------
-
-bits used to store value: 85
-
-min: -1.9342813113834067e+25
-
-min - 1: -1.9342813113834067e+25
-
-max: 1.9342813113834067e+25
-
-max + 1: 1.9342813113834067e+25
-
------
-
+PASS min.toString() is "-4.835703278458517e+24"
+PASS (min - 1).toString() is "-4.835703278458517e+24"
+PASS max.toString() is "4.835703278458517e+24"
+PASS (max + 1).toString() is "4.835703278458517e+24"
+bits used to store value: 84
+PASS min.toString() is "-9.671406556917033e+24"
+PASS (min - 1).toString() is "-9.671406556917033e+24"
+PASS max.toString() is "9.671406556917033e+24"
+PASS (max + 1).toString() is "9.671406556917033e+24"
+bits used to store value: 85
+PASS min.toString() is "-1.9342813113834067e+25"
+PASS (min - 1).toString() is "-1.9342813113834067e+25"
+PASS max.toString() is "1.9342813113834067e+25"
+PASS (max + 1).toString() is "1.9342813113834067e+25"
bits used to store value: 86
-
-min: -3.8685626227668134e+25
-
-min - 1: -3.8685626227668134e+25
-
-max: 3.8685626227668134e+25
-
-max + 1: 3.8685626227668134e+25
-
------
-
+PASS min.toString() is "-3.8685626227668134e+25"
+PASS (min - 1).toString() is "-3.8685626227668134e+25"
+PASS max.toString() is "3.8685626227668134e+25"
+PASS (max + 1).toString() is "3.8685626227668134e+25"
bits used to store value: 87
-
-min: -7.737125245533627e+25
-
-min - 1: -7.737125245533627e+25
-
-max: 7.737125245533627e+25
-
-max + 1: 7.737125245533627e+25
-
------
-
+PASS min.toString() is "-7.737125245533627e+25"
+PASS (min - 1).toString() is "-7.737125245533627e+25"
+PASS max.toString() is "7.737125245533627e+25"
+PASS (max + 1).toString() is "7.737125245533627e+25"
bits used to store value: 88
-
-min: -1.5474250491067253e+26
-
-min - 1: -1.5474250491067253e+26
-
-max: 1.5474250491067253e+26
-
-max + 1: 1.5474250491067253e+26
-
------
-
+PASS min.toString() is "-1.5474250491067253e+26"
+PASS (min - 1).toString() is "-1.5474250491067253e+26"
+PASS max.toString() is "1.5474250491067253e+26"
+PASS (max + 1).toString() is "1.5474250491067253e+26"
bits used to store value: 89
-
-min: -3.094850098213451e+26
-
-min - 1: -3.094850098213451e+26
-
-max: 3.094850098213451e+26
-
-max + 1: 3.094850098213451e+26
-
------
-
+PASS min.toString() is "-3.094850098213451e+26"
+PASS (min - 1).toString() is "-3.094850098213451e+26"
+PASS max.toString() is "3.094850098213451e+26"
+PASS (max + 1).toString() is "3.094850098213451e+26"
bits used to store value: 90
-
-min: -6.189700196426902e+26
-
-min - 1: -6.189700196426902e+26
-
-max: 6.189700196426902e+26
-
-max + 1: 6.189700196426902e+26
-
------
-
+PASS min.toString() is "-6.189700196426902e+26"
+PASS (min - 1).toString() is "-6.189700196426902e+26"
+PASS max.toString() is "6.189700196426902e+26"
+PASS (max + 1).toString() is "6.189700196426902e+26"
bits used to store value: 91
-
-min: -1.2379400392853803e+27
-
-min - 1: -1.2379400392853803e+27
-
-max: 1.2379400392853803e+27
-
-max + 1: 1.2379400392853803e+27
-
------
-
+PASS min.toString() is "-1.2379400392853803e+27"
+PASS (min - 1).toString() is "-1.2379400392853803e+27"
+PASS max.toString() is "1.2379400392853803e+27"
+PASS (max + 1).toString() is "1.2379400392853803e+27"
bits used to store value: 92
-
-min: -2.4758800785707605e+27
-
-min - 1: -2.4758800785707605e+27
-
-max: 2.4758800785707605e+27
-
-max + 1: 2.4758800785707605e+27
-
------
-
+PASS min.toString() is "-2.4758800785707605e+27"
+PASS (min - 1).toString() is "-2.4758800785707605e+27"
+PASS max.toString() is "2.4758800785707605e+27"
+PASS (max + 1).toString() is "2.4758800785707605e+27"
bits used to store value: 93
-
-min: -4.951760157141521e+27
-
-min - 1: -4.951760157141521e+27
-
-max: 4.951760157141521e+27
-
-max + 1: 4.951760157141521e+27
-
------
-
+PASS min.toString() is "-4.951760157141521e+27"
+PASS (min - 1).toString() is "-4.951760157141521e+27"
+PASS max.toString() is "4.951760157141521e+27"
+PASS (max + 1).toString() is "4.951760157141521e+27"
bits used to store value: 94
-
-min: -9.903520314283042e+27
-
-min - 1: -9.903520314283042e+27
-
-max: 9.903520314283042e+27
-
-max + 1: 9.903520314283042e+27
-
------
-
+PASS min.toString() is "-9.903520314283042e+27"
+PASS (min - 1).toString() is "-9.903520314283042e+27"
+PASS max.toString() is "9.903520314283042e+27"
+PASS (max + 1).toString() is "9.903520314283042e+27"
bits used to store value: 95
-
-min: -1.9807040628566084e+28
-
-min - 1: -1.9807040628566084e+28
-
-max: 1.9807040628566084e+28
-
-max + 1: 1.9807040628566084e+28
-
------
-
+PASS min.toString() is "-1.9807040628566084e+28"
+PASS (min - 1).toString() is "-1.9807040628566084e+28"
+PASS max.toString() is "1.9807040628566084e+28"
+PASS (max + 1).toString() is "1.9807040628566084e+28"
bits used to store value: 96
-
-min: -3.961408125713217e+28
-
-min - 1: -3.961408125713217e+28
-
-max: 3.961408125713217e+28
-
-max + 1: 3.961408125713217e+28
-
------
-
+PASS min.toString() is "-3.961408125713217e+28"
+PASS (min - 1).toString() is "-3.961408125713217e+28"
+PASS max.toString() is "3.961408125713217e+28"
+PASS (max + 1).toString() is "3.961408125713217e+28"
bits used to store value: 97
-
-min: -7.922816251426434e+28
-
-min - 1: -7.922816251426434e+28
-
-max: 7.922816251426434e+28
-
-max + 1: 7.922816251426434e+28
-
------
-
+PASS min.toString() is "-7.922816251426434e+28"
+PASS (min - 1).toString() is "-7.922816251426434e+28"
+PASS max.toString() is "7.922816251426434e+28"
+PASS (max + 1).toString() is "7.922816251426434e+28"
bits used to store value: 98
-
-min: -1.5845632502852868e+29
-
-min - 1: -1.5845632502852868e+29
-
-max: 1.5845632502852868e+29
-
-max + 1: 1.5845632502852868e+29
-
------
-
+PASS min.toString() is "-1.5845632502852868e+29"
+PASS (min - 1).toString() is "-1.5845632502852868e+29"
+PASS max.toString() is "1.5845632502852868e+29"
+PASS (max + 1).toString() is "1.5845632502852868e+29"
bits used to store value: 99
-
-min: -3.1691265005705735e+29
-
-min - 1: -3.1691265005705735e+29
-
-max: 3.1691265005705735e+29
-
-max + 1: 3.1691265005705735e+29
-
------
-
+PASS min.toString() is "-3.1691265005705735e+29"
+PASS (min - 1).toString() is "-3.1691265005705735e+29"
+PASS max.toString() is "3.1691265005705735e+29"
+PASS (max + 1).toString() is "3.1691265005705735e+29"
bits used to store value: 100
-
-min: -6.338253001141147e+29
-
-min - 1: -6.338253001141147e+29
-
-max: 6.338253001141147e+29
-
-max + 1: 6.338253001141147e+29
-
------
-
+PASS min.toString() is "-6.338253001141147e+29"
+PASS (min - 1).toString() is "-6.338253001141147e+29"
+PASS max.toString() is "6.338253001141147e+29"
+PASS (max + 1).toString() is "6.338253001141147e+29"
bits used to store value: 101
-
-min: -1.2676506002282294e+30
-
-min - 1: -1.2676506002282294e+30
-
-max: 1.2676506002282294e+30
-
-max + 1: 1.2676506002282294e+30
-
------
-
+PASS min.toString() is "-1.2676506002282294e+30"
+PASS (min - 1).toString() is "-1.2676506002282294e+30"
+PASS max.toString() is "1.2676506002282294e+30"
+PASS (max + 1).toString() is "1.2676506002282294e+30"
bits used to store value: 102
-
-min: -2.535301200456459e+30
-
-min - 1: -2.535301200456459e+30
-
-max: 2.535301200456459e+30
-
-max + 1: 2.535301200456459e+30
-
------
-
+PASS min.toString() is "-2.535301200456459e+30"
+PASS (min - 1).toString() is "-2.535301200456459e+30"
+PASS max.toString() is "2.535301200456459e+30"
+PASS (max + 1).toString() is "2.535301200456459e+30"
bits used to store value: 103
-
-min: -5.070602400912918e+30
-
-min - 1: -5.070602400912918e+30
-
-max: 5.070602400912918e+30
-
-max + 1: 5.070602400912918e+30
-
------
-
+PASS min.toString() is "-5.070602400912918e+30"
+PASS (min - 1).toString() is "-5.070602400912918e+30"
+PASS max.toString() is "5.070602400912918e+30"
+PASS (max + 1).toString() is "5.070602400912918e+30"
bits used to store value: 104
-
-min: -1.0141204801825835e+31
-
-min - 1: -1.0141204801825835e+31
-
-max: 1.0141204801825835e+31
-
-max + 1: 1.0141204801825835e+31
-
------
-
+PASS min.toString() is "-1.0141204801825835e+31"
+PASS (min - 1).toString() is "-1.0141204801825835e+31"
+PASS max.toString() is "1.0141204801825835e+31"
+PASS (max + 1).toString() is "1.0141204801825835e+31"
bits used to store value: 105
-
-min: -2.028240960365167e+31
-
-min - 1: -2.028240960365167e+31
-
-max: 2.028240960365167e+31
-
-max + 1: 2.028240960365167e+31
-
------
-
+PASS min.toString() is "-2.028240960365167e+31"
+PASS (min - 1).toString() is "-2.028240960365167e+31"
+PASS max.toString() is "2.028240960365167e+31"
+PASS (max + 1).toString() is "2.028240960365167e+31"
bits used to store value: 106
-
-min: -4.056481920730334e+31
-
-min - 1: -4.056481920730334e+31
-
-max: 4.056481920730334e+31
-
-max + 1: 4.056481920730334e+31
-
------
-
+PASS min.toString() is "-4.056481920730334e+31"
+PASS (min - 1).toString() is "-4.056481920730334e+31"
+PASS max.toString() is "4.056481920730334e+31"
+PASS (max + 1).toString() is "4.056481920730334e+31"
bits used to store value: 107
-
-min: -8.112963841460668e+31
-
-min - 1: -8.112963841460668e+31
-
-max: 8.112963841460668e+31
-
-max + 1: 8.112963841460668e+31
-
------
-
+PASS min.toString() is "-8.112963841460668e+31"
+PASS (min - 1).toString() is "-8.112963841460668e+31"
+PASS max.toString() is "8.112963841460668e+31"
+PASS (max + 1).toString() is "8.112963841460668e+31"
bits used to store value: 108
-
-min: -1.6225927682921336e+32
-
-min - 1: -1.6225927682921336e+32
-
-max: 1.6225927682921336e+32
-
-max + 1: 1.6225927682921336e+32
-
------
-
+PASS min.toString() is "-1.6225927682921336e+32"
+PASS (min - 1).toString() is "-1.6225927682921336e+32"
+PASS max.toString() is "1.6225927682921336e+32"
+PASS (max + 1).toString() is "1.6225927682921336e+32"
bits used to store value: 109
-
-min: -3.2451855365842673e+32
-
-min - 1: -3.2451855365842673e+32
-
-max: 3.2451855365842673e+32
-
-max + 1: 3.2451855365842673e+32
-
------
-
+PASS min.toString() is "-3.2451855365842673e+32"
+PASS (min - 1).toString() is "-3.2451855365842673e+32"
+PASS max.toString() is "3.2451855365842673e+32"
+PASS (max + 1).toString() is "3.2451855365842673e+32"
bits used to store value: 110
-
-min: -6.490371073168535e+32
-
-min - 1: -6.490371073168535e+32
-
-max: 6.490371073168535e+32
-
-max + 1: 6.490371073168535e+32
-
------
-
+PASS min.toString() is "-6.490371073168535e+32"
+PASS (min - 1).toString() is "-6.490371073168535e+32"
+PASS max.toString() is "6.490371073168535e+32"
+PASS (max + 1).toString() is "6.490371073168535e+32"
bits used to store value: 111
-
-min: -1.298074214633707e+33
-
-min - 1: -1.298074214633707e+33
-
-max: 1.298074214633707e+33
-
-max + 1: 1.298074214633707e+33
-
------
-
+PASS min.toString() is "-1.298074214633707e+33"
+PASS (min - 1).toString() is "-1.298074214633707e+33"
+PASS max.toString() is "1.298074214633707e+33"
+PASS (max + 1).toString() is "1.298074214633707e+33"
bits used to store value: 112
-
-min: -2.596148429267414e+33
-
-min - 1: -2.596148429267414e+33
-
-max: 2.596148429267414e+33
-
-max + 1: 2.596148429267414e+33
-
------
-
+PASS min.toString() is "-2.596148429267414e+33"
+PASS (min - 1).toString() is "-2.596148429267414e+33"
+PASS max.toString() is "2.596148429267414e+33"
+PASS (max + 1).toString() is "2.596148429267414e+33"
bits used to store value: 113
-
-min: -5.192296858534828e+33
-
-min - 1: -5.192296858534828e+33
-
-max: 5.192296858534828e+33
-
-max + 1: 5.192296858534828e+33
-
------
-
+PASS min.toString() is "-5.192296858534828e+33"
+PASS (min - 1).toString() is "-5.192296858534828e+33"
+PASS max.toString() is "5.192296858534828e+33"
+PASS (max + 1).toString() is "5.192296858534828e+33"
bits used to store value: 114
-
-min: -1.0384593717069655e+34
-
-min - 1: -1.0384593717069655e+34
-
-max: 1.0384593717069655e+34
-
-max + 1: 1.0384593717069655e+34
-
------
-
+PASS min.toString() is "-1.0384593717069655e+34"
+PASS (min - 1).toString() is "-1.0384593717069655e+34"
+PASS max.toString() is "1.0384593717069655e+34"
+PASS (max + 1).toString() is "1.0384593717069655e+34"
bits used to store value: 115
-
-min: -2.076918743413931e+34
-
-min - 1: -2.076918743413931e+34
-
-max: 2.076918743413931e+34
-
-max + 1: 2.076918743413931e+34
-
------
-
+PASS min.toString() is "-2.076918743413931e+34"
+PASS (min - 1).toString() is "-2.076918743413931e+34"
+PASS max.toString() is "2.076918743413931e+34"
+PASS (max + 1).toString() is "2.076918743413931e+34"
bits used to store value: 116
-
-min: -4.153837486827862e+34
-
-min - 1: -4.153837486827862e+34
-
-max: 4.153837486827862e+34
-
-max + 1: 4.153837486827862e+34
-
------
-
+PASS min.toString() is "-4.153837486827862e+34"
+PASS (min - 1).toString() is "-4.153837486827862e+34"
+PASS max.toString() is "4.153837486827862e+34"
+PASS (max + 1).toString() is "4.153837486827862e+34"
bits used to store value: 117
-
-min: -8.307674973655724e+34
-
-min - 1: -8.307674973655724e+34
-
-max: 8.307674973655724e+34
-
-max + 1: 8.307674973655724e+34
-
------
-
+PASS min.toString() is "-8.307674973655724e+34"
+PASS (min - 1).toString() is "-8.307674973655724e+34"
+PASS max.toString() is "8.307674973655724e+34"
+PASS (max + 1).toString() is "8.307674973655724e+34"
bits used to store value: 118
-
-min: -1.661534994731145e+35
-
-min - 1: -1.661534994731145e+35
-
-max: 1.661534994731145e+35
-
-max + 1: 1.661534994731145e+35
-
------
-
+PASS min.toString() is "-1.661534994731145e+35"
+PASS (min - 1).toString() is "-1.661534994731145e+35"
+PASS max.toString() is "1.661534994731145e+35"
+PASS (max + 1).toString() is "1.661534994731145e+35"
bits used to store value: 119
-
-min: -3.32306998946229e+35
-
-min - 1: -3.32306998946229e+35
-
-max: 3.32306998946229e+35
-
-max + 1: 3.32306998946229e+35
-
------
-
+PASS min.toString() is "-3.32306998946229e+35"
+PASS (min - 1).toString() is "-3.32306998946229e+35"
+PASS max.toString() is "3.32306998946229e+35"
+PASS (max + 1).toString() is "3.32306998946229e+35"
bits used to store value: 120
-
-min: -6.64613997892458e+35
-
-min - 1: -6.64613997892458e+35
-
-max: 6.64613997892458e+35
-
-max + 1: 6.64613997892458e+35
-
------
-
+PASS min.toString() is "-6.64613997892458e+35"
+PASS (min - 1).toString() is "-6.64613997892458e+35"
+PASS max.toString() is "6.64613997892458e+35"
+PASS (max + 1).toString() is "6.64613997892458e+35"
bits used to store value: 121
-
-min: -1.329227995784916e+36
-
-min - 1: -1.329227995784916e+36
-
-max: 1.329227995784916e+36
-
-max + 1: 1.329227995784916e+36
-
------
-
+PASS min.toString() is "-1.329227995784916e+36"
+PASS (min - 1).toString() is "-1.329227995784916e+36"
+PASS max.toString() is "1.329227995784916e+36"
+PASS (max + 1).toString() is "1.329227995784916e+36"
bits used to store value: 122
-
-min: -2.658455991569832e+36
-
-min - 1: -2.658455991569832e+36
-
-max: 2.658455991569832e+36
-
-max + 1: 2.658455991569832e+36
-
------
-
+PASS min.toString() is "-2.658455991569832e+36"
+PASS (min - 1).toString() is "-2.658455991569832e+36"
+PASS max.toString() is "2.658455991569832e+36"
+PASS (max + 1).toString() is "2.658455991569832e+36"
bits used to store value: 123
-
-min: -5.316911983139664e+36
-
-min - 1: -5.316911983139664e+36
-
-max: 5.316911983139664e+36
-
-max + 1: 5.316911983139664e+36
-
------
-
+PASS min.toString() is "-5.316911983139664e+36"
+PASS (min - 1).toString() is "-5.316911983139664e+36"
+PASS max.toString() is "5.316911983139664e+36"
+PASS (max + 1).toString() is "5.316911983139664e+36"
bits used to store value: 124
-
-min: -1.0633823966279327e+37
-
-min - 1: -1.0633823966279327e+37
-
-max: 1.0633823966279327e+37
-
-max + 1: 1.0633823966279327e+37
-
------
-
+PASS min.toString() is "-1.0633823966279327e+37"
+PASS (min - 1).toString() is "-1.0633823966279327e+37"
+PASS max.toString() is "1.0633823966279327e+37"
+PASS (max + 1).toString() is "1.0633823966279327e+37"
bits used to store value: 125
-
-min: -2.1267647932558654e+37
-
-min - 1: -2.1267647932558654e+37
-
-max: 2.1267647932558654e+37
-
-max + 1: 2.1267647932558654e+37
-
------
-
+PASS min.toString() is "-2.1267647932558654e+37"
+PASS (min - 1).toString() is "-2.1267647932558654e+37"
+PASS max.toString() is "2.1267647932558654e+37"
+PASS (max + 1).toString() is "2.1267647932558654e+37"
bits used to store value: 126
-
-min: -4.253529586511731e+37
-
-min - 1: -4.253529586511731e+37
-
-max: 4.253529586511731e+37
-
-max + 1: 4.253529586511731e+37
-
------
-
+PASS min.toString() is "-4.253529586511731e+37"
+PASS (min - 1).toString() is "-4.253529586511731e+37"
+PASS max.toString() is "4.253529586511731e+37"
+PASS (max + 1).toString() is "4.253529586511731e+37"
bits used to store value: 127
-
-min: -8.507059173023462e+37
-
-min - 1: -8.507059173023462e+37
-
-max: 8.507059173023462e+37
-
-max + 1: 8.507059173023462e+37
-
------
-
+PASS min.toString() is "-8.507059173023462e+37"
+PASS (min - 1).toString() is "-8.507059173023462e+37"
+PASS max.toString() is "8.507059173023462e+37"
+PASS (max + 1).toString() is "8.507059173023462e+37"
bits used to store value: 128
+PASS min.toString() is "-1.7014118346046923e+38"
+PASS (min - 1).toString() is "-1.7014118346046923e+38"
+PASS max.toString() is "1.7014118346046923e+38"
+PASS (max + 1).toString() is "1.7014118346046923e+38"
+PASS successfullyParsed is true
-min: -1.7014118346046923e+38
-
-min - 1: -1.7014118346046923e+38
-
-max: 1.7014118346046923e+38
+TEST COMPLETE
-max + 1: 1.7014118346046923e+38
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
-<script>
-function print(message) {
- var paragraph = document.createElement("p");
- paragraph.appendChild(document.createTextNode(message));
- document.getElementById("console").appendChild(paragraph);
-}
-
-function test() {
- if (window.layoutTestController) {
- layoutTestController.dumpAsText();
- }
-
- print("-1: " + -1);
- print("0: " + 0);
- print("-0: " + -0);
-
- for (var valueBits = 8; valueBits <= 128; valueBits++) {
- print("-----");
- print("bits used to store value: " + valueBits);
- var max = Math.pow(2, valueBits - 1) - 1;
- var min = -Math.pow(2, valueBits - 1);
- print("min: " + min);
- print("min - 1: " + (min - 1));
- print("max: " + max);
- print("max + 1: " + (max + 1));
- }
-}
-</script>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
</head>
-<body onload="test();">
-<p>This test verifies that the bit twiddling done in JavaScriptCore's integer machinery works correctly on the current platform.</p>
-<p>Below, you will see a listing of the extremes related to representing integers using a certain number of bits. If the test succeeds, you should see:</p>
-<ul>
-<li> 0, -0, and -1</li>
-<li> max: 2 ^ ([number of bits] - 1) - 1</li>
-<li> min: -(max + 1)</li>
-<li> a corresponding max + 1 and min - 1</li>
-</ul>
-<hr>
-<div id='console'/>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/integer-extremes.js"></script>
+<script src="resources/js-test-post.js"></script>
</body>
</html>
--- /dev/null
+This tests that isPrototypeOf works according to the ECMA spec.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS Object.isPrototypeOf('string') is false
+PASS Array.prototype.isPrototypeOf(new Array()) is true
+PASS ObjectA.prototype.isPrototypeOf(objb) is true
+PASS ObjectA.prototype.isPrototypeOf(objc) is true
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
--- /dev/null
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href="resources/js-test-style.css">
+<script src="resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script src="resources/isPrototypeOf.js"></script>
+<script src="resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS Array().length is 0
PASS (new Array()).length is 0
PASS (new Array(3)).length is 3
FAIL propnames[2] should be 2. Was 1
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/Array.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS Boolean() is false
PASS Boolean(true) is true
PASS Boolean(false) is false
PASS false.toString() === 'false' is true
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/Boolean.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
-Start Of Test
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+Start Of Test
PASS isNaN(Date.prototype.valueOf()) is true
PASS d.getMinutes() is 45
PASS d.getUTCMinutes() is 45
PASS (new Date('January29,2005')).getDate() is 29
FAIL (new Date('12/25/1995 ::')).valueOf() should be 819878400000. Was NaN
End Of Test
-
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/Date.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS Error('msg').message is 'msg'
PASS (new Error('msg')).message is 'msg'
PASS (new Error('msg')).name is 'Error'
PASS Object.prototype.toString.apply(EvalError) is '[object Function]'
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/Error.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS h.charCodeAt(1) is 239
PASS u.charCodeAt(1) is 4660
PASS escape(h) is 'a%EFc'
PASS delete undefined is false
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/GlobalObject.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS Number() is 0
PASS Number(1) is 1
PASS Number(1.1) is 1.1
PASS Number(0).toPrecision(21) is "0.00000000000000000000"
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/Number.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS typeof Object() is 'object'
PASS var o = Object(); o.x = 11; o.x; is 11
PASS Object(1).valueOf() is 1
PASS String(Object().valueOf()) is '[object Object]'
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/Object.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS s.area() is 9
PASS b.name is 'a book'
PASS b.author is 'Fred'
PASS delete Boolean.prototype is false
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/Prototype.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS (new RegExp()).source is ''
PASS Boolean(new RegExp()) is true
PASS isNaN(Number(new RegExp())) is true
FAIL Object.prototype.toString.apply(RegExp.prototype) should be [object RegExp]. Was [object RegExpPrototype]
PASS typeof RegExp.prototype.toString() is 'string'
Done.
-
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/RegExp.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS 'abc'.length is 3
PASS (new String('abcd')).length is 4
PASS String('abcde').length is 5
PASS 'ab'.indexOf('a', -1) is 0
PASS 'ab'.indexOf('b', 1) is 1
PASS 'ab'.indexOf('a', 1) is -1
-PASS ' '.indexOf('', 1) is 1
+PASS ' '.indexOf('', 1) is 1
PASS String('abc').search(/b/) is 1
PASS String('xyz').search(/b/) is -1
PASS String('abcb').match(/b/) + '' is 'b'
PASS var reg = /ab/g; 'aabab'.match(reg).length is 2
PASS var reg = /ab/g; 'xxx'.match(reg); reg.lastIndex is 0
PASS var reg = /ab/g; 'xxx'.match(reg) is null
-PASS myRe=/d(b+)d/g; 'cdbbdbsbz'.match(myRe)[0] is 'dbbd'
+PASS myRe=/d(b+)d/g; 'cdbbdbsbz'.match(myRe)[0] is 'dbbd'
PASS 'abcd'.replace(/b./, 'xy') is 'axyd'
PASS 'abcd'.replace('bc', 'x') is 'axd'
PASS 'abcd'.replace('x', 'y') is 'abcd'
PASS bar is html
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/StringObject.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS var i = 1; i is 1
PASS j = k = 2 is 2
PASS var i; i is undefined.
PASS var i = -8; i >>>= 24 is 255
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/assignments.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS Boolean(1) === true is true
PASS var s = String; s(1) === '1' is true
PASS n = Number; n(true) === 1 is true
PASS String(Array('a', 'b' )) is 'a,b'
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/cast.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/comment-1.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/comment-2.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS foo(), i is 2
PASS caught is true
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/completion.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS true ? 1 : 2 is 1
PASS false ? 1 : 2 is 2
PASS 'abc' ? 1 : 2 is 1
PASS /*var a=1;if (undefined) a = 2;*/ a is 1
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/conditional.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS c is 11
PASS c is 11
PASS v is 1
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/const.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS Object.length is 1
PASS Function.length is 1
PASS Array.length is 1
PASS URIError.length is 1
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/constructor_length.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/crash-1.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
-OK. Caught an exception
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+OK. Caught an exception
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/crash-2.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS a = 1; delete a; is true
PASS delete nonexistant; is true
PASS delete NaN is false
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/delete.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/empty.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
FAIL checkWithFunctions(encodeURI,decodeURI) should be true. Was false
FAIL checkWithFunctions(encodeURIComponent,decodeURIComponent) should be true. Was false
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/encode_decode_uri.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS eval.length is 1
PASS eval('this') is this
PASS bx is 99
PASS lotto() is 0
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/eval.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
FAIL (new Error()).message should be undefined. Was Unknown error
PASS ''.split(/.*/).length is 0
FAIL window.successfullyParsed should be undefined. Was true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/evil-n.js"></script>
-<script>
-shouldBeUndefined("window.successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post-n.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
FAIL successfullyParsed should be true. Threw exception ReferenceError: Can't find variable: successfullyParsed
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/exception_propagation.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
-Except a lot of errors. They should all be caught and lead to PASS
+KDE JS Test
-testing throw() .......... PASS
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-testing throw() .......... PASS
+Except a lot of errors. They should all be caught and lead to PASS
+testing throw() .......... PASS
+testing throw() .......... PASS
ReferenceError .......... PASS
-
error propagation in functions .......... PASS
-
catch
-
finally
-
Math() error .......... PASS
-
Abort while() on error .......... PASS
-
undefined .......... FAIL
+TEST COMPLETE
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/exceptions.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS empty1() is undefined
PASS empty2() is undefined
PASS obj.func(11) is 66
PASS typeof orgFuncClone is 'function'
PASS orgFuncClone('world') is 'Hello world'
PASS groupClone(1, 2) is 9
-FAIL String(Math.sin) should be function sin() { [native code] } . Was (Internal Function)
+FAIL String(Math.sin) should be
+function sin() {
+ [native code]
+}
+. Was (Internal Function)
PASS shadow() is 2
PASS nestedret is 'outer nest'
PASS not_nestedret is 'global nest'
PASS functionWithVarOverride(1) is 2
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/function.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS mf.arguments is expected[expno++]
PASS mf.arguments[0] is expected[expno++]
PASS mf.arguments[0] is expected[expno++]
PASS newx is 888
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/function_arguments.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS myfunc.prototype.constructor.__proto__ == Function.prototype is true
PASS myfunc.prototype.constructor.__proto__.__proto__ == Object.prototype is true
PASS myfunc.prototype.constructor == myfunc is true
PASS myfunc.toString == Function.prototype.toString is true
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/function_constructor.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS Array.prototype.toString.length is 0
PASS Array.prototype.toLocaleString.length is 0
PASS Array.prototype.concat.length is 1
PASS Number.prototype.toFixed.length is 1
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/function_length.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS window.successfullyParsed is undefined.
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/garbage-n.js"></script>
-<script>
-shouldBeUndefined("window.successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post-n.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS Object.prototype.toString.__proto__ is Function.prototype
PASS Object.prototype.valueOf.__proto__ is Function.prototype
PASS Array.prototype.toString.__proto__ is Function.prototype
PASS Error.prototype.toString.__proto__ is Function.prototype
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/inbuilt_function_proto.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
FAIL StripSpaces(eval.toString()) should be functioneval(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(parseInt.toString()) should be functionparseInt(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(parseFloat.toString()) should be functionparseFloat(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(isFinite.toString()) should be functionisFinite(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(escape.toString()) should be functionescape(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(unescape.toString()) should be functionunescape(){[nativecode]}. Was (InternalFunction)
-FAIL StripSpaces(kjsprint.toString()) should be functionkjsprint(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(Object.prototype.toString.toString()) should be functiontoString(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(Object.prototype.toLocaleString.toString()) should be functiontoLocaleString(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(Object.prototype.valueOf.toString()) should be functionvalueOf(){[nativecode]}. Was (InternalFunction)
FAIL StripSpaces(Error.prototype.toString.toString()) should be functiontoString(){[nativecode]}. Was (InternalFunction)
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/inbuilt_function_tostring.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS count is 10
PASS count is 5
PASS count is 10
PASS list is '123'
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/iteration.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/j-comment-3.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS successfullyParsed is true
+TEST COMPLETE
+
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
- <!-- This file allows to run a javascript test in another browser.
- Simply change the script inclusion at the end of the file -->
-<script src="resources/base.js"></script>
+<head>
+<link rel="stylesheet" href="../resources/js-test-style.css">
+<script src="../resources/js-test-pre.js"></script>
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
<script>
-if (window.layoutTestController)
- layoutTestController.dumpAsText();
-
-function testPassed(msg)
-{
- document.write("<b><font color=green>PASS</font></b> " + msg + "<br>");
-}
-
-function testFailed(msg)
-{
- document.write("<b><font color=red>FAIL</font></b> " + msg + "<br>");
-}
-
-function debug(a)
-{
- document.write("<p> " + a + "</p>");
-}
+description("KDE JS Test");
</script>
-
<script src="resources/j-comment-4.js"></script>
-<script>
-shouldBeTrue("successfullyParsed");
-</script>
-</html>
\ No newline at end of file
+<script src="../resources/js-test-post.js"></script>
+</body>
+</html>
+KDE JS Test
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
PASS x is 1
PASS 0x0 is 0
PASS 0xF is 15
PASS 019 is 19
PASS successfullyParsed is true
+TEST COMPLETE
+