fast/canvas/webgl/angle-instanced-arrays.html is very flaky
authorap@apple.com <ap@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 27 Dec 2014 23:22:02 +0000 (23:22 +0000)
committerap@apple.com <ap@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 27 Dec 2014 23:22:02 +0000 (23:22 +0000)
https://bugs.webkit.org/show_bug.cgi?id=139958

Reviewed by Darin Adler.

WebGL test harness added js-test-post.js in a flaky manner, and to make things worse,
this test also had its own include of js-test-post.js.

Looking at the tests, I noticed that the way test harnesses were used was a big mess,
so I went over the whole directory, making these changes:
1. Use js-test.js instead of js-test-pre.js, because it's simpler and better macthes
the Khronos test model.
2. Removed js-test-post.js everywhere (some tests included it in particularly crazy ways).
3. Removed successfullyParsed = true, as js-test.js doesn't need that.
4. Updated DOCTYPE, while editing these tests anyway.
5. Tests now have correct order of lines in the output (no longer saying TEST COMPLETE
before PASS), so updated results.
6. In js-test tests, we shouldn't use waitUntilDone/notifyDone explicitly, so
updated these with jsTestIsAsync.
7. Updated async tests that used initNonKhronosFramework(false) plus some way to
become async to simply say initNonKhronosFramework(true).
8. Removed isSuccessfullyParsed() calls that several tests were using as an ugly
workaround for issues caused by misusing the harness. This is never expected to be
called directly.

* fast/canvas/webgl/angle-instanced-arrays-out-of-bounds.html:
Removed an unneeded js-test-style.css include.

* fast/canvas/webgl/framebuffer-bindings-unaffected-on-resize.html:
Swapped lines to not have glErrorShouldBe after finishTest.

* fast/canvas/webgl/resources/webgl-test.js:
(initNonKhronosFramework): webgl-test.js relies on js-test anyway, so there is
no need to duplicate the work.
(nonKhronosFrameworkNotifyDone): Use the proper js-test mechanism.
(finishTest): Ditto.
(finishTest.epilogue.document.createElement.epilogue.onload): Deleted.

* resources/js-test.js:
(expectTrue): Added this function that we only has in js-test-pre.js.
(): Perform work after test's load event handler, not immediately on DOMContentLoaded.
This has two benefits:
1. Tests that enable jsTestIsAsync in onload do work. This is expected, because
tests that call waitUntilDone from onload also do work.
2. Non-async tests that perform work in onload have the correct order of lines in output.

* fast/dom/HTMLImageElement/sizes/image-sizes-1x-expected.txt:
* fast/dom/HTMLImageElement/sizes/image-sizes-2x-expected.txt:
* fast/dom/HTMLImageElement/sizes/image-sizes-js-innerhtml-expected.txt:
* fast/hidpi/image-srcset-invalid-descriptor-expected.txt:
* fast/hidpi/image-srcset-src-selection-1x-both-expected.txt:
* svg/custom/html_document_set_title-expected.txt:
Updated results for js-test.js improvements.

* fast/canvas/webgl/WebGLContextEvent.html:
* fast/canvas/webgl/angle-instanced-arrays.html:
* fast/canvas/webgl/array-bounds-clamping.html:
* fast/canvas/webgl/array-buffer-crash.html:
* fast/canvas/webgl/array-buffer-view-crash-when-reassigned.html:
* fast/canvas/webgl/array-buffer-view-crash.html:
* fast/canvas/webgl/array-constructor.html:
* fast/canvas/webgl/array-get-and-set-method-removal.html:
* fast/canvas/webgl/array-get-out-of-bounds.html:
* fast/canvas/webgl/array-message-passing.html:
* fast/canvas/webgl/array-override-set.html:
* fast/canvas/webgl/array-set-invalid-arguments.html:
* fast/canvas/webgl/array-set-out-of-bounds.html:
* fast/canvas/webgl/array-set-with-offset.html:
* fast/canvas/webgl/array-setters.html:
* fast/canvas/webgl/array-unit-tests.html:
* fast/canvas/webgl/arraybuffer-transfer-of-control.html:
* fast/canvas/webgl/attrib-location-length-limits.html:
* fast/canvas/webgl/bad-arguments-test.html:
* fast/canvas/webgl/buffer-bind-test.html:
* fast/canvas/webgl/buffer-data-array-buffer.html:
* fast/canvas/webgl/canvas-2d-webgl-texture-expected.txt:
* fast/canvas/webgl/canvas-2d-webgl-texture.html:
* fast/canvas/webgl/canvas-resize-crash.html:
* fast/canvas/webgl/canvas-supports-context.html:
* fast/canvas/webgl/canvas-test.html:
* fast/canvas/webgl/canvas-zero-size.html:
* fast/canvas/webgl/compressed-tex-image.html:
* fast/canvas/webgl/constants.html:
* fast/canvas/webgl/context-attributes-alpha-depth-stencil-antialias.html:
* fast/canvas/webgl/context-creation-and-destruction.html:
* fast/canvas/webgl/context-lost-restored.html:
* fast/canvas/webgl/context-lost.html:
* fast/canvas/webgl/context-release-upon-reload.html:
* fast/canvas/webgl/copy-tex-image-and-sub-image-2d.html:
* fast/canvas/webgl/data-view-crash.html:
* fast/canvas/webgl/data-view-test.html:
* fast/canvas/webgl/draw-arrays-out-of-bounds.html:
* fast/canvas/webgl/draw-elements-out-of-bounds.html:
* fast/canvas/webgl/drawingbuffer-test.html:
* fast/canvas/webgl/error-reporting.html:
* fast/canvas/webgl/framebuffer-object-attachment.html:
* fast/canvas/webgl/framebuffer-test.html:
* fast/canvas/webgl/functions-returning-strings.html:
* fast/canvas/webgl/get-active-test.html:
* fast/canvas/webgl/gl-bind-attrib-location-before-compile-test.html:
* fast/canvas/webgl/gl-bind-attrib-location-test.html:
* fast/canvas/webgl/gl-bind-attrib-mapped-names.html:
* fast/canvas/webgl/gl-enable-enum-test.html:
* fast/canvas/webgl/gl-enum-tests.html:
* fast/canvas/webgl/gl-get-calls.html:
* fast/canvas/webgl/gl-getshadersource.html:
* fast/canvas/webgl/gl-getstring.html:
* fast/canvas/webgl/gl-object-get-calls.html:
* fast/canvas/webgl/gl-pixelstorei.html:
* fast/canvas/webgl/gl-teximage.html:
* fast/canvas/webgl/gl-uniform-arrays.html:
* fast/canvas/webgl/gl-uniformmatrix4fv.html:
* fast/canvas/webgl/gl-vertex-attrib-zero-issues.html:
* fast/canvas/webgl/gl-vertex-attrib.html:
* fast/canvas/webgl/gl-vertexattribpointer.html:
* fast/canvas/webgl/glsl-conformance.html:
* fast/canvas/webgl/incorrect-context-object-behaviour.html:
* fast/canvas/webgl/index-validation-copies-indices.html:
* fast/canvas/webgl/index-validation-crash-with-buffer-sub-data.html:
* fast/canvas/webgl/index-validation-verifies-too-many-indices.html:
* fast/canvas/webgl/index-validation-with-resized-buffer.html:
* fast/canvas/webgl/index-validation.html:
* fast/canvas/webgl/instanceof-test.html:
* fast/canvas/webgl/invalid-UTF-16.html:
* fast/canvas/webgl/invalid-passed-params.html:
* fast/canvas/webgl/is-object.html:
* fast/canvas/webgl/null-object-behaviour.html:
* fast/canvas/webgl/null-uniform-location.html:
* fast/canvas/webgl/object-deletion-behaviour.html:
* fast/canvas/webgl/oes-element-index-uint.html:
* fast/canvas/webgl/oes-texture-float-linear-expected.txt:
* fast/canvas/webgl/oes-texture-float-linear.html:
* fast/canvas/webgl/oes-texture-half-float-linear-expected.txt:
* fast/canvas/webgl/oes-texture-half-float-linear.html:
* fast/canvas/webgl/oes-texture-half-float-with-canvas.html:
* fast/canvas/webgl/oes-texture-half-float-with-image.html:
* fast/canvas/webgl/oes-texture-half-float-with-video.html:
* fast/canvas/webgl/oes-texture-half-float.html:
* fast/canvas/webgl/oes-vertex-array-object.html:
* fast/canvas/webgl/point-size.html:
* fast/canvas/webgl/premultiplyalpha-test-expected.txt:
* fast/canvas/webgl/premultiplyalpha-test.html:
* fast/canvas/webgl/program-test.html:
* fast/canvas/webgl/read-pixels-pack-alignment.html:
* fast/canvas/webgl/read-pixels-test.html:
* fast/canvas/webgl/renderbuffer-initialization.html:
* fast/canvas/webgl/renderer-and-vendor-strings.html:
* fast/canvas/webgl/resources/tex-image-and-sub-image-2d-with-video.js:
* fast/canvas/webgl/script-tests/arraybuffer-transfer-of-control.js:
* fast/canvas/webgl/shader-deleted-by-accessor.html:
* fast/canvas/webgl/shader-precision-format.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-array-buffer-view.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgb565.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgba4444.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgba5551.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgb565.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgba4444.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgba5551.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgb565.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba4444.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba5551.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-image.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-potentially-subsampled-image.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-svg-image.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgb565.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgba4444.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgba5551.html:
* fast/canvas/webgl/tex-image-and-sub-image-2d-with-video.html:
* fast/canvas/webgl/tex-image-and-uniform-binding-bugs.html:
* fast/canvas/webgl/tex-image-webgl.html:
* fast/canvas/webgl/tex-image-with-format-and-type.html:
* fast/canvas/webgl/tex-image-with-greyscale-image.html:
* fast/canvas/webgl/tex-input-validation.html:
* fast/canvas/webgl/tex-sub-image-2d-bad-args.html:
* fast/canvas/webgl/tex-sub-image-2d.html:
* fast/canvas/webgl/tex-sub-image-cube-maps.html:
* fast/canvas/webgl/texImageTest.html:
* fast/canvas/webgl/texture-active-bind.html:
* fast/canvas/webgl/texture-bindings-uneffected-on-resize-expected.txt:
* fast/canvas/webgl/texture-bindings-uneffected-on-resize.html:
* fast/canvas/webgl/texture-color-profile.html:
* fast/canvas/webgl/texture-complete.html:
* fast/canvas/webgl/texture-npot.html:
* fast/canvas/webgl/texture-transparent-pixels-initialized.html:
* fast/canvas/webgl/triangle.html:
* fast/canvas/webgl/type-conversion-test.html:
* fast/canvas/webgl/typed-arrays-in-workers.html:
* fast/canvas/webgl/uniform-array-length-overflow.html:
* fast/canvas/webgl/uniform-location-length-limits.html:
* fast/canvas/webgl/uniform-location.html:
* fast/canvas/webgl/uniform-samplers-test.html:
* fast/canvas/webgl/uninitialized-test.html:
* fast/canvas/webgl/viewport-unchanged-upon-resize.html:
* fast/canvas/webgl/webgl-array-invalid-ranges.html:
* fast/canvas/webgl/webgl-compressed-texture-size-limit.html:
* fast/canvas/webgl/webgl-depth-texture-expected.txt:
* fast/canvas/webgl/webgl-depth-texture.html:
* fast/canvas/webgl/webgl-draw-buffers.html:
* fast/canvas/webgl/webgl-exceptions.html:
* fast/canvas/webgl/webgl-specific.html:
* fast/canvas/webgl/webgl-texture-binding-preserved-expected.txt:
* fast/canvas/webgl/webgl-texture-binding-preserved.html:
* fast/canvas/webgl/webgl-unprefixed-context-id.html:
* fast/canvas/webgl/webgl-viewport-parameters-preserved-expected.txt:
* fast/canvas/webgl/webgl-viewport-parameters-preserved.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@177772 268f45cc-cd09-0410-ab3c-d52691b4dbfc

164 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/canvas/webgl/WebGLContextEvent.html
LayoutTests/fast/canvas/webgl/angle-instanced-arrays-out-of-bounds.html
LayoutTests/fast/canvas/webgl/angle-instanced-arrays.html
LayoutTests/fast/canvas/webgl/array-bounds-clamping.html
LayoutTests/fast/canvas/webgl/array-buffer-crash.html
LayoutTests/fast/canvas/webgl/array-buffer-view-crash-when-reassigned.html
LayoutTests/fast/canvas/webgl/array-buffer-view-crash.html
LayoutTests/fast/canvas/webgl/array-constructor.html
LayoutTests/fast/canvas/webgl/array-get-and-set-method-removal.html
LayoutTests/fast/canvas/webgl/array-get-out-of-bounds.html
LayoutTests/fast/canvas/webgl/array-message-passing.html
LayoutTests/fast/canvas/webgl/array-override-set.html
LayoutTests/fast/canvas/webgl/array-set-invalid-arguments.html
LayoutTests/fast/canvas/webgl/array-set-out-of-bounds.html
LayoutTests/fast/canvas/webgl/array-set-with-offset.html
LayoutTests/fast/canvas/webgl/array-setters.html
LayoutTests/fast/canvas/webgl/array-unit-tests.html
LayoutTests/fast/canvas/webgl/arraybuffer-transfer-of-control.html
LayoutTests/fast/canvas/webgl/attrib-location-length-limits.html
LayoutTests/fast/canvas/webgl/bad-arguments-test.html
LayoutTests/fast/canvas/webgl/buffer-bind-test.html
LayoutTests/fast/canvas/webgl/buffer-data-array-buffer.html
LayoutTests/fast/canvas/webgl/canvas-2d-webgl-texture-expected.txt
LayoutTests/fast/canvas/webgl/canvas-2d-webgl-texture.html
LayoutTests/fast/canvas/webgl/canvas-resize-crash.html
LayoutTests/fast/canvas/webgl/canvas-supports-context.html
LayoutTests/fast/canvas/webgl/canvas-test.html
LayoutTests/fast/canvas/webgl/canvas-zero-size.html
LayoutTests/fast/canvas/webgl/compressed-tex-image.html
LayoutTests/fast/canvas/webgl/constants.html
LayoutTests/fast/canvas/webgl/context-attributes-alpha-depth-stencil-antialias.html
LayoutTests/fast/canvas/webgl/context-creation-and-destruction.html
LayoutTests/fast/canvas/webgl/context-lost-restored.html
LayoutTests/fast/canvas/webgl/context-lost.html
LayoutTests/fast/canvas/webgl/context-release-upon-reload.html
LayoutTests/fast/canvas/webgl/copy-tex-image-and-sub-image-2d.html
LayoutTests/fast/canvas/webgl/data-view-crash.html
LayoutTests/fast/canvas/webgl/data-view-test.html
LayoutTests/fast/canvas/webgl/draw-arrays-out-of-bounds.html
LayoutTests/fast/canvas/webgl/draw-elements-out-of-bounds.html
LayoutTests/fast/canvas/webgl/drawingbuffer-test.html
LayoutTests/fast/canvas/webgl/error-reporting.html
LayoutTests/fast/canvas/webgl/framebuffer-bindings-unaffected-on-resize.html
LayoutTests/fast/canvas/webgl/framebuffer-object-attachment.html
LayoutTests/fast/canvas/webgl/framebuffer-test.html
LayoutTests/fast/canvas/webgl/functions-returning-strings.html
LayoutTests/fast/canvas/webgl/get-active-test.html
LayoutTests/fast/canvas/webgl/gl-bind-attrib-location-before-compile-test.html
LayoutTests/fast/canvas/webgl/gl-bind-attrib-location-test.html
LayoutTests/fast/canvas/webgl/gl-bind-attrib-mapped-names.html
LayoutTests/fast/canvas/webgl/gl-enable-enum-test.html
LayoutTests/fast/canvas/webgl/gl-enum-tests.html
LayoutTests/fast/canvas/webgl/gl-get-calls.html
LayoutTests/fast/canvas/webgl/gl-getshadersource.html
LayoutTests/fast/canvas/webgl/gl-getstring.html
LayoutTests/fast/canvas/webgl/gl-object-get-calls.html
LayoutTests/fast/canvas/webgl/gl-pixelstorei.html
LayoutTests/fast/canvas/webgl/gl-teximage.html
LayoutTests/fast/canvas/webgl/gl-uniform-arrays.html
LayoutTests/fast/canvas/webgl/gl-uniformmatrix4fv.html
LayoutTests/fast/canvas/webgl/gl-vertex-attrib-zero-issues.html
LayoutTests/fast/canvas/webgl/gl-vertex-attrib.html
LayoutTests/fast/canvas/webgl/gl-vertexattribpointer.html
LayoutTests/fast/canvas/webgl/glsl-conformance.html
LayoutTests/fast/canvas/webgl/incorrect-context-object-behaviour.html
LayoutTests/fast/canvas/webgl/index-validation-copies-indices.html
LayoutTests/fast/canvas/webgl/index-validation-crash-with-buffer-sub-data.html
LayoutTests/fast/canvas/webgl/index-validation-verifies-too-many-indices.html
LayoutTests/fast/canvas/webgl/index-validation-with-resized-buffer.html
LayoutTests/fast/canvas/webgl/index-validation.html
LayoutTests/fast/canvas/webgl/instanceof-test.html
LayoutTests/fast/canvas/webgl/invalid-UTF-16.html
LayoutTests/fast/canvas/webgl/invalid-passed-params.html
LayoutTests/fast/canvas/webgl/is-object.html
LayoutTests/fast/canvas/webgl/null-object-behaviour.html
LayoutTests/fast/canvas/webgl/null-uniform-location.html
LayoutTests/fast/canvas/webgl/object-deletion-behaviour.html
LayoutTests/fast/canvas/webgl/oes-element-index-uint.html
LayoutTests/fast/canvas/webgl/oes-texture-float-linear-expected.txt
LayoutTests/fast/canvas/webgl/oes-texture-float-linear.html
LayoutTests/fast/canvas/webgl/oes-texture-half-float-linear-expected.txt
LayoutTests/fast/canvas/webgl/oes-texture-half-float-linear.html
LayoutTests/fast/canvas/webgl/oes-texture-half-float-with-canvas.html
LayoutTests/fast/canvas/webgl/oes-texture-half-float-with-image.html
LayoutTests/fast/canvas/webgl/oes-texture-half-float-with-video.html
LayoutTests/fast/canvas/webgl/oes-texture-half-float.html
LayoutTests/fast/canvas/webgl/oes-vertex-array-object.html
LayoutTests/fast/canvas/webgl/point-size.html
LayoutTests/fast/canvas/webgl/premultiplyalpha-test-expected.txt
LayoutTests/fast/canvas/webgl/premultiplyalpha-test.html
LayoutTests/fast/canvas/webgl/program-test.html
LayoutTests/fast/canvas/webgl/read-pixels-pack-alignment.html
LayoutTests/fast/canvas/webgl/read-pixels-test.html
LayoutTests/fast/canvas/webgl/renderbuffer-initialization.html
LayoutTests/fast/canvas/webgl/renderer-and-vendor-strings.html
LayoutTests/fast/canvas/webgl/resources/tex-image-and-sub-image-2d-with-video.js
LayoutTests/fast/canvas/webgl/resources/webgl-test.js
LayoutTests/fast/canvas/webgl/script-tests/arraybuffer-transfer-of-control.js
LayoutTests/fast/canvas/webgl/shader-deleted-by-accessor.html
LayoutTests/fast/canvas/webgl/shader-precision-format.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-array-buffer-view.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgb565.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgba4444.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgba5551.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgb565.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgba4444.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgba5551.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgb565.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba4444.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba5551.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-image.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-potentially-subsampled-image.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-svg-image.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgb565.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgba4444.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgba5551.html
LayoutTests/fast/canvas/webgl/tex-image-and-sub-image-2d-with-video.html
LayoutTests/fast/canvas/webgl/tex-image-and-uniform-binding-bugs.html
LayoutTests/fast/canvas/webgl/tex-image-webgl.html
LayoutTests/fast/canvas/webgl/tex-image-with-format-and-type.html
LayoutTests/fast/canvas/webgl/tex-image-with-greyscale-image.html
LayoutTests/fast/canvas/webgl/tex-input-validation.html
LayoutTests/fast/canvas/webgl/tex-sub-image-2d-bad-args.html
LayoutTests/fast/canvas/webgl/tex-sub-image-2d.html
LayoutTests/fast/canvas/webgl/tex-sub-image-cube-maps.html
LayoutTests/fast/canvas/webgl/texImageTest.html
LayoutTests/fast/canvas/webgl/texture-active-bind.html
LayoutTests/fast/canvas/webgl/texture-bindings-uneffected-on-resize-expected.txt
LayoutTests/fast/canvas/webgl/texture-bindings-uneffected-on-resize.html
LayoutTests/fast/canvas/webgl/texture-color-profile.html
LayoutTests/fast/canvas/webgl/texture-complete.html
LayoutTests/fast/canvas/webgl/texture-npot.html
LayoutTests/fast/canvas/webgl/texture-transparent-pixels-initialized.html
LayoutTests/fast/canvas/webgl/triangle.html
LayoutTests/fast/canvas/webgl/type-conversion-test.html
LayoutTests/fast/canvas/webgl/typed-arrays-in-workers.html
LayoutTests/fast/canvas/webgl/uniform-array-length-overflow.html
LayoutTests/fast/canvas/webgl/uniform-location-length-limits.html
LayoutTests/fast/canvas/webgl/uniform-location.html
LayoutTests/fast/canvas/webgl/uniform-samplers-test.html
LayoutTests/fast/canvas/webgl/uninitialized-test.html
LayoutTests/fast/canvas/webgl/viewport-unchanged-upon-resize.html
LayoutTests/fast/canvas/webgl/webgl-array-invalid-ranges.html
LayoutTests/fast/canvas/webgl/webgl-compressed-texture-size-limit.html
LayoutTests/fast/canvas/webgl/webgl-depth-texture-expected.txt
LayoutTests/fast/canvas/webgl/webgl-depth-texture.html
LayoutTests/fast/canvas/webgl/webgl-draw-buffers.html
LayoutTests/fast/canvas/webgl/webgl-exceptions.html
LayoutTests/fast/canvas/webgl/webgl-specific.html
LayoutTests/fast/canvas/webgl/webgl-texture-binding-preserved-expected.txt
LayoutTests/fast/canvas/webgl/webgl-texture-binding-preserved.html
LayoutTests/fast/canvas/webgl/webgl-unprefixed-context-id.html
LayoutTests/fast/canvas/webgl/webgl-viewport-parameters-preserved-expected.txt
LayoutTests/fast/canvas/webgl/webgl-viewport-parameters-preserved.html
LayoutTests/fast/dom/HTMLImageElement/sizes/image-sizes-1x-expected.txt
LayoutTests/fast/dom/HTMLImageElement/sizes/image-sizes-2x-expected.txt
LayoutTests/fast/dom/HTMLImageElement/sizes/image-sizes-js-innerhtml-expected.txt
LayoutTests/fast/hidpi/image-srcset-invalid-descriptor-expected.txt
LayoutTests/fast/hidpi/image-srcset-src-selection-1x-both-expected.txt
LayoutTests/resources/js-test.js
LayoutTests/svg/custom/html_document_set_title-expected.txt

index 9666627..35bd657 100644 (file)
@@ -1,3 +1,213 @@
+2014-12-27  Alexey Proskuryakov  <ap@apple.com>
+
+        fast/canvas/webgl/angle-instanced-arrays.html is very flaky
+        https://bugs.webkit.org/show_bug.cgi?id=139958
+
+        Reviewed by Darin Adler.
+
+        WebGL test harness added js-test-post.js in a flaky manner, and to make things worse,
+        this test also had its own include of js-test-post.js.
+
+        Looking at the tests, I noticed that the way test harnesses were used was a big mess,
+        so I went over the whole directory, making these changes:
+        1. Use js-test.js instead of js-test-pre.js, because it's simpler and better macthes
+        the Khronos test model.
+        2. Removed js-test-post.js everywhere (some tests included it in particularly crazy ways).
+        3. Removed successfullyParsed = true, as js-test.js doesn't need that.
+        4. Updated DOCTYPE, while editing these tests anyway.
+        5. Tests now have correct order of lines in the output (no longer saying TEST COMPLETE
+        before PASS), so updated results.
+        6. In js-test tests, we shouldn't use waitUntilDone/notifyDone explicitly, so
+        updated these with jsTestIsAsync.
+        7. Updated async tests that used initNonKhronosFramework(false) plus some way to
+        become async to simply say initNonKhronosFramework(true).
+        8. Removed isSuccessfullyParsed() calls that several tests were using as an ugly
+        workaround for issues caused by misusing the harness. This is never expected to be
+        called directly.
+
+        * fast/canvas/webgl/angle-instanced-arrays-out-of-bounds.html:
+        Removed an unneeded js-test-style.css include.
+
+        * fast/canvas/webgl/framebuffer-bindings-unaffected-on-resize.html:
+        Swapped lines to not have glErrorShouldBe after finishTest.
+
+        * fast/canvas/webgl/resources/webgl-test.js:
+        (initNonKhronosFramework): webgl-test.js relies on js-test anyway, so there is
+        no need to duplicate the work.
+        (nonKhronosFrameworkNotifyDone): Use the proper js-test mechanism.
+        (finishTest): Ditto.
+        (finishTest.epilogue.document.createElement.epilogue.onload): Deleted.
+
+        * resources/js-test.js:
+        (expectTrue): Added this function that we only has in js-test-pre.js.
+        (): Perform work after test's load event handler, not immediately on DOMContentLoaded.
+        This has two benefits:
+        1. Tests that enable jsTestIsAsync in onload do work. This is expected, because
+        tests that call waitUntilDone from onload also do work.
+        2. Non-async tests that perform work in onload have the correct order of lines in output.
+
+        * fast/dom/HTMLImageElement/sizes/image-sizes-1x-expected.txt:
+        * fast/dom/HTMLImageElement/sizes/image-sizes-2x-expected.txt:
+        * fast/dom/HTMLImageElement/sizes/image-sizes-js-innerhtml-expected.txt:
+        * fast/hidpi/image-srcset-invalid-descriptor-expected.txt:
+        * fast/hidpi/image-srcset-src-selection-1x-both-expected.txt:
+        * svg/custom/html_document_set_title-expected.txt:
+        Updated results for js-test.js improvements.
+
+        * fast/canvas/webgl/WebGLContextEvent.html:
+        * fast/canvas/webgl/angle-instanced-arrays.html:
+        * fast/canvas/webgl/array-bounds-clamping.html:
+        * fast/canvas/webgl/array-buffer-crash.html:
+        * fast/canvas/webgl/array-buffer-view-crash-when-reassigned.html:
+        * fast/canvas/webgl/array-buffer-view-crash.html:
+        * fast/canvas/webgl/array-constructor.html:
+        * fast/canvas/webgl/array-get-and-set-method-removal.html:
+        * fast/canvas/webgl/array-get-out-of-bounds.html:
+        * fast/canvas/webgl/array-message-passing.html:
+        * fast/canvas/webgl/array-override-set.html:
+        * fast/canvas/webgl/array-set-invalid-arguments.html:
+        * fast/canvas/webgl/array-set-out-of-bounds.html:
+        * fast/canvas/webgl/array-set-with-offset.html:
+        * fast/canvas/webgl/array-setters.html:
+        * fast/canvas/webgl/array-unit-tests.html:
+        * fast/canvas/webgl/arraybuffer-transfer-of-control.html:
+        * fast/canvas/webgl/attrib-location-length-limits.html:
+        * fast/canvas/webgl/bad-arguments-test.html:
+        * fast/canvas/webgl/buffer-bind-test.html:
+        * fast/canvas/webgl/buffer-data-array-buffer.html:
+        * fast/canvas/webgl/canvas-2d-webgl-texture-expected.txt:
+        * fast/canvas/webgl/canvas-2d-webgl-texture.html:
+        * fast/canvas/webgl/canvas-resize-crash.html:
+        * fast/canvas/webgl/canvas-supports-context.html:
+        * fast/canvas/webgl/canvas-test.html:
+        * fast/canvas/webgl/canvas-zero-size.html:
+        * fast/canvas/webgl/compressed-tex-image.html:
+        * fast/canvas/webgl/constants.html:
+        * fast/canvas/webgl/context-attributes-alpha-depth-stencil-antialias.html:
+        * fast/canvas/webgl/context-creation-and-destruction.html:
+        * fast/canvas/webgl/context-lost-restored.html:
+        * fast/canvas/webgl/context-lost.html:
+        * fast/canvas/webgl/context-release-upon-reload.html:
+        * fast/canvas/webgl/copy-tex-image-and-sub-image-2d.html:
+        * fast/canvas/webgl/data-view-crash.html:
+        * fast/canvas/webgl/data-view-test.html:
+        * fast/canvas/webgl/draw-arrays-out-of-bounds.html:
+        * fast/canvas/webgl/draw-elements-out-of-bounds.html:
+        * fast/canvas/webgl/drawingbuffer-test.html:
+        * fast/canvas/webgl/error-reporting.html:
+        * fast/canvas/webgl/framebuffer-object-attachment.html:
+        * fast/canvas/webgl/framebuffer-test.html:
+        * fast/canvas/webgl/functions-returning-strings.html:
+        * fast/canvas/webgl/get-active-test.html:
+        * fast/canvas/webgl/gl-bind-attrib-location-before-compile-test.html:
+        * fast/canvas/webgl/gl-bind-attrib-location-test.html:
+        * fast/canvas/webgl/gl-bind-attrib-mapped-names.html:
+        * fast/canvas/webgl/gl-enable-enum-test.html:
+        * fast/canvas/webgl/gl-enum-tests.html:
+        * fast/canvas/webgl/gl-get-calls.html:
+        * fast/canvas/webgl/gl-getshadersource.html:
+        * fast/canvas/webgl/gl-getstring.html:
+        * fast/canvas/webgl/gl-object-get-calls.html:
+        * fast/canvas/webgl/gl-pixelstorei.html:
+        * fast/canvas/webgl/gl-teximage.html:
+        * fast/canvas/webgl/gl-uniform-arrays.html:
+        * fast/canvas/webgl/gl-uniformmatrix4fv.html:
+        * fast/canvas/webgl/gl-vertex-attrib-zero-issues.html:
+        * fast/canvas/webgl/gl-vertex-attrib.html:
+        * fast/canvas/webgl/gl-vertexattribpointer.html:
+        * fast/canvas/webgl/glsl-conformance.html:
+        * fast/canvas/webgl/incorrect-context-object-behaviour.html:
+        * fast/canvas/webgl/index-validation-copies-indices.html:
+        * fast/canvas/webgl/index-validation-crash-with-buffer-sub-data.html:
+        * fast/canvas/webgl/index-validation-verifies-too-many-indices.html:
+        * fast/canvas/webgl/index-validation-with-resized-buffer.html:
+        * fast/canvas/webgl/index-validation.html:
+        * fast/canvas/webgl/instanceof-test.html:
+        * fast/canvas/webgl/invalid-UTF-16.html:
+        * fast/canvas/webgl/invalid-passed-params.html:
+        * fast/canvas/webgl/is-object.html:
+        * fast/canvas/webgl/null-object-behaviour.html:
+        * fast/canvas/webgl/null-uniform-location.html:
+        * fast/canvas/webgl/object-deletion-behaviour.html:
+        * fast/canvas/webgl/oes-element-index-uint.html:
+        * fast/canvas/webgl/oes-texture-float-linear-expected.txt:
+        * fast/canvas/webgl/oes-texture-float-linear.html:
+        * fast/canvas/webgl/oes-texture-half-float-linear-expected.txt:
+        * fast/canvas/webgl/oes-texture-half-float-linear.html:
+        * fast/canvas/webgl/oes-texture-half-float-with-canvas.html:
+        * fast/canvas/webgl/oes-texture-half-float-with-image.html:
+        * fast/canvas/webgl/oes-texture-half-float-with-video.html:
+        * fast/canvas/webgl/oes-texture-half-float.html:
+        * fast/canvas/webgl/oes-vertex-array-object.html:
+        * fast/canvas/webgl/point-size.html:
+        * fast/canvas/webgl/premultiplyalpha-test-expected.txt:
+        * fast/canvas/webgl/premultiplyalpha-test.html:
+        * fast/canvas/webgl/program-test.html:
+        * fast/canvas/webgl/read-pixels-pack-alignment.html:
+        * fast/canvas/webgl/read-pixels-test.html:
+        * fast/canvas/webgl/renderbuffer-initialization.html:
+        * fast/canvas/webgl/renderer-and-vendor-strings.html:
+        * fast/canvas/webgl/resources/tex-image-and-sub-image-2d-with-video.js:
+        * fast/canvas/webgl/script-tests/arraybuffer-transfer-of-control.js:
+        * fast/canvas/webgl/shader-deleted-by-accessor.html:
+        * fast/canvas/webgl/shader-precision-format.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-array-buffer-view.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgb565.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgba4444.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas-rgba5551.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-canvas.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgb565.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgba4444.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data-rgba5551.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-data.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgb565.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba4444.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-image-rgba5551.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-image.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-potentially-subsampled-image.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-svg-image.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgb565.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgba4444.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-video-rgba5551.html:
+        * fast/canvas/webgl/tex-image-and-sub-image-2d-with-video.html:
+        * fast/canvas/webgl/tex-image-and-uniform-binding-bugs.html:
+        * fast/canvas/webgl/tex-image-webgl.html:
+        * fast/canvas/webgl/tex-image-with-format-and-type.html:
+        * fast/canvas/webgl/tex-image-with-greyscale-image.html:
+        * fast/canvas/webgl/tex-input-validation.html:
+        * fast/canvas/webgl/tex-sub-image-2d-bad-args.html:
+        * fast/canvas/webgl/tex-sub-image-2d.html:
+        * fast/canvas/webgl/tex-sub-image-cube-maps.html:
+        * fast/canvas/webgl/texImageTest.html:
+        * fast/canvas/webgl/texture-active-bind.html:
+        * fast/canvas/webgl/texture-bindings-uneffected-on-resize-expected.txt:
+        * fast/canvas/webgl/texture-bindings-uneffected-on-resize.html:
+        * fast/canvas/webgl/texture-color-profile.html:
+        * fast/canvas/webgl/texture-complete.html:
+        * fast/canvas/webgl/texture-npot.html:
+        * fast/canvas/webgl/texture-transparent-pixels-initialized.html:
+        * fast/canvas/webgl/triangle.html:
+        * fast/canvas/webgl/type-conversion-test.html:
+        * fast/canvas/webgl/typed-arrays-in-workers.html:
+        * fast/canvas/webgl/uniform-array-length-overflow.html:
+        * fast/canvas/webgl/uniform-location-length-limits.html:
+        * fast/canvas/webgl/uniform-location.html:
+        * fast/canvas/webgl/uniform-samplers-test.html:
+        * fast/canvas/webgl/uninitialized-test.html:
+        * fast/canvas/webgl/viewport-unchanged-upon-resize.html:
+        * fast/canvas/webgl/webgl-array-invalid-ranges.html:
+        * fast/canvas/webgl/webgl-compressed-texture-size-limit.html:
+        * fast/canvas/webgl/webgl-depth-texture-expected.txt:
+        * fast/canvas/webgl/webgl-depth-texture.html:
+        * fast/canvas/webgl/webgl-draw-buffers.html:
+        * fast/canvas/webgl/webgl-exceptions.html:
+        * fast/canvas/webgl/webgl-specific.html:
+        * fast/canvas/webgl/webgl-texture-binding-preserved-expected.txt:
+        * fast/canvas/webgl/webgl-texture-binding-preserved.html:
+        * fast/canvas/webgl/webgl-unprefixed-context-id.html:
+        * fast/canvas/webgl/webgl-viewport-parameters-preserved-expected.txt:
+        * fast/canvas/webgl/webgl-viewport-parameters-preserved.html:
+
 2014-12-27  Csaba Osztrogon√°c  <ossy@webkit.org>
 
         [Win] Unreviewed gardening, mark more timeouting tests.
index e5f97ae..ede61ea 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script>
@@ -67,13 +67,7 @@ function runTest2()
 }
 
 function finish() {
-    var epilogue = document.createElement("script");
-    epilogue.onload = function() {
-        if (window.nonKhronosFrameworkNotifyDone)
-            window.nonKhronosFrameworkNotifyDone();
-    };
-    epilogue.src = "../../../resources/js-test-post.js";
-    document.body.appendChild(epilogue);
+    finishTest();
 }
 
 </script>
index 1e052df..e6ce0ca 100644 (file)
@@ -29,9 +29,8 @@
 <html>
 <head>
 <meta charset="utf-8">
-<link rel="stylesheet" href="../../../resources/js-test-style.css"/>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/out-of-bounds-test.js"></script>
@@ -71,10 +70,6 @@ if (!ext) {
     OutOfBoundsTest.runDrawElementsInstancedTest("ext.drawElementsInstancedANGLE(gl.TRIANGLES, $(count), $(type), $(offset), $(primcount))", gl, wtu, ext);
     debug("");
 }
-
-var successfullyParsed = true;
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 24aa5f2..45f17da 100644 (file)
@@ -29,7 +29,7 @@
 <meta charset="utf-8">
 <title>WebGL ANGLE_instanced_arrays Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -288,10 +288,6 @@ function runUniqueObjectTest()
 }
 
 debug("");
-var successfullyParsed = true;
-
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 8bae2d0..d1d3621 100644 (file)
@@ -3,7 +3,7 @@
 <html>
 <head>
 <title>WebGL array bounds clamping conformance test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 </head>
 <body>
@@ -100,7 +100,6 @@ function init()
 
 init();
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 4ca67c4..a185581 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -17,10 +17,5 @@ new ArrayBuffer().byteLength;
 testPassed("new ArrayBuffer().byteLength did not crash");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index c0805a7..e77a8b5 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -23,10 +23,5 @@ new Int16Array(function() {});
 testPassed("reassigning typed array constructor did not crash");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index 3e91681..cc67a18 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -17,10 +17,5 @@ new Uint32Array().length;
 testPassed("new Uint32Array().length did not crash");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index ac2450a..3ef63ad 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -29,8 +29,5 @@ for (idx = 0; idx < target.length; idx++) {
 }
 
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
-
index 1528a34..5a75942 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -46,7 +46,5 @@ negativeTestGetAndSetMethods("Uint32Array");
 negativeTestGetAndSetMethods("Float32Array");
 
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 75e507f..ca7eec8 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -33,7 +33,5 @@ testGetWithOutOfRangeIndices("Uint32Array");
 testGetWithOutOfRangeIndices("Float32Array");
 
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 6f931c2..ebaa5bb 100644 (file)
@@ -1,13 +1,12 @@
-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<!DOCTYPE html>
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="webgl-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script src="script-tests/array-message-passing.js"></script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index e356212..a5353d0 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -41,7 +41,5 @@ for (var i = 0; i < typeNames.length; i++) {
 }
 
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 4a22384..0fc4673 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -34,8 +34,6 @@ negativeTestSet("Uint32Array");
 negativeTestSet("Float32Array");
 
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 0c5dbb5..bd0f9b2 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -33,7 +33,5 @@ negativeTestSet("Uint32Array");
 negativeTestSet("Float32Array");
 
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index cdd1998..966758c 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -39,7 +39,5 @@ testSetters("Int32Array", -2147483648, 2147483647);
 testSetters("Uint32Array", 0, 4294967295);
 testSetters("Float32Array", -2.5, 3.5);
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index e66f203..b3e6ae6 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -65,7 +65,5 @@ testSetters("Int32Array", -2147483648, 2147483647);
 testSetters("Uint32Array", 0, 4294967295);
 testSetters("Float32Array", -2.5, 3.5);
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 23c5771..f884676 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/typed-array-test-cases.js"></script>
 </head>
@@ -1025,10 +1025,6 @@ function runTests() {
 }
 
 runTests();
-var successfullyParsed = true;
-
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 92354b4..759fce2 100644 (file)
@@ -1,14 +1,13 @@
-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<!DOCTYPE html>
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="webgl-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script src="script-tests/arraybuffer-transfer-of-control.js"></script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 6066b65..7c7cc94 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL attrib location length tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -94,6 +94,5 @@ shouldBe('gl.getAttribLocation(program, "vPosition012345678901234567890123456789
 wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 7a56fef..6c1bbfb 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -85,7 +85,5 @@ for (var i = 0; i < arguments.length; ++i) {
   func3("context.getShaderSource(argument)");
 }
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 63fdcf8..5b5b84b 100644 (file)
@@ -1,9 +1,8 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
   <head>
     <title>WebGL BindBuffer conformance test.</title>
-    <script src="../../../resources/js-test-pre.js"></script>
+    <script src="../../../resources/js-test.js"></script>
     <script src="resources/webgl-test.js"> </script>
 </head>
 <body>
@@ -53,11 +52,5 @@ if (!gl) {
 debug("");
 </script>
 </body>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
-</body>
 </html>
 
index 7caebcf..cb0f816 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -54,7 +54,5 @@ glErrorShouldBe(gl, gl.NO_ERROR);
 gl.bufferSubData(gl.ARRAY_BUFFER, 10, null);
 glErrorShouldBe(gl, gl.NO_ERROR);
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 3e5cabe..8b49a20 100644 (file)
@@ -3,9 +3,9 @@ Checks that copying canvas results to a WebGL texture functions without error.
 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
 
 
+PASS Should have rendered red.
+PASS Should have rendered blue.
 PASS successfullyParsed is true
 
 TEST COMPLETE
-PASS Should have rendered red.
-PASS Should have rendered blue.
  
index 8d1b478..8caaf66 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -9,11 +9,6 @@ description("Checks that copying canvas results to a WebGL texture functions wit
 
 var wtu = WebGLTestUtils;
 
-if (window.testRunner) {
-    testRunner.dumpAsText();
-    testRunner.waitUntilDone();
-}
-
 var canvas;
 var gl;
 var ctx;
@@ -36,14 +31,13 @@ function draw()
   wtu.drawQuad(gl);
   wtu.checkCanvasRect(gl, 0, 0, 1, 1, [0, 0, 200, 255], "Should have rendered blue.", 1);
 
-  if (window.testRunner)
-      testRunner.notifyDone();
+  finishTest();
 }
 
 window.onload = function()
 {
   if (window.initNonKhronosFramework)
-    window.initNonKhronosFramework(false);
+    window.initNonKhronosFramework(true);
 
   canvas = document.getElementById("webgl-canvas");
   gl = create3DContext(canvas);
@@ -69,7 +63,6 @@ window.onload = function()
   setTimeout(draw, 0);
 }
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 <body>
 <div id="description"></div>
 <div id="console"></div>
index c92dc80..42a6fdb 100644 (file)
@@ -6,7 +6,7 @@
   height: 100%;
 }
 </style>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test-utils.js"> </script>
 <script>
 description('Tests that canvas does not crash on resize.');
@@ -37,7 +37,6 @@ testPassed("Canvas did not crash on resize.");
 </script>
 
 <canvas id="example"></canvas>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 45dbd05..b29f47f 100644 (file)
@@ -1,7 +1,7 @@
 <html>
 <head>
 <title>WebGL Canvas probablySupportsContext Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
@@ -165,6 +165,5 @@ function run_tests()
 
 run_tests();
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
\ No newline at end of file
index 0d904d5..fbcedc7 100644 (file)
@@ -1,11 +1,10 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL Canvas Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -188,8 +187,5 @@ function finish() {
 }
 
 </script>
-<script>
-</script>
-
 </body>
 </html>
index 4b5a088..dcb8f3f 100644 (file)
@@ -3,7 +3,7 @@
   <head>
   <meta charset="utf-8">
     <title>Zero Size Canvas Test</title>
-    <script src="../../../resources/js-test-pre.js"></script>
+    <script src="../../../resources/js-test.js"></script>
     <script src="resources/webgl-test.js"> </script>
     <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -29,7 +29,5 @@ wtu.drawQuad(gl);
 
 glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 720825a..a15a284 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL CompressedTexImage and CompressedTexSubImage Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -45,7 +45,6 @@ if (!gl) {
   shouldGenerateGLError(gl, gl.INVALID_ENUM, "gl.compressedTexImage2D(gl.TEXTURE_2D, 0, COMPRESSED_RGBA_PVRTC_4BPPV1_IMG, 8, 8, 0, new Uint8Array(8))");
 }
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index be406ba..9ba6cf2 100644 (file)
@@ -8,7 +8,7 @@ found in the LICENSE file.
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL Constants Test</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -517,7 +517,5 @@ for (var i in gl) {
 
 debug("");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 08ade4d..26c06d0 100644 (file)
@@ -3,7 +3,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script id="vshader" type="x-shader/x-vertex">
 attribute vec3 pos;
index d1f9e53..311e5c4 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
index 8771e37..906ea43 100644 (file)
@@ -1,7 +1,7 @@
 <!DOCTYPE html>
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script>
index 5d17364..08f57e6 100644 (file)
@@ -1,7 +1,7 @@
 <!DOCTYPE html>
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script>
index 851feb7..71b1e06 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL Context Release Test</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
 <script>
 description("This test ensures that WebGL contexts are released properly upon page reload");
 
-if (window.testRunner) {
-    testRunner.dumpAsText();
-    testRunner.waitUntilDone();
-}
+window.jsTestIsAsync = true;
 
 var host = document.getElementById("host");
 var testIterations = 8;
index 40b9cb5..c04bfbc 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script id="vshader" type="x-shader/x-vertex">
 attribute vec3 g_Position;
index f14c1dd..c7510d1 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
@@ -15,7 +15,5 @@ shouldThrow("view = new DataView(array.buffer, -4500000000)");
 shouldThrow("view = new DataView(array.buffer, -4500000000, 4500000000)");
 var value = view ? view.getFloat32(0, true) : 0;
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 70abcae..091cb8d 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
@@ -357,7 +357,5 @@ runGetTests();
 runSetTests();
 runIndexingTests();
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 16f5b1a..9dd8440 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -102,7 +102,5 @@ shouldGenerateGLError(context, context.INVALID_OPERATION, "context.drawArrays(co
 
 debug("")
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index a11c7c0..a7b3218 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -133,7 +133,5 @@ shouldGenerateGLError(context, context.INVALID_OPERATION, "context.drawElements(
 
 debug("")
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index c14595b..56c96fa 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL Canvas Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -215,6 +215,5 @@ test(maxSize[0] + 32, 8);
 
 debug("")
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index c3250ba..3f6bcc1 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -63,7 +63,5 @@ glErrorShouldBe(context, context.INVALID_OPERATION);
 // Error state should be clear by this point
 glErrorShouldBe(context, context.NO_ERROR);
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 8451c9f..9c2e5c4 100644 (file)
@@ -4,7 +4,7 @@
 <head>
 <meta charset="utf-8">
 <title>Verifies that GL framebuffer bindings do not change when canvas is resized</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -71,11 +71,9 @@ debug("test after resizing canvas and waiting for compositing");
 canvas.width = 16;
 wtu.waitFrames(5, function() {
   test();
-  finishTest();
   glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors.");
+  finishTest();
 });
-
-successfullyParsed = true;
 </script>
 </body>
 </html>
index 9a90152..b52da15 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -525,10 +525,6 @@ function testFramebufferIncompleteDimensions() {
 
     glErrorShouldBe(gl, gl.NO_ERROR);
 }
-
-successfullyParsed = true;
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 9f57a6c..7b3f7be 100644 (file)
@@ -1,10 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL Framebuffer Test</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -163,9 +162,5 @@ if (!gl) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-<script>
-</script>
-
 </body>
 </html>
index 809c53c..db18e5b 100644 (file)
@@ -4,7 +4,7 @@
 <meta charset="utf-8">
 <title>WebGL Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -86,10 +86,6 @@ if (!gl) {
 }
 
 debug("");
-successfullyParsed = true;
-
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index e904df4..172d064 100644 (file)
@@ -1,7 +1,6 @@
-
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -104,7 +103,5 @@ glErrorShouldBe(context, context.INVALID_VALUE);
 shouldBeNull("context.getActiveAttrib(program, 0)");
 glErrorShouldBe(context, context.INVALID_VALUE);
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index b847a2b..283504a 100644 (file)
@@ -1,10 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL BindAttribLocation (Before Compile) Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -191,7 +190,5 @@ glErrorShouldBe(gl, gl.NO_ERROR);
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 6cf9959..1de24dc 100644 (file)
@@ -1,10 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL BindAttribLocation Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -193,7 +192,5 @@ glErrorShouldBe(gl, gl.NO_ERROR);
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index b6e4cfa..7f8dc2c 100644 (file)
@@ -1,10 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL BindAttribLocation Mapped Names Conformance Test</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -187,7 +186,5 @@ glErrorShouldBe(gl, gl.NO_ERROR);
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 7b5b383..28de013 100644 (file)
@@ -1,11 +1,10 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL gl.ENABLE enums Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -124,10 +123,5 @@ if (!gl) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index b484f2c..aa2c5fb 100644 (file)
@@ -1,11 +1,10 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL gl enums Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -78,11 +77,6 @@ if (!gl) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
 
index b7c765b..fab9137 100644 (file)
@@ -1,9 +1,8 @@
-
 <html xmlns="http://www.w3.org/1999/xhtml">
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL gl calls Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -113,10 +112,5 @@ else {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index 3b102c1..3b3d5bb 100644 (file)
@@ -1,10 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta content='text/html; charset=UTF-8' http-equiv='Content-Type'/>
    <title>WebGL getShaderSource conformance test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -26,13 +25,6 @@ shouldBe("source", "original");
 glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors.");
 </script>
 </body>
-</body>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
-</body>
 </html>
 
 
index 8164cc0..32c4f59 100644 (file)
@@ -1,11 +1,10 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL gl.getParameter Strings Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -46,10 +45,5 @@ function checkPrefix(expected, enum_val) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index 1279567..df9437e 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -246,7 +246,5 @@ gl.deleteBuffer(buffer);
 shouldBeNull('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING)');
 glErrorShouldBe(gl, gl.NO_ERROR);
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 98b51ab..67fd61f 100644 (file)
@@ -1,9 +1,8 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <title>WebGL pixelStorei Test</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
 </head>
@@ -113,10 +112,4 @@ function init() {
 init();
 </script>
 </body>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
-</body>
 </html>
index 45ec324..3ab506c 100644 (file)
@@ -1,9 +1,8 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <title>WebGL texImage2D conformance test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -398,7 +397,6 @@ function runTests(imgs) {
   checkPixelRange(buf, middle, center, [ 255, 0, 0, 255 ], 10);
 
   debug("");
-  isSuccessfullyParsed();
 }
 
 </script>
index f89cee7..43edc68 100644 (file)
@@ -1,10 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL uniform array Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -295,10 +294,5 @@ for (var tt = 0; tt < typeInfos.length; ++tt) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index f671d1b..91ef60b 100644 (file)
@@ -1,10 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL uniformMatrix Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -70,7 +69,5 @@ for (var ii = 2; ii <= 4; ++ii) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index f5524bf..7914308 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <title>WebGL Enable Vertex Attrib Zero Test</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -79,11 +79,6 @@ for (var ii = 0; ii < 5; ++ii) {
 
 wtu.checkCanvas(gl, [0, 0, 0, 0], "canvas should be 0, 0, 0, 0");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
 
index 10728f9..821e9d6 100644 (file)
@@ -1,10 +1,9 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL vertexAttrib Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -42,7 +41,5 @@ if (!gl) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 692a6d8..c97fb70 100644 (file)
@@ -1,11 +1,10 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL vertexAttribPointer Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -127,10 +126,5 @@ if (!gl) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index dc1b4a5..7d54e2b 100644 (file)
@@ -4,7 +4,7 @@
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL GLSL Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -539,10 +539,5 @@ if (!gl) {
 debug("");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
 </body>
 </html>
index 8c8cb63..f6ccf9e 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -51,7 +51,5 @@ shouldGenerateGLError(contextA, contextA.INVALID_OPERATION, "contextA.getShaderS
 shouldGenerateGLError(contextA, contextA.INVALID_OPERATION, "contextA.getUniform(programB, locationA)");
 shouldGenerateGLError(contextA, contextA.INVALID_OPERATION, "contextA.getUniformLocation(programB, 'u_modelViewProjMatrix')");
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 57cc5ba..9fbf79b 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -40,7 +40,5 @@ shouldGenerateGLError(context, context.INVALID_OPERATION, "context.drawElements(
 
 debug("")
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index f8d8bd8..fa92d4c 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -19,7 +19,5 @@ var data = new Uint8Array(127);
 gl.bufferSubData(gl.ELEMENT_ARRAY_BUFFER, 63, data);
 testPassed("bufferSubData, when buffer object was initialized with null, did not crash");
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 339022d..7ef05da 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -35,7 +35,5 @@ shouldGenerateGLError(context, context.INVALID_OPERATION, "context.drawElements(
 
 debug("")
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index ca1e9aa..7733500 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -91,7 +91,5 @@ glErrorShouldBe(gl, gl.NO_ERROR, "after drawing");
 
 debug("")
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 10b9768..8f8ad12 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -105,10 +105,6 @@ debug("Pass large negative index to vertexAttribPointer");
 gl.vertexAttribPointer(normalLoc, 3, gl.FLOAT, false, 7 * sizeInBytes(gl.FLOAT), -2000000000 * sizeInBytes(gl.FLOAT));
 glErrorShouldBe(gl, gl.INVALID_VALUE);
 shouldBeUndefined('gl.drawElements(gl.TRIANGLES, 3, gl.UNSIGNED_SHORT, 0)');
-
-successfullyParsed = true;
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 16d7a37..3f45321 100644 (file)
@@ -4,7 +4,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL instanceof test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -77,11 +77,7 @@ shouldThrowWithNew(window.WebGLShader, 'WebGLShader');
 shouldThrowWithNew(window.WebGLTexture, 'WebGLTexture');
 shouldThrowWithNew(window.WebGLUniformLocation, 'WebGLUniformLocation');
 shouldThrowWithNew(window.WebGLShaderPrecisionFormat, 'WebGLShaderPrecisionFormat');
-
-successfullyParsed = true;
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
 
index 14cc86a..ea7c69f 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -33,6 +33,5 @@ var program = gl.createProgram();
 gl.bindAttribLocation(program, 0, string);
 testPassed("bindAttribLocation with invalid UTF-16 did not crash");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 5259163..dad5d93 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/desktop-gl-constants.js"></script>
 </head>
@@ -159,7 +159,5 @@ for (var i = 0; i < invalidSet.length; ++i) {
 
 debug("")
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 3a36e5b..35c4f87 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -64,6 +64,5 @@ shouldGenerateGLError(gl, gl.NO_ERROR, "gl.deleteShader(shader)");
 shouldBeFalse("gl.isShader(shader)");
 debug("");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 253980b..6bab617 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -74,7 +74,5 @@ shouldGenerateGLError(context, context.INVALID_OPERATION, "context.texImage2D(co
 shouldGenerateGLError(context, context.INVALID_OPERATION, "context.texParameteri(context.TEXTURE_2D, context.TEXTURE_MIN_FILTER, context.NEAREST)");
 shouldGenerateGLError(context, context.INVALID_OPERATION, "context.getTexParameter(context.TEXTURE_2D, context.TEXTURE_MIN_FILTER)");
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index ae2d61e..9199c75 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -60,7 +60,5 @@ for (var i = 0; i < funcs.length; i++) {
   shouldBe("gl.getError()", "gl.NO_ERROR");
 }
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 6a4d1fe..bb3a336 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -413,10 +413,6 @@ if (gl.checkFramebufferStatus(gl.FRAMEBUFFER) == gl.FRAMEBUFFER_COMPLETE) {
   // check again because many buggy implementations will have bound to the true backbuffer on deleteFramebuffer.
   shouldGenerateGLError(gl, gl.NO_ERROR, 'wtu.checkCanvasRect(gl, 0, 0, 300, 150, [0,255,0,255], "fbo should be green")');
 }
-
-successfullyParsed = true;
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 9b99366..1b282bf 100644 (file)
@@ -4,7 +4,7 @@
 <meta charset="utf-8">
 <title>WebGL OES_element_index_uint Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -413,9 +413,6 @@ function runCrashWithBufferSubDataTests() {
 }
 
 debug("");
-successfullyParsed = true;
-isSuccessfullyParsed();
-
 </script>
 </body>
 </html>
index ab779fe..7dabb71 100644 (file)
@@ -217,4 +217,7 @@ PASS should be 255,255,255,255
 testing target: TEXTURE_CUBE_MAP, testing format: RGBA, magFilter is: LINEAR, minFilter is: LINEAR_MIPMAP_LINEAR, OES_texture_float_linear is enabled
 PASS getError was expected value: NO_ERROR : OES_texture_float texture with Linear filter should succeed with NO_ERROR if OES_texture_float is enabled
 PASS should be 255,255,255,255
+PASS successfullyParsed is true
+
+TEST COMPLETE
 
index 48ff8ff..bc6fe36 100644 (file)
@@ -29,7 +29,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/oes-texture-float-and-half-float-linear.js"></script>
index 0ad1031..7ff4173 100644 (file)
@@ -217,4 +217,7 @@ PASS should be 255,255,255,255
 testing target: TEXTURE_CUBE_MAP, testing format: RGBA, magFilter is: LINEAR, minFilter is: LINEAR_MIPMAP_LINEAR, OES_texture_half_float_linear is enabled
 PASS getError was expected value: NO_ERROR : OES_texture_half_float texture with Linear filter should succeed with NO_ERROR if OES_texture_half_float is enabled
 PASS should be 255,255,255,255
+PASS successfullyParsed is true
+
+TEST COMPLETE
 
index 3da0adb..5bfb346 100644 (file)
@@ -29,7 +29,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/oes-texture-float-and-half-float-linear.js"></script>
index f294ae4..ec1ac3b 100644 (file)
@@ -30,7 +30,7 @@
 <head>
 <meta charset="utf-8">
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-canvas.js"></script>
index 74aae70..99535fc 100644 (file)
@@ -30,7 +30,7 @@
 <head>
 <meta charset="utf-8">
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image.js"></script>
index aa361f3..78adb38 100644 (file)
 <head>
 <meta charset="utf-8">
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-video.js"></script>
 <script>
 "use strict";
+
+// As a workaround for https://bugs.webkit.org/show_bug.cgi?id=87448, this code needs to
+// be run from an inline script in a main resource.
+window.jsTestIsAsync = true;
+if (window.testRunner)
+    testRunner.waitUntilDone();
+
 function testPrologue(gl) {
     var ext = null;
 
index fd3e558..c4e51fe 100644 (file)
@@ -31,7 +31,7 @@
 <meta charset="utf-8">
 <title>WebGL OES_texture_half_float Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -268,9 +268,6 @@ function runUniqueObjectTest()
 }
 
 debug("");
-var successfullyParsed = true;
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 00a98e5..c853334 100644 (file)
@@ -4,7 +4,7 @@
 <meta charset="utf-8">
 <title>WebGL OES_vertex_array_object Conformance Tests</title>
 <script src="resources/desktop-gl-constants.js" type="text/javascript"></script>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -592,8 +592,6 @@ function runArrayBufferBindTests() {
 }
 
 debug("");
-successfullyParsed = true;
-isSuccessfullyParsed();
 </script>
 </body>
 </html>
index 022d484..2ee25b3 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script id="vshader" type="x-shader/x-vertex">
 attribute vec3 pos;
@@ -118,8 +118,5 @@ description('Verify GL_VERTEX_PROGRAM_POINT_SIZE is enabled in WebGL');
 if (runTest())
     testPassed("");
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 111654d..47876e9 100644 (file)
@@ -56,4 +56,7 @@ PASS getError was expected value: NO_ERROR : Should be no errors from drawing.
 PASS getError was expected value: NO_ERROR : Should be no errors from creating copy.
 PASS getError was expected value: NO_ERROR : Should be no errors from 2nd drawing.
 PASS should draw with 128,128,128,255
+PASS successfullyParsed is true
+
+TEST COMPLETE
 
index 13edd16..6383384 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>Test the WebGL premultipledAlpha context creation flag.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -72,10 +72,9 @@ var gl;
 var canvas;
 var premultipledAlpha;
 
-if (window.testRunner) {
-      testRunner.waitUntilDone();
-      testRunner.overridePreference("WebKitWebGLEnabled", "1");
-}
+jsTestIsAsync = true;
+if (window.testRunner)
+    testRunner.overridePreference("WebKitWebGLEnabled", "1");
 
 description("Test the WebGL premultipledAlpha context creation flag.");
 doNextTest();
@@ -153,11 +152,8 @@ function doNextTest() {
         // Load canvas into the texture asynchronously (to prevent unbounded stack consumption)
         setTimeout(loadTexture, 0);
      }
-   } else {
-      if (window.testRunner)
-         testRunner.notifyDone();
-      finishTest();
-   }
+   } else
+      finishJSTest();
 }
 
 </script>
index 1399799..220f31b 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL Program Compiling/Linking Conformance Test</title>
-<script src="../../../resources/js-test-pre.js" type="text/javascript"></script>
+<script src="../../../resources/js-test.js" type="text/javascript"></script>
 <script src="resources/webgl-test.js" type="text/javascript"></script>
 </head>
 <body>
@@ -305,7 +305,5 @@ function go() {
 debug("");
 go();
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index b339835..89ae59d 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script id="vshader" type="x-shader/x-vertex">
 attribute vec3 pos;
@@ -233,6 +233,5 @@ runTestIteration(gl.RGBA, gl.UNSIGNED_BYTE, 2, 1, -1);
 runTestIteration(gl.RGBA, gl.UNSIGNED_BYTE, 4, 0, -1);
 runTestIteration(gl.RGBA, gl.UNSIGNED_BYTE, 8, -1, -1);
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 9353d8d..20c7266 100644 (file)
@@ -3,7 +3,7 @@
 <html>
 <head>
 <title>WebGL ReadPixels conformance test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
index f0a2554..14654e0 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script>
 function runTest(gl, width, height)
@@ -79,6 +79,5 @@ if (gl) {
 } else
     testFailed('canvas.getContext() failed');
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index ef99b94..8e00d3f 100644 (file)
@@ -1,5 +1,5 @@
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -23,6 +23,4 @@ var gl = create3DContext();
 shouldBe("gl.getParameter(gl.RENDERER)", '"WebKit WebGL"');
 shouldBe("gl.getParameter(gl.VENDOR)", '"WebKit"');
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
index 659f5e2..adf75cf 100644 (file)
@@ -1,10 +1,3 @@
-// This block needs to be outside the onload handler in order for this
-// test to run reliably in WebKit's test harness (at least the
-// Chromium port). https://bugs.webkit.org/show_bug.cgi?id=87448
-if (window.initNonKhronosFramework) {
-    window.initNonKhronosFramework(true);
-}
-
 function generateTest(pixelFormat, pixelType, prologue) {
     var wtu = WebGLTestUtils;
     var gl = null;
index e5bf53a..7f8a486 100644 (file)
@@ -12,30 +12,18 @@ function assertMsg(assertion, msg) {
 }
 
 function initNonKhronosFramework(waitUntilDone) {
-  if (window.testRunner) {
+  if (window.testRunner)
     testRunner.overridePreference("WebKitWebGLEnabled", "1");
-    testRunner.dumpAsText();
-    if (waitUntilDone) {
-      testRunner.waitUntilDone();
-    }
-  }
+  if (waitUntilDone)
+    window.jsTestIsAsync = true;
 }
 
 function nonKhronosFrameworkNotifyDone() {
-  if (window.testRunner) {
-    testRunner.notifyDone();
-  }
+  finishJSTest();
 }
 
 function finishTest() {
-  var epilogue = document.createElement("script")
-  epilogue.onload = function() {
-    if (window.nonKhronosFrameworkNotifyDone) {
-      window.nonKhronosFrameworkNotifyDone();
-    }
-  };
-  epilogue.src = "../../../resources/js-test-post.js";
-  document.body.appendChild(epilogue);
+  finishJSTest();
 }
 
 //
index cc9f182..2797cc9 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -36,8 +36,6 @@ for (var i = 0; i < 10; ++i) {
     context.getShaderParameter(shaders[1], 0);
 }
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 52090d3..94f2c07 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL shader precision format test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
index b64834d..2753e3f 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -178,6 +178,5 @@ textureLoc = gl.getUniformLocation(program, "tex");
 
 runTest();
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 6cf47ed..bd7f1e8 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-canvas.js"></script>
index e17d1f1..6522bdd 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-canvas.js"></script>
index 5d2effb..8a8eec3 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-canvas.js"></script>
index fb18673..37dd5a1 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-canvas.js"></script>
index ca6c6af..7689929 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image-data.js"></script>
index 53259f8..1ec6703 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image-data.js"></script>
index fbefad2..f5751f4 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image-data.js"></script>
index 7dad2b5..49cc92d 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image-data.js"></script>
index 654d3ec..1b2b124 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image.js"></script>
index 8959554..35be57a 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image.js"></script>
index 78545d3..0d5780f 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image.js"></script>
index dd64ae1..6085f38 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-image.js"></script>
index 2e0244d..f589b01 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-potentially-subsampled-image.js"></script>
index 21bc3c5..52bf5dd 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-svg-image.js"></script>
index 82e7717..cfb7b89 100644 (file)
@@ -2,11 +2,17 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-video.js"></script>
 <script>
+// As a workaround for https://bugs.webkit.org/show_bug.cgi?id=87448, this code needs to
+// be run from an inline script in a main resource.
+window.jsTestIsAsync = true;
+if (window.testRunner)
+    testRunner.waitUntilDone();
+
 function testPrologue(gl) {
     return true;
 }
index c58995c..3370e93 100644 (file)
@@ -2,11 +2,17 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-video.js"></script>
 <script>
+// As a workaround for https://bugs.webkit.org/show_bug.cgi?id=87448, this code needs to
+// be run from an inline script in a main resource.
+window.jsTestIsAsync = true;
+if (window.testRunner)
+    testRunner.waitUntilDone();
+
 function testPrologue(gl) {
     return true;
 }
index 10e3426..c710f91 100644 (file)
@@ -2,11 +2,17 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-video.js"></script>
 <script>
+// As a workaround for https://bugs.webkit.org/show_bug.cgi?id=87448, this code needs to
+// be run from an inline script in a main resource.
+window.jsTestIsAsync = true;
+if (window.testRunner)
+    testRunner.waitUntilDone();
+
 function testPrologue(gl) {
     return true;
 }
index 12d2f80..ad41fc5 100644 (file)
@@ -2,11 +2,17 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script src="resources/tex-image-and-sub-image-2d-with-video.js"></script>
 <script>
+// As a workaround for https://bugs.webkit.org/show_bug.cgi?id=87448, this code needs to
+// be run from an inline script in a main resource.
+window.jsTestIsAsync = true;
+if (window.testRunner)
+    testRunner.waitUntilDone();
+
 function testPrologue(gl) {
     return true;
 }
index 4cebae5..7dde3f8 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -26,7 +26,5 @@ shouldBeUndefined("gl.bindTexture(gl.TEXTURE_2D, texture)");
 shouldBeUndefined("gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, tmpcanvas)");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 66e4b97..98ffe2b 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL texImage2D from WebGL conformance test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -50,9 +50,7 @@ wtu.drawQuad(gl);
 wtu.checkCanvas(gl, [0, 255, 0, 255], "Canvas should be green");
 
 debug("");
-successfullyParsed = true;
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 025b488..8c59c94 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/pnglib.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
index 37b6b93..ae04cae 100644 (file)
@@ -1,14 +1,13 @@
 <!DOCTYPE html>
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script>
 var wtu = WebGLTestUtils;
 var gl = null;
 var textureLoc = null;
-var successfullyParsed = false;
 
 function init()
 {
index 4d14d0d..60d834b 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -348,7 +348,5 @@ testCases =
 for (var ii = 0; ii < testCases.length; ++ii)
     testCopyFromInternalFBO(testCases[ii]);
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 37e8a01..b49f237 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -64,6 +64,5 @@ glErrorShouldBe(gl, gl.INVALID_OPERATION, "format not same as original RGBA 4_4_
 gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGBA, gl.UNSIGNED_BYTE, c);
 glErrorShouldBe(gl, gl.INVALID_OPERATION, "type not same as original RGBA 4_4_4_4");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 3cb8d6e..318e71e 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script id="fshader" type="x-shader/x-fragment">
@@ -86,6 +86,5 @@ for (var i = 0; i < textureWidth; i++) {
 if (passed)
     testPassed("");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 82b4490..dd3b727 100644 (file)
@@ -30,7 +30,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL texture texSubImage2Ds cube map conformance test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -325,10 +325,7 @@ function mulMatrix(a, b) {
   dst[15] = a30 * b03 + a31 * b13 + a32 * b23 + a33 * b33;
   return dst;
 };
-
-successfullyParsed = true;
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 76641a1..1eb54d1 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -8,7 +8,5 @@
 <div id="console"></div>
 
 <script src="script-tests/texImageTest.js"></script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 16239c8..15a3fe2 100644 (file)
@@ -1,9 +1,8 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
   <head>
     <title>WebGL ActiveTexture BindTexture conformance test.</title>
-    <script src="../../../resources/js-test-pre.js"></script>
+    <script src="../../../resources/js-test.js"></script>
     <script src="resources/webgl-test.js"> </script>
 </head>
 <body>
@@ -148,9 +147,6 @@ function init()
 
 init();
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
 
index 2fddbca..fbace31 100644 (file)
@@ -1,7 +1,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -43,8 +43,6 @@ test();
 debug("test after resizing canvas");
 canvas.width = 8;
 test();
-
-successfullyParsed = true;
 </script>
 </body>
 </html>
index c4742db..d8aa5bc 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <title>Texture upload with color profile</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -82,7 +82,6 @@ function runTests(imgs) {
   checkPixelRange(buf, 0, 0, [163, 126, 94, 129], 20);
 
   debug("");
-  isSuccessfullyParsed();
 }
 </script>
 </body>
index a0e5061..2864d6b 100644 (file)
@@ -1,9 +1,8 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <title>WebGL "Texture Complete" texture conformance test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 </head>
 <body>
@@ -121,9 +120,6 @@ function init()
 
 init();
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
 
index 098c5b3..c5ace88 100644 (file)
@@ -1,9 +1,8 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-  "http://www.w3.org/TR/html4/loose.dtd">
+<!DOCTYPE html>
 <html>
 <head>
 <title>WebGL Non-Power of 2 texture conformance test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -219,11 +218,5 @@ function fillCubeTexture(gl, tex, width, height, color, opt_level) {
 
 </script>
 </body>
-<script src="../../../resources/js-test-post.js"></script>
-
-<script>
-</script>
-
-</body>
 </html>
 
index 943044d..da7b877 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <script>
index 4309875..25d59d3 100644 (file)
@@ -3,7 +3,7 @@
 <html>
   <head>
     <title>Rendering Test</title>
-    <script src="../../../resources/js-test-pre.js"></script>
+    <script src="../../../resources/js-test.js"></script>
     <script src="resources/webgl-test.js"> </script>
 </head>
 <body>
@@ -89,7 +89,4 @@ There is supposed to be an example drawing here, but it's not important.
        init();
     </script>
 </body>
-<script src="../../../resources/js-test-post.js"></script>
-
-</body>
 </html>
index cdf4d3a..38dc0a7 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -137,8 +137,6 @@ for (var i = 0; i < args.length; ++i) {
   func1("context.uniform4f(loc, 0, 0, 0, argument)");
 }
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 2b796f7..7bb63e0 100644 (file)
@@ -29,7 +29,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/typed-array-test-cases.js"></script>
 </head>
@@ -273,8 +273,6 @@ if (window.Worker) {
   debug("Workers not supported -- skipping test");
   finishTest();
 }
-
-var successfullyParsed = true;
 </script>
 </body>
 </html>
index a5add21..9287743 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -31,7 +31,5 @@ try {
     context.uniform4fv(floatLocation, array);
 } catch (e) { }
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index d180699..9854b3e 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL uniform location length tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"> </script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -103,6 +103,5 @@ wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
 shouldBeNull('uniformLoc');
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 86af687..1bbebe1 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -66,7 +66,5 @@ locationArray0 = contextA.getUniformLocation(programS, "u_array[0]");
 shouldGenerateGLError(contextA, contextA.NO_ERROR, "contextA.uniform1i(locationSx, 3)");
 shouldBe("contextA.getUniform(programS, locationSx)", "3");
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 121a5af..17f8f4d 100644 (file)
@@ -2,7 +2,7 @@
   <head>
 <meta charset="utf-8">
     <title>WebGL sampler uniforms conformance test.</title>
-    <script src="../../../resources/js-test-pre.js"></script>
+    <script src="../../../resources/js-test.js"></script>
     <script src="resources/webgl-test.js"> </script>
     <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -80,9 +80,7 @@ function init()
 }
 
 init();
-var successfullyParsed = true;
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index cb4f993..e394775 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <title>WebGL Uninitialized GL Resources Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -237,7 +237,6 @@ glErrorShouldBe(gl, gl.NO_ERROR);
 
 debug("");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
 
index 9a0ef78..7a93403 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script id="vshader" type="x-shader/x-vertex">
 attribute vec3 g_Position;
@@ -88,6 +88,5 @@ if (passed) {
 if (passed)
     testPassed("Viewport correctly did not change size during canvas resize");
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 33dc9cf..991ed2b 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -155,7 +155,5 @@ ints[0]=-0x7ffff;
 shouldBeTrue("isNaN(floats[0])");
 
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 9860fdc..1dd084e 100644 (file)
@@ -29,7 +29,7 @@
 
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -39,10 +39,7 @@ function init()
 "use strict";
 description("Checks size limit of the webgl compressed textures")
 
-if (window.testRunner) {
-    testRunner.dumpAsText();
-    testRunner.waitUntilDone();
-}
+window.jsTestIsAsync = true;
 
 if (window.internals)
     window.internals.settings.setWebGLErrorsToConsoleEnabled(false);
@@ -248,8 +245,6 @@ function testFormatType(t, test) {
     testPassed("No " + test.extension + " extension support -- this is legal");
 }
 }
-
-var successfullyParsed = true;
 </script>
 <body onload="init()">
 <canvas id="example" width="32" height="32" style="width: 40px; height: 40px;"></canvas>
index de12173..bcb294f 100644 (file)
@@ -77,4 +77,7 @@ PASS gl.checkFramebufferStatus(gl.FRAMEBUFFER) is not gl.FRAMEBUFFER_COMPLETE
 PASS gl.clear(gl.DEPTH_BUFFER_BIT) generated expected GL error: INVALID_FRAMEBUFFER_OPERATION.
 PASS gl.getError() is gl.NO_ERROR
 
+PASS successfullyParsed is true
+
+TEST COMPLETE
 
index b991e73..404c30e 100644 (file)
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta charset="utf-8">
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 <title>WebGL WEBGL_depth_texture Conformance Tests</title>
@@ -312,7 +312,6 @@ function runTestExtension() {
 }
 
 debug("");
-successfullyParsed = true;
 if (window.nonKhronosFrameworkNotifyDone) {
     window.nonKhronosFrameworkNotifyDone();
 }
index fd2d660..fe6b33c 100644 (file)
@@ -28,7 +28,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL WEBGL_draw_buffers Conformance Tests</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
 <body>
@@ -690,9 +690,6 @@ function runDrawTests() {
 }
 
 debug("");
-var successfullyParsed = true;
 </script>
-<script src="../../../resources/js-test-post.js"></script>
-
 </body>
 </html>
index 5a35627..2ec1b38 100644 (file)
@@ -1,7 +1,7 @@
 <!DOCTYPE html>
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -24,5 +24,4 @@ shouldThrow('gl.uniform1fv()');
 shouldThrow('gl.vertexAttrib1fv()');
 </script>
 </body>
-<script src="../../../resources/js-test-post.js"></script>
 </html>
index 0e56f43..55c91ff 100644 (file)
@@ -3,7 +3,7 @@
 <head>
 <meta charset="utf-8">
 <title>WebGL GLES2 difference test.</title>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"></script>
 </head>
@@ -97,10 +97,6 @@ debug("");
 debug("Verify that bindAttribLocation rejects names start with webgl_ or _webgl_");
 shouldGenerateGLError(gl, gl.INVALID_OPERATION, "gl.bindAttribLocation(program, 0, 'webgl_a')");
 shouldGenerateGLError(gl, gl.INVALID_OPERATION, "gl.bindAttribLocation(program, 0, '_webgl_a')");
-
-successfullyParsed = true;
 </script>
-
-<script src="../../../resources/js-test-post.js"></script>
 </body>
 </html>
index 8b621ad..c9ef03a 100644 (file)
@@ -2,8 +2,8 @@ Checks that painting WebGL contents doesn't pollute the context state.
 
 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
 
+PASS Should have rendered blue.
 PASS successfullyParsed is true
 
 TEST COMPLETE
-PASS Should have rendered blue.
 
index 8edcd8e..dcb4542 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -12,10 +12,7 @@ description("Checks that painting WebGL contents doesn't pollute the context sta
 
 var wtu = WebGLTestUtils;
 
-if (window.testRunner) {
-    testRunner.dumpAsText();
-    testRunner.waitUntilDone();
-}
+window.jsTestIsAsync = true;
 
 if (window.internals)
     window.internals.settings.setWebGLErrorsToConsoleEnabled(false);
@@ -30,16 +27,11 @@ function draw() {
   wtu.drawQuad(context);
 
   wtu.checkCanvasRect(context, 0, 0, 1, 1, [0, 0, 255, 255], "Should have rendered blue.", 1);
-  if (window.testRunner)
-    testRunner.notifyDone();
+  finishJSTest();
 }
 
 window.onload = function()
 {
-  if (window.initNonKhronosFramework) {
-    window.initNonKhronosFramework(false);
-  }
-
   canvas = document.getElementById("webgl-canvas");
   context = create3DContext(canvas);
 
@@ -64,7 +56,6 @@ window.onload = function()
   setTimeout(draw, 100);
 }
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 <canvas id="webgl-canvas" width="32px" height="32px"></canvas>
 </body>
 </html>
index 161f960..5c390b8 100644 (file)
@@ -1,7 +1,7 @@
 <!DOCTYPE html>
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 </head>
 <body>
@@ -16,5 +16,4 @@ else
   testPassed("context exists");
 </script>
 </body>
-<script src="../../../resources/js-test-post.js"></script>
 </html>
\ No newline at end of file
index 9a7ffad..aa7e5d5 100644 (file)
@@ -2,8 +2,8 @@ Checks that painting WebGL contents doesn't pollute the context's viewport state
 
 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
 
+PASS Viewport not corrupted.
 PASS successfullyParsed is true
 
 TEST COMPLETE
-PASS Viewport not corrupted.
 
index 022129d..78fe8d2 100644 (file)
@@ -1,6 +1,6 @@
 <html>
 <head>
-<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../../resources/js-test.js"></script>
 <script src="resources/webgl-test.js"></script>
 <script src="resources/webgl-test-utils.js"> </script>
 </head>
@@ -12,11 +12,6 @@ description("Checks that painting WebGL contents doesn't pollute the context's v
 
 var wtu = WebGLTestUtils;
 
-if (window.testRunner) {
-  testRunner.dumpAsText();
-  testRunner.waitUntilDone();
-}
-
 var canvas;
 var context;
 
@@ -29,14 +24,13 @@ function draw() {
     testPassed("Viewport not corrupted.");
   }
 
-  if (window.testRunner)
-    testRunner.notifyDone();
+  finishTest();
 }
 
 window.onload = function()
 {
   if (window.initNonKhronosFramework) {
-    window.initNonKhronosFramework(false);
+    window.initNonKhronosFramework(true);
   }
 
   canvas = document.getElementById("webgl-canvas");
@@ -54,7 +48,6 @@ window.onload = function()
   setTimeout(draw, 0);
 }
 </script>
-<script src="../../../resources/js-test-post.js"></script>
 <canvas id="webgl-canvas" width="32px" height="32px"></canvas>
 </body>
 </html>
index d301d45..166e3f5 100644 (file)
@@ -1,6 +1,3 @@
-PASS successfullyParsed is true
-
-TEST COMPLETE
 PASS document.getElementById("simple").currentSrc.indexOf("file://") == 0 is true
 PASS document.getElementById("simple").clientWidth is (window.innerWidth)
 PASS currentSrcFileName("simple") is "image-set-2x.png"
@@ -30,4 +27,7 @@ PASS document.getElementById("half_size").clientWidth is (window.innerWidth/2)
 PASS currentSrcFileName("half_size") is "image-set-2x.png"
 PASS document.getElementById("infitisimal_sizes").clientWidth is (window.innerWidth/100)
 PASS currentSrcFileName("infitisimal_sizes") is "image-set-2x.png"
+PASS successfullyParsed is true
+
+TEST COMPLETE
               
index daa30d0..12114bb 100644 (file)
@@ -1,6 +1,3 @@
-PASS successfullyParsed is true
-
-TEST COMPLETE
 PASS document.getElementById("simple").clientWidth is window.innerWidth
 PASS currentSrcFileName("simple") is "image-set-2x.png"
 PASS document.getElementById("small_sizes").clientWidth is 300
@@ -25,4 +22,7 @@ PASS document.getElementById("half_size").clientWidth is (window.innerWidth/2)
 PASS currentSrcFileName("half_size") is "image-set-2x.png"
 PASS document.getElementById("infitisimal_sizes").clientWidth is (window.innerWidth/100)
 PASS currentSrcFileName("infitisimal_sizes") is "image-set-2x.png"
+PASS successfullyParsed is true
+
+TEST COMPLETE
             
index c97331d..5331e2d 100644 (file)
@@ -1,5 +1,5 @@
+PASS fileName(window.testdiv.children[0].currentSrc) is "image-set-4x.png"
 PASS successfullyParsed is true
 
 TEST COMPLETE
-PASS fileName(window.testdiv.children[0].currentSrc) is "image-set-4x.png"
 
index e22e85d..86b8bf3 100644 (file)
@@ -1,12 +1,12 @@
-PASS successfullyParsed is true
-
-TEST COMPLETE
 PASS document.getElementById("invalid_with_x").clientWidth is 100
 PASS document.getElementById("invalid_without_x").clientWidth is 100
 PASS document.getElementById("future_descriptor").clientWidth is 100
 PASS document.getElementById("future_descriptor_without_x").clientWidth is 100
 PASS document.getElementById("x_with_w_ignored").clientWidth is 200
 PASS document.getElementById("x_with_h_ignored").clientWidth is 200
+PASS successfullyParsed is true
+
+TEST COMPLETE
 This test passes if the image below is a 100px blue square when the deviceScaleFactor is 1.
 It tests that even though the 1x resource contains many invalid descriptors, only the invalid descriptors are ignored (according to the spec).
          
index 4923e5c..665f689 100644 (file)
@@ -1,6 +1,6 @@
+PASS document.getElementById("foo").clientWidth==400 is true
 PASS successfullyParsed is true
 
 TEST COMPLETE
-PASS document.getElementById("foo").clientWidth==400 is true
 This test passes if the div below is a blue 100px square when the deviceScaleFactor is 1. It simply ensures that when both src and srcset are specified for the same DPR, srcset wins.
 
index bb82ed6..518a039 100644 (file)
@@ -102,7 +102,11 @@ var unexpectedErrorMessage; // set by onerror when expectingError is not true
     }
 
     if (!isWorker()) {
-        window.addEventListener('DOMContentLoaded', handleTestFinished, false);
+        window.addEventListener('DOMContentLoaded', function() {
+            // Some tests set jsTestIsAsync in load event handler. Adding the listener late
+            // makes handleTestFinished() run after the test handles load events.
+            window.addEventListener("load", handleTestFinished, false);
+        }, false);
         insertStyleSheet();
     }
 
@@ -543,6 +547,14 @@ function shouldBeGreaterThanOrEqual(_a, _b) {
         testPassed(_a + " is >= " + _b);
 }
 
+function expectTrue(v, msg) {
+  if (v) {
+    testPassed(msg);
+  } else {
+    testFailed(msg);
+  }
+}
+
 function shouldNotThrow(_a) {
     try {
         eval(_a);
index 7a777f7..4e2f06e 100644 (file)
@@ -1,5 +1,5 @@
+PASS document.title is ""
 PASS successfullyParsed is true
 
 TEST COMPLETE
-PASS document.title is ""