Update WebGL conformance test suite to 2022-01-12
https://bugs.webkit.org/show_bug.cgi?id=235563

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2022-01-27
Reviewed by Dean Jackson.

Tools:

Add functionality to Tools/Scripts/update-webgl-conformance-tests:
 - Copy http-only tests to http/tests/webgl
 - Add template to js-test-pre.js

* Scripts/webkitpy/update_webgl_conformance_tests_lib/js-test-pre-template.js: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js.
* Scripts/webkitpy/update_webgl_conformance_tests_lib/main.py:
(_copy_tree):
(main):

LayoutTests:

Update WebGL testsuite to 2022-01-12 9b58fd243d38f4b9c72ab6f75ad701cafc131137.

Additionally:
The import script can now categorize tests to regular tests and small amount of http
tests:
 - Remove old http/tests/webgl/1.0.2/
 - Add new http/tests/webgl/1.0.x / 2.0.y

* http/tests/webgl/1.0.2/origin-clean-conformance-expected.txt: Removed.
* http/tests/webgl/1.0.2/origin-clean-conformance.html: Removed.
* http/tests/webgl/1.0.2/readPixelsBadArgs-expected.txt: Removed.
* http/tests/webgl/1.0.2/readPixelsBadArgs.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/3x3.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/blue-1x1.jpg: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/bug-32888-texture.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/floatUniformShader.vert: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/fragmentShader.frag: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256-with-128-alpha.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-default-gamma.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma0.1.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma1.0.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma2.0.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma4.0.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma9.0.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/green-2x2-16bit.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/noopUniformShader.frag: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.mp4: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.theora.ogv: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.webmvp8.webm: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/pnglib.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.mp4: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.theora.ogv: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.webmvp8.webm: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-indexed.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-cie-rgb-profile.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colormatch-profile.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.jpg: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-e-srgb-profile.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-smpte-c-profile.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-srgb-iec61966-2.1-profile.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-canvas.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image-data.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-video.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/vertexShader.vert: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test-utils.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/zero-alpha.png: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/00_test_list.txt: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/compressed-tex-image.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-2d-formats.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-and-sub-image-2d.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-get-tex-parameter.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-pixelstorei.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-teximage.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/mipmap-fbo.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/origin-clean-conformance.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-array-buffer-view.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgb565.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba4444.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba5551.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgb565.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba4444.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba5551.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgb565.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba4444.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba5551.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgb565.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba4444.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba5551.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-uniform-binding-bugs.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-webgl.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-format-and-type.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-invalid-data.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-input-validation.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d-bad-args.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texparameter-test.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind-2.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-attachment-formats.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-clear.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-complete.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-formats-test.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-hd-dpi.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-mips.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot-video.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-cube-maps.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-limit.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-sub-image-cube-maps.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-transparent-pixels-initialized.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-upload-cube-maps.html: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/resources/desktop-gl-constants.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-post.js: Removed.
* http/tests/webgl/1.0.2/resources/webgl_test_files/resources/webgl-test-harness.js: Removed.
* http/tests/webgl/1.0.2/texImage2DHTML-expected.txt: Removed.
* http/tests/webgl/1.0.2/texImage2DHTML.html: Removed.
* http/tests/webgl/1.0.2/texSubImage2DHTML-expected.txt: Removed.
* http/tests/webgl/1.0.2/texSubImage2DHTML.html: Removed.
* http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt.
* http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html.
* http/tests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* http/tests/webgl/1.0.x/conformance/more/functions/texImage2DHTML.html: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML.html.
* http/tests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML-expected.txt.
* http/tests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML.html: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML.html.
* http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt.
* http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs.html: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs.html.
* http/tests/webgl/2.0.y/conformance/more/functions/texImage2DHTML-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML-expected.txt.
* http/tests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html: Copied from LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html.
* http/tests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML-expected.txt.
* http/tests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML.html: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML.html.
* http/tests/webgl/resources/js-test-pre.js: Copied from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js.
* http/tests/webgl/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html.
* http/tests/webgl/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html.
* http/tests/webgl/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html.
* http/tests/webgl/resources/webgl_test_files/conformance/more/unit.css: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.css.
* http/tests/webgl/resources/webgl_test_files/conformance/more/unit.js: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.js.
* http/tests/webgl/resources/webgl_test_files/conformance/more/util.js: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/util.js.
* http/tests/webgl/resources/webgl_test_files/js/js-test-post.js: Added.
* http/tests/webgl/resources/webgl_test_files/js/js-test-pre.js: Copied from LayoutTests/webgl/resources/webgl_test_files/js/js-test-pre.js.
* http/tests/webgl/resources/webgl_test_files/js/webgl-test-utils.js: Copied from LayoutTests/webgl/resources/webgl_test_files/js/webgl-test-utils.js.
* http/tests/webgl/resources/webgl_test_files/resources/js-test-style.css: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-style.css.
* http/tests/webgl/resources/webgl_test_files/resources/opengl_logo.jpg: Added.
* http/tests/webgl/resources/webgl_test_files/resources/thunderbird-logo-64x64.png: Added.
* http/tests/webgl/resources/webkit-webgl-test-harness.js: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webkit-webgl-test-harness.js.
* webgl/1.0.x/conformance/canvas/to-data-url-after-composite-expected.txt: Renamed from LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample-expected.txt.
* webgl/1.0.x/conformance/canvas/to-data-url-after-composite.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176.html: Added.
* webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178.html: Added.
* webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt: Added.
* webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test.html: Added.
* webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt: Added.
* webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html: Added.
* webgl/1.0.x/conformance/textures/misc/format-filterable-renderable-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-expected.txt.
* webgl/1.0.x/conformance/textures/misc/format-filterable-renderable.html: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html.
* webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html: Removed.
* webgl/1.0.x/conformance/textures/misc/png-image-types-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt.
* webgl/1.0.x/conformance/textures/misc/png-image-types.html: Renamed from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance.html.
* webgl/2.0.y/conformance/canvas/to-data-url-after-composite-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/2.0.y/conformance/canvas/to-data-url-after-composite.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176.html: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178-expected.txt: Added.
* webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178.html: Added.
* webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt: Added.
* webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test.html: Added.
* webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt: Added.
* webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html: Added.
* webgl/2.0.y/conformance/textures/misc/format-filterable-renderable-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt.
* webgl/2.0.y/conformance/textures/misc/format-filterable-renderable.html: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html.
* webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html: Removed.
* webgl/2.0.y/conformance/textures/misc/origin-clean-conformance.html: Removed.
* webgl/2.0.y/conformance/textures/misc/png-image-types-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt.
* webgl/2.0.y/conformance/textures/misc/png-image-types.html: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html.
* webgl/2.0.y/conformance2/extensions/required-extensions-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/2.0.y/conformance2/extensions/required-extensions.html: Added.
* webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash.html: Added.
* webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash-expected.txt: Added.
* webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html: Added.
* webgl/2.0.y/conformance2/misc/blend-integer-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
* webgl/2.0.y/conformance2/misc/blend-integer.html: Added.
* webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask-expected.txt: Added.
* webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html: Added.
* webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations-expected.txt: Added.
* webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations.html: Added.
* webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt: Removed.
* webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html: Removed.
* webgl/2.0.y/deqp/functional/gles3/multisample.html: Removed.
* webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo-expected.txt: Added.
* webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo.html: Added.
* webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples-expected.txt: Added.
* webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples.html: Added.
* webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples-expected.txt: Added.
* webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples.html: Added.
* webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples-expected.txt: Added.
* webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples.html: Added.
* webgl/draw-webgl-to-context2d-memory-test-expected.txt:
* webgl/resources/webgl_test_files/conformance/attribs/gl-vertexattribpointer.html:
* webgl/resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html: Added.
* webgl/resources/webgl_test_files/conformance/context/context-attributes-alpha-depth-stencil-antialias.html:
* webgl/resources/webgl_test_files/conformance/context/methods.html:
* webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-bptc.html:
* webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-rgtc.html:
* webgl/resources/webgl_test_files/conformance/extensions/s3tc-and-rgtc.html:
* webgl/resources/webgl_test_files/conformance/extensions/webgl-compressed-texture-s3tc-srgb.html:
* webgl/resources/webgl_test_files/conformance/extensions/webgl-multi-draw.html:
* webgl/resources/webgl_test_files/conformance/extensions/webgl-webcodecs-video-frame.html:
* webgl/resources/webgl_test_files/conformance/glsl/bugs/character-set.html:
* webgl/resources/webgl_test_files/conformance/glsl/constructors/glsl-construct-vec-mat-index.html:
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Data_Types_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Standard_Library_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectBuiltInOveride_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectComma_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding1_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding2_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstruct_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension10_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension1_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension4_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFull_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFunction1_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectModule_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess5_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess8_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess9_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectVersion_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/DuplicateVersion1_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/FunctionParam_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/Include_Preprocessor_Directive_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/Low_Level_Assembly_Reserved_Words_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/Main_Parameters_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Constant_Conversions_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Scalar_Vector_Expressions_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/TernaryOp_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/Texture_Rectangle_Samplers_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array10_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array11_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array5_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array6_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array7_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array8_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/array9_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute1_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute2_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/break_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma1_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma3_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/comment_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/constFunc_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor3_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/continue_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType10_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType11_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType12_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType13_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType19_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType5_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType6_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType7_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType8_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType9_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dowhile_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension2_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension3_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension5_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension6_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension7_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension8_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension9_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/float2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/float3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/float4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly1_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly2_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly3_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly4_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function10_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function2_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function6_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function7_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function8_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/function9_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/if1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/if2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment6_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/input.run.txt: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/main1_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/main2_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/main3_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/matrix_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/normal_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser10_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser1_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser5_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser6_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser7_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser8_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser9_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess0_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess10_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess6_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess7_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct10_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct11_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct4_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct5_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct6_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct7_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct8_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct9_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/typecast_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying3_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/vector_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/version2_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/version3_V100_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertex_vert.vert: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/while1_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/while2_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/ogles/GL/build/while_frag.frag: Added.
* webgl/resources/webgl_test_files/conformance/programs/program-test.html:
* webgl/resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html: Added.
* webgl/resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html: Added.
* webgl/resources/webgl_test_files/conformance/state/gl-object-get-calls.html:
* webgl/resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html: Added.
* webgl/resources/webgl_test_files/conformance/textures/misc/png-image-types.html: Added.
* webgl/resources/webgl_test_files/conformance/textures/misc/video-rotation.html:
* webgl/resources/webgl_test_files/conformance2/context/methods-2.html:
* webgl/resources/webgl_test_files/conformance2/extensions/ext-color-buffer-float.html:
* webgl/resources/webgl_test_files/conformance2/extensions/ext-texture-norm16.html:
* webgl/resources/webgl_test_files/conformance2/extensions/oes-draw-buffers-indexed.html:
* webgl/resources/webgl_test_files/conformance2/extensions/required-extensions.html: Added.
* webgl/resources/webgl_test_files/conformance2/extensions/webgl-multi-draw-instanced-base-vertex-base-instance.html:
* webgl/resources/webgl_test_files/conformance2/glsl3/array-equality.html:
* webgl/resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html: Added.
* webgl/resources/webgl_test_files/conformance2/glsl3/matrix-row-major-dynamic-indexing.html:
* webgl/resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html: Added.
* webgl/resources/webgl_test_files/conformance2/misc/blend-integer.html: Added.
* webgl/resources/webgl_test_files/conformance2/programs/gl-get-frag-data-location.html:
* webgl/resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html: Added.
* webgl/resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html: Added.
* webgl/resources/webgl_test_files/conformance2/state/gl-object-get-calls.html:
* webgl/resources/webgl_test_files/conformance2/textures/misc/tex-storage-compressed-formats.html:
* webgl/resources/webgl_test_files/deqp/functional/gles3/es3fMultisampleTests.js:
* webgl/resources/webgl_test_files/deqp/functional/gles3/es3fPrimitiveRestartTests.js:
* webgl/resources/webgl_test_files/deqp/functional/gles3/multisample.html: Removed.
* webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html: Added.
* webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html: Added.
* webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html: Added.
* webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html: Added.
* webgl/resources/webgl_test_files/js/glsl-conformance-test.js:
* webgl/resources/webgl_test_files/js/js-test-post.js:
* webgl/resources/webgl_test_files/js/js-test-pre.js:
* webgl/resources/webgl_test_files/js/tests/compressed-texture-utils.js:
* webgl/resources/webgl_test_files/js/tests/context-methods.js: Added.
* webgl/resources/webgl_test_files/js/tests/ext-color-buffer-half-float.js:
* webgl/resources/webgl_test_files/js/tests/gl-object-get-calls.js:
* webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-2d-with-image-bitmap-from-video.js:
* webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-3d-with-image-bitmap-from-video.js:
* webgl/resources/webgl_test_files/js/webgl-test-utils.js:
* webgl/resources/webgl_test_files/resources/red-green.webmvp8.webm:
* webgl/resources/webgl_test_files/resources/video-rotation-0.mp4:
* webgl/resources/webgl_test_files/resources/video-rotation-0.vp9.mp4:
* webgl/resources/webgl_test_files/resources/video-rotation-180.mp4:
* webgl/resources/webgl_test_files/resources/video-rotation-180.vp9.mp4:
* webgl/resources/webgl_test_files/resources/video-rotation-270.mp4:
* webgl/resources/webgl_test_files/resources/video-rotation-270.vp9.mp4:
* webgl/resources/webgl_test_files/resources/video-rotation-90.mp4:
* webgl/resources/webgl_test_files/resources/video-rotation-90.vp9.mp4:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@288671 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 6a12375..44e1da4 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,550 @@
+2022-01-27  Kimmo Kinnunen  <kkinnunen@apple.com>
+
+        Update WebGL conformance test suite to 2022-01-12
+        https://bugs.webkit.org/show_bug.cgi?id=235563
+
+        Reviewed by Dean Jackson.
+
+        Update WebGL testsuite to 2022-01-12 9b58fd243d38f4b9c72ab6f75ad701cafc131137.
+
+        Additionally:
+        The import script can now categorize tests to regular tests and small amount of http
+        tests:
+         - Remove old http/tests/webgl/1.0.2/
+         - Add new http/tests/webgl/1.0.x / 2.0.y
+
+        * http/tests/webgl/1.0.2/origin-clean-conformance-expected.txt: Removed.
+        * http/tests/webgl/1.0.2/origin-clean-conformance.html: Removed.
+        * http/tests/webgl/1.0.2/readPixelsBadArgs-expected.txt: Removed.
+        * http/tests/webgl/1.0.2/readPixelsBadArgs.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/3x3.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/blue-1x1.jpg: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/bug-32888-texture.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/floatUniformShader.vert: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/fragmentShader.frag: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256-with-128-alpha.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-default-gamma.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma0.1.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma1.0.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma2.0.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma4.0.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma9.0.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/green-2x2-16bit.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/noopUniformShader.frag: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.mp4: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.theora.ogv: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.webmvp8.webm: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/pnglib.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.mp4: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.theora.ogv: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.webmvp8.webm: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-indexed.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-cie-rgb-profile.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colormatch-profile.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.jpg: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-e-srgb-profile.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-smpte-c-profile.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-srgb-iec61966-2.1-profile.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-canvas.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image-data.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-video.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/vertexShader.vert: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test-utils.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/zero-alpha.png: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/00_test_list.txt: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/compressed-tex-image.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-2d-formats.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-and-sub-image-2d.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-get-tex-parameter.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-pixelstorei.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-teximage.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/mipmap-fbo.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/origin-clean-conformance.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-array-buffer-view.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgb565.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba4444.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba5551.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgb565.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba4444.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba5551.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgb565.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba4444.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba5551.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgb565.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba4444.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba5551.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-uniform-binding-bugs.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-webgl.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-format-and-type.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-invalid-data.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-input-validation.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d-bad-args.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texparameter-test.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind-2.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-attachment-formats.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-clear.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-complete.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-formats-test.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-hd-dpi.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-mips.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot-video.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-cube-maps.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-limit.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-sub-image-cube-maps.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-transparent-pixels-initialized.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-upload-cube-maps.html: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/resources/desktop-gl-constants.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-post.js: Removed.
+        * http/tests/webgl/1.0.2/resources/webgl_test_files/resources/webgl-test-harness.js: Removed.
+        * http/tests/webgl/1.0.2/texImage2DHTML-expected.txt: Removed.
+        * http/tests/webgl/1.0.2/texImage2DHTML.html: Removed.
+        * http/tests/webgl/1.0.2/texSubImage2DHTML-expected.txt: Removed.
+        * http/tests/webgl/1.0.2/texSubImage2DHTML.html: Removed.
+        * http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt.
+        * http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html.
+        * http/tests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * http/tests/webgl/1.0.x/conformance/more/functions/texImage2DHTML.html: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML.html.
+        * http/tests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML-expected.txt.
+        * http/tests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML.html: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML.html.
+        * http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt.
+        * http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs.html: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs.html.
+        * http/tests/webgl/2.0.y/conformance/more/functions/texImage2DHTML-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML-expected.txt.
+        * http/tests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html: Copied from LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html.
+        * http/tests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML-expected.txt.
+        * http/tests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML.html: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML.html.
+        * http/tests/webgl/resources/js-test-pre.js: Copied from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js.
+        * http/tests/webgl/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html.
+        * http/tests/webgl/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html.
+        * http/tests/webgl/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html.
+        * http/tests/webgl/resources/webgl_test_files/conformance/more/unit.css: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.css.
+        * http/tests/webgl/resources/webgl_test_files/conformance/more/unit.js: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.js.
+        * http/tests/webgl/resources/webgl_test_files/conformance/more/util.js: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/util.js.
+        * http/tests/webgl/resources/webgl_test_files/js/js-test-post.js: Added.
+        * http/tests/webgl/resources/webgl_test_files/js/js-test-pre.js: Copied from LayoutTests/webgl/resources/webgl_test_files/js/js-test-pre.js.
+        * http/tests/webgl/resources/webgl_test_files/js/webgl-test-utils.js: Copied from LayoutTests/webgl/resources/webgl_test_files/js/webgl-test-utils.js.
+        * http/tests/webgl/resources/webgl_test_files/resources/js-test-style.css: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-style.css.
+        * http/tests/webgl/resources/webgl_test_files/resources/opengl_logo.jpg: Added.
+        * http/tests/webgl/resources/webgl_test_files/resources/thunderbird-logo-64x64.png: Added.
+        * http/tests/webgl/resources/webkit-webgl-test-harness.js: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webkit-webgl-test-harness.js.
+        * webgl/1.0.x/conformance/canvas/to-data-url-after-composite-expected.txt: Renamed from LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample-expected.txt.
+        * webgl/1.0.x/conformance/canvas/to-data-url-after-composite.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176.html: Added.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178.html: Added.
+        * webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt: Added.
+        * webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test.html: Added.
+        * webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt: Added.
+        * webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html: Added.
+        * webgl/1.0.x/conformance/textures/misc/format-filterable-renderable-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-expected.txt.
+        * webgl/1.0.x/conformance/textures/misc/format-filterable-renderable.html: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html.
+        * webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html: Removed.
+        * webgl/1.0.x/conformance/textures/misc/png-image-types-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt.
+        * webgl/1.0.x/conformance/textures/misc/png-image-types.html: Renamed from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance.html.
+        * webgl/2.0.y/conformance/canvas/to-data-url-after-composite-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/2.0.y/conformance/canvas/to-data-url-after-composite.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176.html: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178-expected.txt: Added.
+        * webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178.html: Added.
+        * webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt: Added.
+        * webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test.html: Added.
+        * webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt: Added.
+        * webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html: Added.
+        * webgl/2.0.y/conformance/textures/misc/format-filterable-renderable-expected.txt: Renamed from LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt.
+        * webgl/2.0.y/conformance/textures/misc/format-filterable-renderable.html: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html.
+        * webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html: Removed.
+        * webgl/2.0.y/conformance/textures/misc/origin-clean-conformance.html: Removed.
+        * webgl/2.0.y/conformance/textures/misc/png-image-types-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt.
+        * webgl/2.0.y/conformance/textures/misc/png-image-types.html: Renamed from LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html.
+        * webgl/2.0.y/conformance2/extensions/required-extensions-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/2.0.y/conformance2/extensions/required-extensions.html: Added.
+        * webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash-expected.txt: Copied from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash.html: Added.
+        * webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash-expected.txt: Added.
+        * webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html: Added.
+        * webgl/2.0.y/conformance2/misc/blend-integer-expected.txt: Renamed from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt.
+        * webgl/2.0.y/conformance2/misc/blend-integer.html: Added.
+        * webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask-expected.txt: Added.
+        * webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html: Added.
+        * webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations-expected.txt: Added.
+        * webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations.html: Added.
+        * webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt: Removed.
+        * webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html: Removed.
+        * webgl/2.0.y/deqp/functional/gles3/multisample.html: Removed.
+        * webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo-expected.txt: Added.
+        * webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo.html: Added.
+        * webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples-expected.txt: Added.
+        * webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples.html: Added.
+        * webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples-expected.txt: Added.
+        * webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples.html: Added.
+        * webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples-expected.txt: Added.
+        * webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples.html: Added.
+        * webgl/draw-webgl-to-context2d-memory-test-expected.txt:
+        * webgl/resources/webgl_test_files/conformance/attribs/gl-vertexattribpointer.html:
+        * webgl/resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html: Added.
+        * webgl/resources/webgl_test_files/conformance/context/context-attributes-alpha-depth-stencil-antialias.html:
+        * webgl/resources/webgl_test_files/conformance/context/methods.html:
+        * webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-bptc.html:
+        * webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-rgtc.html:
+        * webgl/resources/webgl_test_files/conformance/extensions/s3tc-and-rgtc.html:
+        * webgl/resources/webgl_test_files/conformance/extensions/webgl-compressed-texture-s3tc-srgb.html:
+        * webgl/resources/webgl_test_files/conformance/extensions/webgl-multi-draw.html:
+        * webgl/resources/webgl_test_files/conformance/extensions/webgl-webcodecs-video-frame.html:
+        * webgl/resources/webgl_test_files/conformance/glsl/bugs/character-set.html:
+        * webgl/resources/webgl_test_files/conformance/glsl/constructors/glsl-construct-vec-mat-index.html:
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Data_Types_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Standard_Library_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectBuiltInOveride_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectComma_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding1_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding2_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstruct_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension10_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension1_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension4_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFull_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFunction1_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectModule_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess5_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess8_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess9_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectVersion_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/DuplicateVersion1_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/FunctionParam_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/Include_Preprocessor_Directive_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/Low_Level_Assembly_Reserved_Words_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/Main_Parameters_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Constant_Conversions_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Scalar_Vector_Expressions_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/TernaryOp_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/Texture_Rectangle_Samplers_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array10_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array11_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array5_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array6_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array7_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array8_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/array9_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute1_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute2_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/break_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma1_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma3_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/comment_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/constFunc_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor3_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/continue_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType10_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType11_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType12_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType13_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType19_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType5_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType6_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType7_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType8_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType9_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dowhile_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension2_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension3_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension5_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension6_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension7_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension8_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension9_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/float2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/float3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/float4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly1_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly2_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly3_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly4_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function10_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function2_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function6_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function7_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function8_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/function9_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/if1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/if2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment6_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/input.run.txt: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/main1_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/main2_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/main3_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/matrix_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/normal_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser10_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser1_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser5_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser6_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser7_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser8_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser9_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess0_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess10_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess6_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess7_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct10_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct11_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct4_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct5_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct6_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct7_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct8_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct9_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/typecast_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying3_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/vector_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/version2_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/version3_V100_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertex_vert.vert: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/while1_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/while2_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/ogles/GL/build/while_frag.frag: Added.
+        * webgl/resources/webgl_test_files/conformance/programs/program-test.html:
+        * webgl/resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html: Added.
+        * webgl/resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html: Added.
+        * webgl/resources/webgl_test_files/conformance/state/gl-object-get-calls.html:
+        * webgl/resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html: Added.
+        * webgl/resources/webgl_test_files/conformance/textures/misc/png-image-types.html: Added.
+        * webgl/resources/webgl_test_files/conformance/textures/misc/video-rotation.html:
+        * webgl/resources/webgl_test_files/conformance2/context/methods-2.html:
+        * webgl/resources/webgl_test_files/conformance2/extensions/ext-color-buffer-float.html:
+        * webgl/resources/webgl_test_files/conformance2/extensions/ext-texture-norm16.html:
+        * webgl/resources/webgl_test_files/conformance2/extensions/oes-draw-buffers-indexed.html:
+        * webgl/resources/webgl_test_files/conformance2/extensions/required-extensions.html: Added.
+        * webgl/resources/webgl_test_files/conformance2/extensions/webgl-multi-draw-instanced-base-vertex-base-instance.html:
+        * webgl/resources/webgl_test_files/conformance2/glsl3/array-equality.html:
+        * webgl/resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html: Added.
+        * webgl/resources/webgl_test_files/conformance2/glsl3/matrix-row-major-dynamic-indexing.html:
+        * webgl/resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html: Added.
+        * webgl/resources/webgl_test_files/conformance2/misc/blend-integer.html: Added.
+        * webgl/resources/webgl_test_files/conformance2/programs/gl-get-frag-data-location.html:
+        * webgl/resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html: Added.
+        * webgl/resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html: Added.
+        * webgl/resources/webgl_test_files/conformance2/state/gl-object-get-calls.html:
+        * webgl/resources/webgl_test_files/conformance2/textures/misc/tex-storage-compressed-formats.html:
+        * webgl/resources/webgl_test_files/deqp/functional/gles3/es3fMultisampleTests.js:
+        * webgl/resources/webgl_test_files/deqp/functional/gles3/es3fPrimitiveRestartTests.js:
+        * webgl/resources/webgl_test_files/deqp/functional/gles3/multisample.html: Removed.
+        * webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html: Added.
+        * webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html: Added.
+        * webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html: Added.
+        * webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html: Added.
+        * webgl/resources/webgl_test_files/js/glsl-conformance-test.js:
+        * webgl/resources/webgl_test_files/js/js-test-post.js:
+        * webgl/resources/webgl_test_files/js/js-test-pre.js:
+        * webgl/resources/webgl_test_files/js/tests/compressed-texture-utils.js:
+        * webgl/resources/webgl_test_files/js/tests/context-methods.js: Added.
+        * webgl/resources/webgl_test_files/js/tests/ext-color-buffer-half-float.js:
+        * webgl/resources/webgl_test_files/js/tests/gl-object-get-calls.js:
+        * webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-2d-with-image-bitmap-from-video.js:
+        * webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-3d-with-image-bitmap-from-video.js:
+        * webgl/resources/webgl_test_files/js/webgl-test-utils.js:
+        * webgl/resources/webgl_test_files/resources/red-green.webmvp8.webm:
+        * webgl/resources/webgl_test_files/resources/video-rotation-0.mp4:
+        * webgl/resources/webgl_test_files/resources/video-rotation-0.vp9.mp4:
+        * webgl/resources/webgl_test_files/resources/video-rotation-180.mp4:
+        * webgl/resources/webgl_test_files/resources/video-rotation-180.vp9.mp4:
+        * webgl/resources/webgl_test_files/resources/video-rotation-270.mp4:
+        * webgl/resources/webgl_test_files/resources/video-rotation-270.vp9.mp4:
+        * webgl/resources/webgl_test_files/resources/video-rotation-90.mp4:
+        * webgl/resources/webgl_test_files/resources/video-rotation-90.vp9.mp4:
+
 2022-01-27  Cameron McCormack  <heycam@apple.com>
 
         Avoid setting and clearing :active state when dispatching synthetic click events when possible
diff --git a/LayoutTests/http/tests/webgl/1.0.2/origin-clean-conformance-expected.txt b/LayoutTests/http/tests/webgl/1.0.2/origin-clean-conformance-expected.txt
deleted file mode 100644
index e645d38..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/origin-clean-conformance-expected.txt
+++ /dev/null
@@ -1,9 +0,0 @@
-CONSOLE MESSAGE: Promoted URL from http://www.opengl.org/img/opengl_logo.jpg to https
-Blocked access to external URL https://www.opengl.org/img/opengl_logo.jpg
-CONSOLE MESSAGE: Promoted URL from http://www.opengl.org/img/opengl_logo.jpg to https
-Blocked access to external URL https://www.opengl.org/img/opengl_logo.jpg
-This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
-
-Test: resources/webgl_test_files/conformance/textures/origin-clean-conformance.html
-FAIL
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/origin-clean-conformance.html b/LayoutTests/http/tests/webgl/1.0.2/origin-clean-conformance.html
deleted file mode 100644
index 1038832..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/origin-clean-conformance.html
+++ /dev/null
@@ -1,18 +0,0 @@
-<!-- This file is auto-generated by generate-webgl-tests.py. DO NOT EDIT -->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Conformance Test Wrapper for origin-clean-conformance.html</title>
-<script type="text/javascript" src="resources/conformance/resources/js-test-pre.js"></script>
-<script type="text/javascript" src="resources/webkit-webgl-test-harness.js"></script>
-</head>
-<body>
-<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
-Test: <a href="resources/webgl_test_files/conformance/textures/origin-clean-conformance.html">resources/webgl_test_files/conformance/textures/origin-clean-conformance.html</a>
-<div id="result"></div>
-<div id="iframe">
-<iframe src="resources/webgl_test_files/conformance/textures/origin-clean-conformance.html" width="800" height="600"></iframe>
-</div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/readPixelsBadArgs-expected.txt b/LayoutTests/http/tests/webgl/1.0.2/readPixelsBadArgs-expected.txt
deleted file mode 100644
index 0aaca86..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/readPixelsBadArgs-expected.txt
+++ /dev/null
@@ -1,9 +0,0 @@
-CONSOLE MESSAGE: Promoted URL from http://www.opengl.org/img/opengl_logo.jpg to https
-Blocked access to external URL https://www.opengl.org/img/opengl_logo.jpg
-CONSOLE MESSAGE: Promoted URL from http://www.opengl.org/img/opengl_logo.jpg to https
-Blocked access to external URL https://www.opengl.org/img/opengl_logo.jpg
-This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
-
-Test: resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html
-FAIL
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/readPixelsBadArgs.html b/LayoutTests/http/tests/webgl/1.0.2/readPixelsBadArgs.html
deleted file mode 100644
index b6be713..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/readPixelsBadArgs.html
+++ /dev/null
@@ -1,18 +0,0 @@
-<!-- This file is auto-generated by generate-webgl-tests.py. DO NOT EDIT -->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Conformance Test Wrapper for readPixelsBadArgs.html</title>
-<script type="text/javascript" src="resources/conformance/resources/js-test-pre.js"></script>
-<script type="text/javascript" src="resources/webkit-webgl-test-harness.js"></script>
-</head>
-<body>
-<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
-Test: <a href="resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html">resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html</a>
-<div id="result"></div>
-<div id="iframe">
-<iframe src="resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html" width="800" height="600"></iframe>
-</div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html
deleted file mode 100644
index 3e69613..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html
+++ /dev/null
@@ -1,119 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-<link rel="stylesheet" type="text/css" href="../unit.css" />
-<script type="application/x-javascript" src="../unit.js"></script>
-<script type="application/x-javascript" src="../util.js"></script>
-<script type="application/x-javascript">
-
-Tests.startUnit = function () {
-  var canvas = document.getElementById('gl');
-  var gl = wrapGLContext(getGLContext(canvas));
-  return [gl];
-}
-
-Tests.testReadPixels = function(gl) {
-  // we can't know if this is going to fail because of negative width
-  // or because the buffer size doesn't match the dimensions.
-  assertSomeGLError(gl, "negative width",
-      function(){gl.readPixels(0,0,-1,1, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(4));});
-  assertSomeGLError(gl,  "negative height",
-      function(){gl.readPixels(0,0,1,-1, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(4));});
-  assertOk("negative x",
-      function(){gl.readPixels(-1,0,1,1, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(4));});
-  assertOk("negative y",
-      function(){gl.readPixels(0,-1,1,1, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(4));});
-  assertOk("height > backbuffer height",
-      function(){gl.readPixels(0,0,16,17, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(16*17*4));});
-  assertOk("width > backbuffer width",
-      function(){gl.readPixels(0,0,17,16, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(17*16*4));});
-  assertOk("width, height = 0",
-      function(){gl.readPixels(0,0,0,0, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(0));});
-  // we can't know if this is going to fail because of negative width
-  // or because the buffer size doesn't match the dimensions.
-  assertSomeGLError(gl, "bad format",
-      function(){gl.readPixels(0,0,1,1, gl.FLOAT, gl.UNSIGNED_BYTE,
-          new Uint8Array(4*4));});
-  // we can't know if this is going to fail because of negative width
-  // or because the buffer size doesn't match the dimensions.
-  assertSomeGLError(gl, "bad type",
-      function(){gl.readPixels(0,0,1,1, gl.ALPHA, gl.FLOAT,
-          new Uint8Array(1*4));});
-}
-
-Tests.testReadPixelsSOPIMG = function(gl) {
-    var img = document.getElementById("i");
-    while (!img.complete) {}
-    var tex = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, tex);
-    // SOP failure
-    assertThrowNoGLError(gl, "throw because img is from another domain",
-      function(){gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, img);});
-    gl.bindTexture(gl.TEXTURE_2D, null);
-    assertOk("canvas still origin-clean",
-      function(){gl.readPixels(0,0,1,1, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(4));});
-    gl.deleteTexture(tex);
-}
-Tests.testReadPixelsSOPCanvas = function(gl) {
-    var img = document.getElementById("i");
-    while (!img.complete) {}
-    var c = document.getElementById("c");
-    c.getContext("2d").drawImage(img, 0, 0);
-    assertFail("canvas throws because not origin clean",
-      function(){c.getContext("2d").getImageData(0,0,1,1);});
-    var tex = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, tex);
-    // SOP failure
-    assertThrowNoGLError(gl, "throw because canvas is not origin clean",
-      function(){gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);});
-    gl.bindTexture(gl.TEXTURE_2D, null);
-    assertOk("canvas still origin-clean",
-      function(){gl.readPixels(0,0,1,1, gl.RGBA, gl.UNSIGNED_BYTE,
-          new Uint8Array(4));});
-    gl.deleteTexture(tex);
-}
-
-Tests.endUnit = function(gl) {
-}
-
-</script>
-</head><body>
-<canvas id="gl" width="16" height="16"></canvas>
-<canvas id="c" width="128" height="128"></canvas>
-<img id="i" src="http://www.opengl.org/img/opengl_logo.jpg">
-</body></html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html
deleted file mode 100644
index 9defd78..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html
+++ /dev/null
@@ -1,152 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-<link rel="stylesheet" type="text/css" href="../unit.css" />
-<script type="application/x-javascript" src="../unit.js"></script>
-<script type="application/x-javascript" src="../util.js"></script>
-<script type="application/x-javascript">
-
-Tests.startUnit = function () {
-    var canvas = document.getElementById('gl');
-    var gl = wrapGLContext(getGLContext(canvas));
-    gl.viewport(0,0,canvas.width,canvas.height);
-    gl.clearColor(0,0,1,1);
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    gl.disable(gl.DEPTH_TEST);
-    return [gl];
-}
-
-Tests.setup = function(gl) {
-    var tex = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, tex);
-    var texCubeMap = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_CUBE_MAP, texCubeMap);
-    return [gl]
-}
-
-Tests.teardown = function(gl, tex, texCubeMap) {
-    gl.bindTexture(gl.TEXTURE_2D, null);
-    gl.deleteTexture(tex);
-    gl.bindTexture(gl.TEXTURE_CUBE_MAP, null);
-    gl.deleteTexture(texCubeMap);
-}
-
-Tests.testTexImage2D = function(gl) {
-    gl.enable(gl.BLEND);
-    var img = document.getElementById('i');
-    var c = document.getElementById('c');
-    var ctx = c.getContext('2d');
-    ctx.drawImage(img,0,0);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, img);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-    var f = new Filter(gl, 'identity-flip-vert', 'identity-frag');
-    gl.blendFunc(gl.ONE, gl.ZERO);
-    f.apply();
-    f.destroy();
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);
-    f = new Filter(gl, 'identity-hflip-vert', 'identity-frag');
-    gl.blendFunc(gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA);
-    f.apply();
-    f.destroy();
-    var valid_targets = [
-        gl.TEXTURE_2D,
-        gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-        gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-        gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-        gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-        gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-        gl.TEXTURE_CUBE_MAP_NEGATIVE_Z
-    ];
-    valid_targets.forEach(function(t) {
-        assertOk(function(){gl.texImage2D(t, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);});
-        assertOk(function(){gl.texImage2D(t, 1, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);});
-    });
-}
-
-Tests.testTexImage2DNonSOP = function(gl) {
-    var img = document.getElementById('i2');
-    while (!img.complete) {}
-    var c = document.getElementById('c');
-    var ctx = c.getContext('2d');
-    ctx.drawImage(img,0,0);
-    assertThrowNoGLError(gl, "texImage2D with cross-origin image should throw exception.",
-      function(){gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, img);});
-    assertThrowNoGLError(gl, "texImage2D with dirty origin canvas should throw exception.",
-      function(){gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);});
-}
-
-Tests.endUnit = function(gl) {
-}
-
-</script>
-<script id="identity-flip-vert" type="x-shader/x-vertex">
-attribute vec3 Vertex;
-attribute vec2 Tex;
-
-varying vec4 texCoord0;
-void main()
-{
-    texCoord0 = vec4(Tex.s, 1.0-Tex.t, 0.0, 0.0);
-    gl_Position = vec4(Vertex, 1.0);
-}
-</script>
-<script id="identity-hflip-vert" type="x-shader/x-vertex">
-attribute vec3 Vertex;
-attribute vec2 Tex;
-
-varying vec4 texCoord0;
-void main()
-{
-    texCoord0 = vec4(1.0-Tex.s, Tex.t, 0.0, 0.0);
-    gl_Position = vec4(Vertex, 1.0);
-}
-</script>
-<script id="identity-frag" type="x-shader/x-fragment">
-precision mediump float;
-
-uniform sampler2D Texture;
-
-varying vec4 texCoord0;
-void main()
-{
-    vec4 c = texture2D(Texture, texCoord0.st);
-    gl_FragColor = c;
-}
-</script>
-</head><body>
-<canvas id="gl" width="256" height="256"></canvas>
-<canvas id="c" width="256" height="256"></canvas>
-<img id="i" width="256" height="256"  src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEACAYAAABccqhmAAATVElEQVR4nO3d+VPUd57Hcf2b9k9Y+z44+qK7OZoGFVA5VfBGzah9cxpNzGEOoRua5lBEue/DK4fZ7MapmSm3Mlshu8xOdCpDJt3v/aEBAUHAOMG4z0fV53fqU/V6fd7fT/e32bEDAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwOvBkar7l+3+GwBsk8xUrT0rTb8vx2Q45janlu7YsWPnsgXgTeYwak85U3Xv5ZiM3+XbUh/l2dICBc6080WZ1ur92baSHRQB8GayGdUWu1HzoSNFO+ZM1f2cbTLM51lT5woc5rkDObbZ/Vm2SEm23VvsyjhV5nJQBsCbxGZQVtmN6p4Mo/YPdqNGHKlayUrXJ9zWlESh0xIvzsmYL3HZ54pzMm6VuRyRMpfTW+pyUAbAm8BmVNVnGNTTdqP6vzOMGrGnaMSZqpNsk17ybKlS6DTL/ixbotRlj5flOubL3I65MpfjVrnbEalYKINSl335vQGA3wKbUW2xGdWRDKP66wyjWhYLwJGiFWeaTrJNBnFbU2SP3ST7s6xSmmuXcrczUe52xstzHfPlbsdcudt5qyzX3lKWlxkszXGeK8mxnyzJySjeQRkArzebQVllM6p7bUb149UF4EjVSmaaTrLS9eKypMgee7ocyLZJmdshFXmZUpHnXFEGB/OzJsrdjqEyt/NmWa49XJbt9Ja6Mk4Vu7hEBF5LNr2q3mZQz9gM6u9XFEBqsgCcaTrJXJgEci0pstdhkv3ZNinNTZbAofwsOZSfJQfzMqU8z5kodzsSZbmOeIXb+XW52zFa5nLcKnPZI2ULl4jFfKIAvB7MOrXFZlBHbAb11zaj+kmGUbNuAWSm65dKYHdGmhRlWqQ8zyFHCnLk+L5cOV6UK0cKXVK5J1sO5mdKhdspZavKoDTX0VPiciTLIHtFGVAIwK/NYlBW2fTqXptB/dhmSJ7+LyqArHS95JiTJVDgNEllQZZ4KgulrrpU6qtLJXBsv5wt3yMn9rvlaIFLDi8vg1xH4mB+5p+Wl0Fpjr2lJMcRLM6ynyvOzjhxIIt7A+BXY9Gr6q0L4/9SAaRoxL7w/L9WAWSbDJJrTZFid4Z4jxZJU/1xufHhOem+ek6il0/LB74qaTxTJoGj++Vs2R45vj9XjhTkyOHdC48JC2VwaHfmnyrczn+vcDsmynLtQyU5GTeLczLCpTk2T3GW7VhxVsae7d4f4I1l1qktVoM6YjOovrYa1D8sFoB9WQE415kA8u1pcvRAjnwUOiLDLQG5190o9242ylRHnQyG/XLz6nmJXqqWD3yV0nC6VPxH98nZst1yfF+uHC10SdXebDmUnyyDqoLs7w7lZ35b7nb8scxt/7dSl32kJCejqyQn40pJTkbZDiYC4NWzaJVVVr2q12ZQPbYa1H9fuwB0SwWQla6XLFOyAAoyTfLW4T3SfuWM3L3RIA/7L8vD/svyZe8l+ezW23Kvu1EmO2ploNkn3VfPSevb1fK+t1Iaz5RJ7cli8R0pktOl+XKsKFkGBxfKoHJv1l8P5mf+uSLP8fvyXMdMmdsRKXc5qotdGQXbvV/AG8WiV9Vb9aoZq141azOoxWbcXAHkWlOkJC9Dak8Xy61PL8iDnotLBbBUBH2X5Yvbl+RBz0W5e6NBJtprpL/ZJzc/Oi/XP3hLWi6ekvc8h6WuukS8Vc/KYPEC8WhhzpOqguzvKvdmfXV4d2b3wfzM9w/lZTENAK+CWaewWHWqiE2v+tqqV/2w2QLINhkkP2Nh/K89ImNtIfmi99Kz8Pcl15dL65J80XtJPr/1tty/2Sh3uxvkzvV6GY+FpO+aV65/8DuJXDwpVzyHpO7UQhmU5MvRIpdU7c2RQ7uz5MR+9x+OFbnuHi3MiVQVuKoP784u2u79A37TLFpllVWn6rXqVY+tetWPGxbAsgvAvU6TvHVot8SunJY7N+rly761g/9lb3J9sWx9fvuSfH77bXnQc1HudTfITFedjLWFpPeaR7o+eEvCjSflyoVDUlddKsHjB+TC4UI5VZwnVQU5ibcq9nx1ujS/58QB99XqYnf5DqYB4OVYdM/Gf6te9Y/k8//GBeCyGKXEnSE11Qek55Pzcv9m48rQrxP8L25fki9uvy2fr1qf3bqYnAxuNMh0Z52MRINy+1OPXP/wd9J+5Yw015+Qd84flJqTxXLhcIGcLM77+UhBzt8uVBa2nqvce/ZsxZ6y7d5L4Ddlcfy36FVfW/SqH6wGlawugMWvATvTlhWAySB5GalydH+OfFRzREajQfn81tvrh/6FwV9cF+WzWxflwa2Lcr/notzrbpSZ6/Uy1VUnkx21MtwSkJ5PLkjHe2elqf64XD53UEInDiQuHC6Yry7Omz1W5HrY+FbF4R1MA8DmWLTKKsuy8d9qUL+wAJZ/C3CPM13OHtwtbe+elunr9fLFusF/PvSf31o7+A96nq37PRflfk+j3L+Z/Fjx7o0Gme6qk4n2Ghlq8UvPx+el/coZuVZ3XC6fq/i57lTx32pOHngUOlUc/jR4lEtCYCMWnareolfNWPSqWatB9dOaBbDGl4BcFqMUu20SOnVAbn58Tu52N27qtP98g9A/WAz9QvAX173FEuhukLvdDcnJoLNWxmM1Mhjxy82Pzknn+2cSsXdPz4cbT8x+GKh8+FHwSO0OSgBYm1mnsJh1qohFr1wY/5XxZwWw/teAs9KTvwtwZH+2XA1VyXBrUB70XFz/tF9nzN9K8O91N8i9hfAvrjs3GuTOjXqZXnhEGG+vkdFoUAbD/p97Pj7/t56r57/pu+b5pOXd6qPbvdfAa8ei3VVl0al6LXrlY4tO+aNFr0pstgD2ONLlzMHdEn2nWqY66+SzlxzzHywb858L/TrBv3vjWfgX18z15JruqpOpzlqZaA8lxmKhv49Gg3/oD/s+3u69Bl47Fp2i3qJVzVh0ylmrTvmTVZ+8AFz5HsDzBZBjNkpxrk2Cpw5I90fn5M6Nhhee9lsOfvfmg3/n+rPwz1yvk5muOpleWJMdtfHJjprvJjtqKABgueT4r4iYdcqvzbpdP1j0yvjqArCv9SJQul7ctlSp2pctHwYrZaglIPdvNq5/2r/gYm9Twb+x9eBPd9XJVHISmJ/qrP1murOGRwBgOZN2V5VFp+y1aBfGf50ysVQAa3wHYLEAstL1stuRLqcr8qX18imZ7KiVBz0XXxj6jZ/vNxn86xsHP/kIUCdTnXXx6c7av0x11PRs914Drx2TTlFv0ipmzDrlrEWn/MmiV8lmCiDbbJADuTYJntwvN67+Tmau1ydDvmbot36x9yz49S8Z/NrFNT/dVfv7qc66k9u918BrxaxePf4r4hsVgHPh9wBzrSlSVZQtHwQqZTDil7vdjVs77bcY/JmtB1+mOmsTkx21T6a6ake2e6+B145Ju6vKpFP2mrTKx2bts/F/8VuALyqA3fY0OV2eLy2XTspEe43cf8Gz/TYEXyY7amWyoyY+1VHz/VRnXfN27zXw2lka/7XKWYtW+ZNFp5TNFEC2ySD7XVYJnNgnXR++JdNddZs+7X+d4NfKZEeNTHbUzE921Dya5PIPWClNrbCYtcnx36Td9YNZp4hbdKqNC2Bh/K8szJL3/YdlIOyTOzcatvwx3sY3+r8o+DLZEUpMtNc8mehg/AeeY1LvqjJplb0mjeKxWav40axVJlYXwFpvAmam6STfnibVZXkSefukjMVCcrd7EyP+eqf9loJfu2HwJzpqZKK9RsbbQ/HJ9tD3k501jP/AaiaNot6kSY7/Zq3iJ7NOKYsXgC8qgCyTQfblWMV/fJ90fnBWJjtrV4z3Wzntn7vRv/586Lca/GcrND/RHno02c74D6yQplZYTFpFxKRVLI3/Kwvg+ReB7CnJ3wFwWVLkcGGWvOc/LP3NXpm5Xv/LT/tNBn9yE8EfT4Y/MR4LPRlvDzH+A6uZNYpKk3ZXb/rC+G/SKhKbLYC8jDQ5VZYn4YsnZLQtKHdubC70mx3zf0nwx9tDMh4LyVgsFB+PBb8fb2f8B56TrlHUp2sV0yaNYmn830wBZKXrZV+2RXzH90nH+2dloqMmWQCv4LR/+eCHloK/EH4ZjwXnx2PBR2PtQcZ/YDmTRpmarlY0mTS7vkrTKP5q0ip+NuuUYtmgABypWnFZjHKoIFOueA9JX5NHprvqNh36zZ72vyT4C+FPjLYFn4zHgoz/wGomza7d6ZpdMZNG8Y1Jo3hi1i48/2+iAPIyUuVkqVuaGk/ISDQoM9df3Wm/Mvg1Ww7+WCwkY21BGW0Lxkfbgt+PxUKM/8BqaZpdu9PUiiaTRvGVSav4y9InABsUQGa6XoqyLeI9ViTt752R8fbQqsC/4tN+i8EfawvKaDQoI9HA/Ghb8JuxKOM/8ByT5l9T09SKQLpGMWTSKv7TrFU8NeuUieUFYFv1YyCOVK3kmJPj/7veg9J7zSNTnbWv6LR/BcFfWCPRQHwkGvjLSDTAm3/AetLVyjyTRvmOSauYNOsU35p1yn9sVABuW6qcLM2Vaw3HZbg1INNdr+a0X/sz/K0FfzQalNFoIHn6RwO/H2kL8uYf8CImza5Ck27Xe2atcsqiU8bXLYAUjWSm66QwyyzeY4USu3JaxmKhtUP/i0/7mhWhXxH8tvWCH5SRaEBGo4HESKv/yWhrgMs/YDPSdcois1bxvkWnfGrRK+NrFYA9RSvZZoMc3OuUdzwH5fa1CzLRUfNPPe3H1zjt1wv+4hpuDcRHooHvR6IBLv+AzTLrlEVmnfKhRad8al3z58C04ralyImSXLnWcEyGWv0y2VkrU13Ph/6lTvsNgj+6QfBHWgMy3BqQ4Vb//HBr4NFI1M/lH7AVFr0qYNGrHlr1qqc2gyq+/E1AZ5pOCrNM4jlaIG1XTstoW/Cfd9q/VPADMtzqTwy3+J8MM/4DL2XnihIwquI2o1rsKRrJNhmkYq9DLl+okFufnJfx9ppnoV/vc/utnvaxNcb8TQU/IMOtfhlq8ceHW/zfD0cDF7Z7I4Hfqp02vSpg06se2gzqpxlGTdyeopFca4ocL3HJp/VHZTDik4mOzY34L33ab+7EXwz+wvLND7cEbo20BjK3exOB37KdNqM6YDOoH2YY1U+dabp4QaZJLhzZK9F3q2UkGpCJDU/70Ks77TcMvl+GWnyJwYjvyVBL4J3t3jzgTbDTZlQHMoyah9lm/dOKPc74pfPl0vPxORmLhX6d035TwV9YEV98sMU/NRDm8g94VXbaU7UBl8X48ESJ6+kn9Ud+Hgh7EuPtoVdz2rdtJvQvDv5gxLewvH8ciHg7hloClu3eNOBNstNtSw34jxc9bH2nenaoxTc33h6aH4uF4uPtwcR48n/u/RNO+80G3ydDEd//DIR99wbCvsbt3izgTbTzaqgy0PPxufBINBAbbw89Go+FZsdjobnx9tDcaCw4P9oWjI/FgomxWCAx+gpO++G1xvxVwR+M+GQw7P1xMOx7PBj29fZHvFXbvVHAm2rn4prsrKkd6wiFR9tDsfH2mthILPRorC04O9YWmhuNheZG2wLzI9FgfLQtkBiNBhLPhf4XnPaLayDik4GwTwbC3v8daPY+HIj4Pupv9jL+A7+CncvXeHtN7WgsGB6NhWKjsVBsJBp8NBoNzo5EA3MLa364NRAfafUnhpPr5U77lcGXgbD37wNhz5/7m70jA2HPmW3eE+D/rZWF0BasHW4LhkeigdhILBQbbg08Gm4NzA63+OeGW/xzQ63++aEWf3yoxZdIrmWhb3k+9INLoV8KvvQ3e+MDzd4f+ps9/9Ef9rYNRHyObd4DAAtWFMJoW7B2uDUYHooGYkPRQGyoxf9oqMU3OxTxzQ1FfHNDLb75oYgvPhjxJpZWeO3gJ8PvSfQ3eX8aCHtn+5u9M33NXP4Br7MVhTDcGqgdbvWHB1v9scFWf2ww4n80GPHNDoa9c4MR39xg2Ds3EPbOD4S98YGwJzEQ9iT6m73S3+yVvmbPfH+zZ76vyfO0v9n7p75mb29/M5d/wG/Jc4Uw1OIP90f8scGIP9Yf8ccGwr5HA2Hv7ECzd26g2TvXlwx9vK/Z821/s+e/+po83/Y3eT7ra/Y0cfkH/LbtXL2GWny1A2FfuC/sjfWHvbH+Zs+jvrD3Zm+TZ6i3yTPW1+yZ7GvyXO9r9vi3908H8M+wohB6m7xlt695Tw6EfecGw15ff5Pnnb5mT6D32oUD2/x3AvgV7dyxY8fOgSavu7/Jk9V3zave7j8IAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAICV/g9tPJEQu1XvmQAAAABJRU5ErkJggg==">
-<img id="i2" src="http://localhost:8000/resources/square128.png">
-
-</body></html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html
deleted file mode 100644
index 1df8803..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html
+++ /dev/null
@@ -1,164 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-<link rel="stylesheet" type="text/css" href="../unit.css" />
-<script type="application/x-javascript" src="../unit.js"></script>
-<script type="application/x-javascript" src="../util.js"></script>
-<script type="application/x-javascript">
-
-Tests.startUnit = function () {
-    var canvas = document.getElementById('gl');
-    var gl = wrapGLContext(getGLContext(canvas));
-    gl.viewport(0,0,canvas.width,canvas.height);
-    gl.clearColor(0,0,1,1);
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    gl.disable(gl.DEPTH_TEST);
-    return [gl];
-}
-
-Tests.setup = function(gl) {
-    var tex = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, tex);
-    var texCubeMap = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_CUBE_MAP, texCubeMap);
-    return [gl]
-}
-
-Tests.teardown = function(gl, tex, texCubeMap) {
-    gl.bindTexture(gl.TEXTURE_2D, null);
-    gl.deleteTexture(tex);
-    gl.bindTexture(gl.TEXTURE_CUBE_MAP, null);
-    gl.deleteTexture(texCubeMap);
-}
-
-Tests.testTexImage2D = function(gl) {
-    gl.enable(gl.BLEND);
-    var img = document.getElementById('i');
-    var c = document.getElementById('c');
-    var ctx = c.getContext('2d');
-    ctx.drawImage(img,0,0);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, img);
-    gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, img);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-    var f = new Filter(gl, 'identity-flip-vert', 'identity-frag');
-    gl.blendFunc(gl.ONE, gl.ZERO);
-    f.apply();
-    f.destroy();
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);
-    gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-    f = new Filter(gl, 'identity-hflip-vert', 'identity-frag');
-    gl.blendFunc(gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA);
-    f.apply();
-    f.destroy();
-    var valid_targets = [
-        gl.TEXTURE_2D,
-        gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-        gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-        gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-        gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-        gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-        gl.TEXTURE_CUBE_MAP_NEGATIVE_Z
-    ];
-    valid_targets.forEach(function(t) {
-        assertOk(function(){
-                gl.texImage2D(t, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);
-                gl.texSubImage2D(t, 0, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-        });
-        assertOk(function(){
-                gl.texImage2D(t, 1, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);
-                gl.texSubImage2D(t, 1, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-        });
-    });
-}
-
-Tests.testTexImage2DNonSOP = function(gl) {
-    var img = document.getElementById('i2');
-    while (!img.complete) {}
-    var c = document.getElementById('c');
-    var ctx = c.getContext('2d');
-    ctx.drawImage(img,0,0);
-    assertThrowNoGLError(gl, "texImage2D with cross-origin image should throw exception.",
-      function(){gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, img);});
-    assertThrowNoGLError(gl, "texSubImage2D with cross-origin image should throw exception.",
-      function(){gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGBA, gl.UNSIGNED_BYTE, img);});
-    assertThrowNoGLError(gl, "texImage2D with dirty origin canvas should throw exception.",
-      function(){gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);});
-    assertThrowNoGLError(gl, "texSubImage2D with dirty origin canvas should throw exception.",
-      function(){gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGBA, gl.UNSIGNED_BYTE, c);});
-}
-
-Tests.endUnit = function(gl) {
-}
-
-</script>
-<script id="identity-flip-vert" type="x-shader/x-vertex">
-attribute vec3 Vertex;
-attribute vec2 Tex;
-
-varying vec4 texCoord0;
-void main()
-{
-    texCoord0 = vec4(Tex.s, 1.0-Tex.t, 0.0, 0.0);
-    gl_Position = vec4(Vertex, 1.0);
-}
-</script>
-<script id="identity-hflip-vert" type="x-shader/x-vertex">
-attribute vec3 Vertex;
-attribute vec2 Tex;
-
-varying vec4 texCoord0;
-void main()
-{
-    texCoord0 = vec4(1.0-Tex.s, Tex.t, 0.0, 0.0);
-    gl_Position = vec4(Vertex, 1.0);
-}
-</script>
-<script id="identity-frag" type="x-shader/x-fragment">
-precision mediump float;
-
-uniform sampler2D Texture;
-
-varying vec4 texCoord0;
-void main()
-{
-    vec4 c = texture2D(Texture, texCoord0.st);
-    gl_FragColor = c;
-}
-</script>
-</head><body>
-<canvas id="gl" width="256" height="256"></canvas>
-<canvas id="c" width="256" height="256"></canvas>
-<img id="i" width="256" height="256"  src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAAEACAYAAABccqhmAAATVElEQVR4nO3d+VPUd57Hcf2b9k9Y+z44+qK7OZoGFVA5VfBGzah9cxpNzGEOoRua5lBEue/DK4fZ7MapmSm3Mlshu8xOdCpDJt3v/aEBAUHAOMG4z0fV53fqU/V6fd7fT/e32bEDAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwOvBkar7l+3+GwBsk8xUrT0rTb8vx2Q45janlu7YsWPnsgXgTeYwak85U3Xv5ZiM3+XbUh/l2dICBc6080WZ1ur92baSHRQB8GayGdUWu1HzoSNFO+ZM1f2cbTLM51lT5woc5rkDObbZ/Vm2SEm23VvsyjhV5nJQBsCbxGZQVtmN6p4Mo/YPdqNGHKlayUrXJ9zWlESh0xIvzsmYL3HZ54pzMm6VuRyRMpfTW+pyUAbAm8BmVNVnGNTTdqP6vzOMGrGnaMSZqpNsk17ybKlS6DTL/ixbotRlj5flOubL3I65MpfjVrnbEalYKINSl335vQGA3wKbUW2xGdWRDKP66wyjWhYLwJGiFWeaTrJNBnFbU2SP3ST7s6xSmmuXcrczUe52xstzHfPlbsdcudt5qyzX3lKWlxkszXGeK8mxnyzJySjeQRkArzebQVllM6p7bUb149UF4EjVSmaaTrLS9eKypMgee7ocyLZJmdshFXmZUpHnXFEGB/OzJsrdjqEyt/NmWa49XJbt9Ja6Mk4Vu7hEBF5LNr2q3mZQz9gM6u9XFEBqsgCcaTrJXJgEci0pstdhkv3ZNinNTZbAofwsOZSfJQfzMqU8z5kodzsSZbmOeIXb+XW52zFa5nLcKnPZI2ULl4jFfKIAvB7MOrXFZlBHbAb11zaj+kmGUbNuAWSm65dKYHdGmhRlWqQ8zyFHCnLk+L5cOV6UK0cKXVK5J1sO5mdKhdspZavKoDTX0VPiciTLIHtFGVAIwK/NYlBW2fTqXptB/dhmSJ7+LyqArHS95JiTJVDgNEllQZZ4KgulrrpU6qtLJXBsv5wt3yMn9rvlaIFLDi8vg1xH4mB+5p+Wl0Fpjr2lJMcRLM6ynyvOzjhxIIt7A+BXY9Gr6q0L4/9SAaRoxL7w/L9WAWSbDJJrTZFid4Z4jxZJU/1xufHhOem+ek6il0/LB74qaTxTJoGj++Vs2R45vj9XjhTkyOHdC48JC2VwaHfmnyrczn+vcDsmynLtQyU5GTeLczLCpTk2T3GW7VhxVsae7d4f4I1l1qktVoM6YjOovrYa1D8sFoB9WQE415kA8u1pcvRAjnwUOiLDLQG5190o9242ylRHnQyG/XLz6nmJXqqWD3yV0nC6VPxH98nZst1yfF+uHC10SdXebDmUnyyDqoLs7w7lZ35b7nb8scxt/7dSl32kJCejqyQn40pJTkbZDiYC4NWzaJVVVr2q12ZQPbYa1H9fuwB0SwWQla6XLFOyAAoyTfLW4T3SfuWM3L3RIA/7L8vD/svyZe8l+ezW23Kvu1EmO2ploNkn3VfPSevb1fK+t1Iaz5RJ7cli8R0pktOl+XKsKFkGBxfKoHJv1l8P5mf+uSLP8fvyXMdMmdsRKXc5qotdGQXbvV/AG8WiV9Vb9aoZq141azOoxWbcXAHkWlOkJC9Dak8Xy61PL8iDnotLBbBUBH2X5Yvbl+RBz0W5e6NBJtprpL/ZJzc/Oi/XP3hLWi6ekvc8h6WuukS8Vc/KYPEC8WhhzpOqguzvKvdmfXV4d2b3wfzM9w/lZTENAK+CWaewWHWqiE2v+tqqV/2w2QLINhkkP2Nh/K89ImNtIfmi99Kz8Pcl15dL65J80XtJPr/1tty/2Sh3uxvkzvV6GY+FpO+aV65/8DuJXDwpVzyHpO7UQhmU5MvRIpdU7c2RQ7uz5MR+9x+OFbnuHi3MiVQVuKoP784u2u79A37TLFpllVWn6rXqVY+tetWPGxbAsgvAvU6TvHVot8SunJY7N+rly761g/9lb3J9sWx9fvuSfH77bXnQc1HudTfITFedjLWFpPeaR7o+eEvCjSflyoVDUlddKsHjB+TC4UI5VZwnVQU5ibcq9nx1ujS/58QB99XqYnf5DqYB4OVYdM/Gf6te9Y/k8//GBeCyGKXEnSE11Qek55Pzcv9m48rQrxP8L25fki9uvy2fr1qf3bqYnAxuNMh0Z52MRINy+1OPXP/wd9J+5Yw015+Qd84flJqTxXLhcIGcLM77+UhBzt8uVBa2nqvce/ZsxZ6y7d5L4Ddlcfy36FVfW/SqH6wGlawugMWvATvTlhWAySB5GalydH+OfFRzREajQfn81tvrh/6FwV9cF+WzWxflwa2Lcr/notzrbpSZ6/Uy1VUnkx21MtwSkJ5PLkjHe2elqf64XD53UEInDiQuHC6Yry7Omz1W5HrY+FbF4R1MA8DmWLTKKsuy8d9qUL+wAJZ/C3CPM13OHtwtbe+elunr9fLFusF/PvSf31o7+A96nq37PRflfk+j3L+Z/Fjx7o0Gme6qk4n2Ghlq8UvPx+el/coZuVZ3XC6fq/i57lTx32pOHngUOlUc/jR4lEtCYCMWnareolfNWPSqWatB9dOaBbDGl4BcFqMUu20SOnVAbn58Tu52N27qtP98g9A/WAz9QvAX173FEuhukLvdDcnJoLNWxmM1Mhjxy82Pzknn+2cSsXdPz4cbT8x+GKh8+FHwSO0OSgBYm1mnsJh1qohFr1wY/5XxZwWw/teAs9KTvwtwZH+2XA1VyXBrUB70XFz/tF9nzN9K8O91N8i9hfAvrjs3GuTOjXqZXnhEGG+vkdFoUAbD/p97Pj7/t56r57/pu+b5pOXd6qPbvdfAa8ei3VVl0al6LXrlY4tO+aNFr0pstgD2ONLlzMHdEn2nWqY66+SzlxzzHywb858L/TrBv3vjWfgX18z15JruqpOpzlqZaA8lxmKhv49Gg3/oD/s+3u69Bl47Fp2i3qJVzVh0ylmrTvmTVZ+8AFz5HsDzBZBjNkpxrk2Cpw5I90fn5M6Nhhee9lsOfvfmg3/n+rPwz1yvk5muOpleWJMdtfHJjprvJjtqKABgueT4r4iYdcqvzbpdP1j0yvjqArCv9SJQul7ctlSp2pctHwYrZaglIPdvNq5/2r/gYm9Twb+x9eBPd9XJVHISmJ/qrP1murOGRwBgOZN2V5VFp+y1aBfGf50ysVQAa3wHYLEAstL1stuRLqcr8qX18imZ7KiVBz0XXxj6jZ/vNxn86xsHP/kIUCdTnXXx6c7av0x11PRs914Drx2TTlFv0ipmzDrlrEWn/MmiV8lmCiDbbJADuTYJntwvN67+Tmau1ydDvmbot36x9yz49S8Z/NrFNT/dVfv7qc66k9u918BrxaxePf4r4hsVgHPh9wBzrSlSVZQtHwQqZTDil7vdjVs77bcY/JmtB1+mOmsTkx21T6a6ake2e6+B145Ju6vKpFP2mrTKx2bts/F/8VuALyqA3fY0OV2eLy2XTspEe43cf8Gz/TYEXyY7amWyoyY+1VHz/VRnXfN27zXw2lka/7XKWYtW+ZNFp5TNFEC2ySD7XVYJnNgnXR++JdNddZs+7X+d4NfKZEeNTHbUzE921Dya5PIPWClNrbCYtcnx36Td9YNZp4hbdKqNC2Bh/K8szJL3/YdlIOyTOzcatvwx3sY3+r8o+DLZEUpMtNc8mehg/AeeY1LvqjJplb0mjeKxWav40axVJlYXwFpvAmam6STfnibVZXkSefukjMVCcrd7EyP+eqf9loJfu2HwJzpqZKK9RsbbQ/HJ9tD3k501jP/AaiaNot6kSY7/Zq3iJ7NOKYsXgC8qgCyTQfblWMV/fJ90fnBWJjtrV4z3Wzntn7vRv/586Lca/GcrND/RHno02c74D6yQplZYTFpFxKRVLI3/Kwvg+ReB7CnJ3wFwWVLkcGGWvOc/LP3NXpm5Xv/LT/tNBn9yE8EfT4Y/MR4LPRlvDzH+A6uZNYpKk3ZXb/rC+G/SKhKbLYC8jDQ5VZYn4YsnZLQtKHdubC70mx3zf0nwx9tDMh4LyVgsFB+PBb8fb2f8B56TrlHUp2sV0yaNYmn830wBZKXrZV+2RXzH90nH+2dloqMmWQCv4LR/+eCHloK/EH4ZjwXnx2PBR2PtQcZ/YDmTRpmarlY0mTS7vkrTKP5q0ip+NuuUYtmgABypWnFZjHKoIFOueA9JX5NHprvqNh36zZ72vyT4C+FPjLYFn4zHgoz/wGomza7d6ZpdMZNG8Y1Jo3hi1i48/2+iAPIyUuVkqVuaGk/ISDQoM9df3Wm/Mvg1Ww7+WCwkY21BGW0Lxkfbgt+PxUKM/8BqaZpdu9PUiiaTRvGVSav4y9InABsUQGa6XoqyLeI9ViTt752R8fbQqsC/4tN+i8EfawvKaDQoI9HA/Ghb8JuxKOM/8ByT5l9T09SKQLpGMWTSKv7TrFU8NeuUieUFYFv1YyCOVK3kmJPj/7veg9J7zSNTnbWv6LR/BcFfWCPRQHwkGvjLSDTAm3/AetLVyjyTRvmOSauYNOsU35p1yn9sVABuW6qcLM2Vaw3HZbg1INNdr+a0X/sz/K0FfzQalNFoIHn6RwO/H2kL8uYf8CImza5Ck27Xe2atcsqiU8bXLYAUjWSm66QwyyzeY4USu3JaxmKhtUP/i0/7mhWhXxH8tvWCH5SRaEBGo4HESKv/yWhrgMs/YDPSdcois1bxvkWnfGrRK+NrFYA9RSvZZoMc3OuUdzwH5fa1CzLRUfNPPe3H1zjt1wv+4hpuDcRHooHvR6IBLv+AzTLrlEVmnfKhRad8al3z58C04ralyImSXLnWcEyGWv0y2VkrU13Ph/6lTvsNgj+6QfBHWgMy3BqQ4Vb//HBr4NFI1M/lH7AVFr0qYNGrHlr1qqc2gyq+/E1AZ5pOCrNM4jlaIG1XTstoW/Cfd9q/VPADMtzqTwy3+J8MM/4DL2XnihIwquI2o1rsKRrJNhmkYq9DLl+okFufnJfx9ppnoV/vc/utnvaxNcb8TQU/IMOtfhlq8ceHW/zfD0cDF7Z7I4Hfqp02vSpg06se2gzqpxlGTdyeopFca4ocL3HJp/VHZTDik4mOzY34L33ab+7EXwz+wvLND7cEbo20BjK3exOB37KdNqM6YDOoH2YY1U+dabp4QaZJLhzZK9F3q2UkGpCJDU/70Ks77TcMvl+GWnyJwYjvyVBL4J3t3jzgTbDTZlQHMoyah9lm/dOKPc74pfPl0vPxORmLhX6d035TwV9YEV98sMU/NRDm8g94VXbaU7UBl8X48ESJ6+kn9Ud+Hgh7EuPtoVdz2rdtJvQvDv5gxLewvH8ciHg7hloClu3eNOBNstNtSw34jxc9bH2nenaoxTc33h6aH4uF4uPtwcR48n/u/RNO+80G3ydDEd//DIR99wbCvsbt3izgTbTzaqgy0PPxufBINBAbbw89Go+FZsdjobnx9tDcaCw4P9oWjI/FgomxWCAx+gpO++G1xvxVwR+M+GQw7P1xMOx7PBj29fZHvFXbvVHAm2rn4prsrKkd6wiFR9tDsfH2mthILPRorC04O9YWmhuNheZG2wLzI9FgfLQtkBiNBhLPhf4XnPaLayDik4GwTwbC3v8daPY+HIj4Pupv9jL+A7+CncvXeHtN7WgsGB6NhWKjsVBsJBp8NBoNzo5EA3MLa364NRAfafUnhpPr5U77lcGXgbD37wNhz5/7m70jA2HPmW3eE+D/rZWF0BasHW4LhkeigdhILBQbbg08Gm4NzA63+OeGW/xzQ63++aEWf3yoxZdIrmWhb3k+9INLoV8KvvQ3e+MDzd4f+ps9/9Ef9rYNRHyObd4DAAtWFMJoW7B2uDUYHooGYkPRQGyoxf9oqMU3OxTxzQ1FfHNDLb75oYgvPhjxJpZWeO3gJ8PvSfQ3eX8aCHtn+5u9M33NXP4Br7MVhTDcGqgdbvWHB1v9scFWf2ww4n80GPHNDoa9c4MR39xg2Ds3EPbOD4S98YGwJzEQ9iT6m73S3+yVvmbPfH+zZ76vyfO0v9n7p75mb29/M5d/wG/Jc4Uw1OIP90f8scGIP9Yf8ccGwr5HA2Hv7ECzd26g2TvXlwx9vK/Z821/s+e/+po83/Y3eT7ra/Y0cfkH/LbtXL2GWny1A2FfuC/sjfWHvbH+Zs+jvrD3Zm+TZ6i3yTPW1+yZ7GvyXO9r9vi3908H8M+wohB6m7xlt695Tw6EfecGw15ff5Pnnb5mT6D32oUD2/x3AvgV7dyxY8fOgSavu7/Jk9V3zave7j8IAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAICV/g9tPJEQu1XvmQAAAABJRU5ErkJggg==">
-<img id="i2" src="http://localhost:8000/resources/square128.png">
-
-</body></html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/3x3.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/3x3.png
deleted file mode 100644
index 6cf1e74..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/3x3.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/blue-1x1.jpg b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/blue-1x1.jpg
deleted file mode 100644
index a70bbb0..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/blue-1x1.jpg
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/bug-32888-texture.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/bug-32888-texture.png
deleted file mode 100644
index e78cfe7..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/bug-32888-texture.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/floatUniformShader.vert b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/floatUniformShader.vert
deleted file mode 100644
index 58991b4..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/floatUniformShader.vert
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) 2009 The Chromium Authors. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- *    * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *    * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *    * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * AS IS AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-*/
-
-uniform float fval;
-uniform vec2 fval2;
-uniform vec3 fval3;
-uniform vec4 fval4;
-
-void main()
-{
-    float sum = fval
-            + fval2[0] + fval2[1]
-            + fval3[0] + fval3[1] + fval3[2]
-            + fval4[0] + fval4[1] + fval4[2] + fval4[3];
-    gl_Position = vec4(sum, 0.0, 0.0, 1.0);
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/fragmentShader.frag b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/fragmentShader.frag
deleted file mode 100644
index dcedbde..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/fragmentShader.frag
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
-Copyright (C) 2009 Apple Inc.  All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-1. Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-2. Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
-
-THIS SOFTWARE IS PROVIDED BY APPLE INC. AS IS AND ANY
-EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE INC. OR
-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
-EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
-OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-*/
-
-// Workaround for non-compliant WebGL implementations (FIXME)
-varying mediump vec3 v_normal;
-
-void main()
-{
-    gl_FragColor = vec4(v_normal/2.0+vec3(0.5), 1);
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256-with-128-alpha.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256-with-128-alpha.png
deleted file mode 100644
index 183e55d..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256-with-128-alpha.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256.png
deleted file mode 100644
index 01e486b..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-256.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-default-gamma.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-default-gamma.png
deleted file mode 100644
index a5a89be..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-default-gamma.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma0.1.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma0.1.png
deleted file mode 100644
index 637c792..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma0.1.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma1.0.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma1.0.png
deleted file mode 100644
index 40ceeb0..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma1.0.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma2.0.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma2.0.png
deleted file mode 100644
index 73fcf7b..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma2.0.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma4.0.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma4.0.png
deleted file mode 100644
index d878f1e..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma4.0.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma9.0.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma9.0.png
deleted file mode 100644
index 8a69ed1..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp-gamma9.0.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp.png
deleted file mode 100644
index a5a89be..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/gray-ramp.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/green-2x2-16bit.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/green-2x2-16bit.png
deleted file mode 100644
index 7fcb969..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/green-2x2-16bit.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/noopUniformShader.frag b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/noopUniformShader.frag
deleted file mode 100644
index b2dfc9f..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/noopUniformShader.frag
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright (c) 2009 The Chromium Authors. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- *    * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *    * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *    * Neither the name of Google Inc. nor the names of its
- * contributors may be used to endorse or promote products derived from
- * this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * AS IS AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-*/
-
-void main()
-{
-    gl_FragColor = vec4(0.0, 0.0, 0.0, 1.0);
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.mp4 b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.mp4
deleted file mode 100644
index 59f5f77..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.mp4
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.theora.ogv b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.theora.ogv
deleted file mode 100644
index 4458678..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.theora.ogv
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.webmvp8.webm b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.webmvp8.webm
deleted file mode 100644
index 47277bd..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/npot-video.webmvp8.webm
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/pnglib.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/pnglib.js
deleted file mode 100644
index d2a9b99..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/pnglib.js
+++ /dev/null
@@ -1,207 +0,0 @@
-/**
-* A handy class to calculate color values.
-*
-* @version 1.0
-* @author Robert Eisele <robert@xarg.org>
-* @copyright Copyright (c) 2010, Robert Eisele
-* @link http://www.xarg.org/2010/03/generate-client-side-png-files-using-javascript/
-* @license http://www.opensource.org/licenses/bsd-license.php BSD License
-*
-*/
-
-(function() {
-
-    // helper functions for that ctx
-    function write(buffer, offs) {
-        for (var i = 2; i < arguments.length; i++) {
-            for (var j = 0; j < arguments[i].length; j++) {
-                buffer[offs++] = arguments[i].charAt(j);
-            }
-        }
-    }
-
-    function byte2(w) {
-        return String.fromCharCode((w >> 8) & 255, w & 255);
-    }
-
-    function byte4(w) {
-        return String.fromCharCode((w >> 24) & 255, (w >> 16) & 255, (w >> 8) & 255, w & 255);
-    }
-
-    function byte2lsb(w) {
-        return String.fromCharCode(w & 255, (w >> 8) & 255);
-    }
-
-    window.PNGlib = function(width,height,depth) {
-
-        this.width   = width;
-        this.height  = height;
-        this.depth   = depth;
-
-        // pixel data and row filter identifier size
-        this.pix_size = height * (width + 1);
-
-        // deflate header, pix_size, block headers, adler32 checksum
-        this.data_size = 2 + this.pix_size + 5 * Math.floor((0xfffe + this.pix_size) / 0xffff) + 4;
-
-        // offsets and sizes of Png chunks
-        this.ihdr_offs = 0;                                    // IHDR offset and size
-        this.ihdr_size = 4 + 4 + 13 + 4;
-        this.plte_offs = this.ihdr_offs + this.ihdr_size;    // PLTE offset and size
-        this.plte_size = 4 + 4 + 3 * depth + 4;
-        this.trns_offs = this.plte_offs + this.plte_size;    // tRNS offset and size
-        this.trns_size = 4 + 4 + depth + 4;
-        this.idat_offs = this.trns_offs + this.trns_size;    // IDAT offset and size
-        this.idat_size = 4 + 4 + this.data_size + 4;
-        this.iend_offs = this.idat_offs + this.idat_size;    // IEND offset and size
-        this.iend_size = 4 + 4 + 4;
-        this.buffer_size  = this.iend_offs + this.iend_size;    // total PNG size
-
-        this.buffer  = new Array();
-        this.palette = new Object();
-        this.pindex  = 0;
-
-        var _crc32 = new Array();
-
-        // initialize buffer with zero bytes
-        for (var i = 0; i < this.buffer_size; i++) {
-            this.buffer[i] = "\x00";
-        }
-
-        // initialize non-zero elements
-        write(this.buffer, this.ihdr_offs, byte4(this.ihdr_size - 12), 'IHDR', byte4(width), byte4(height), "\x08\x03");
-        write(this.buffer, this.plte_offs, byte4(this.plte_size - 12), 'PLTE');
-        write(this.buffer, this.trns_offs, byte4(this.trns_size - 12), 'tRNS');
-        write(this.buffer, this.idat_offs, byte4(this.idat_size - 12), 'IDAT');
-        write(this.buffer, this.iend_offs, byte4(this.iend_size - 12), 'IEND');
-
-        // initialize deflate header
-        var header = ((8 + (7 << 4)) << 8) | (3 << 6);
-        header+= 31 - (header % 31);
-
-        write(this.buffer, this.idat_offs + 8, byte2(header));
-
-        // initialize deflate block headers
-        for (var i = 0; (i << 16) - 1 < this.pix_size; i++) {
-            var size, bits;
-            if (i + 0xffff < this.pix_size) {
-                size = 0xffff;
-                bits = "\x00";
-            } else {
-                size = this.pix_size - (i << 16) - i;
-                bits = "\x01";
-            }
-            write(this.buffer, this.idat_offs + 8 + 2 + (i << 16) + (i << 2), bits, byte2lsb(size), byte2lsb(~size));
-        }
-
-        /* Create crc32 lookup table */
-        for (var i = 0; i < 256; i++) {
-            var c = i;
-            for (var j = 0; j < 8; j++) {
-                if (c & 1) {
-                    c = -306674912 ^ ((c >> 1) & 0x7fffffff);
-                } else {
-                    c = (c >> 1) & 0x7fffffff;
-                }
-            }
-            _crc32[i] = c;
-        }
-
-        // compute the index into a png for a given pixel
-        this.index = function(x,y) {
-            var i = y * (this.width + 1) + x + 1;
-            var j = this.idat_offs + 8 + 2 + 5 * Math.floor((i / 0xffff) + 1) + i;
-            return j;
-        }
-
-        // convert a color and build up the palette
-        this.color = function(red, green, blue, alpha) {
-
-            alpha = alpha >= 0 ? alpha : 255;
-            var color = (((((alpha << 8) | red) << 8) | green) << 8) | blue;
-
-            if (typeof this.palette[color] == "undefined") {
-                if (this.pindex == this.depth) return "\x00";
-
-                var ndx = this.plte_offs + 8 + 3 * this.pindex;
-
-                this.buffer[ndx + 0] = String.fromCharCode(red);
-                this.buffer[ndx + 1] = String.fromCharCode(green);
-                this.buffer[ndx + 2] = String.fromCharCode(blue);
-                this.buffer[this.trns_offs+8+this.pindex] = String.fromCharCode(alpha);
-
-                this.palette[color] = String.fromCharCode(this.pindex++);
-            }
-            return this.palette[color];
-        }
-
-        // output a PNG string, Base64 encoded
-        this.getBase64 = function() {
-
-            var s = this.getDump();
-
-            var ch = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
-            var c1, c2, c3, e1, e2, e3, e4;
-            var l = s.length;
-            var i = 0;
-            var r = "";
-
-            do {
-                c1 = s.charCodeAt(i);
-                e1 = c1 >> 2;
-                c2 = s.charCodeAt(i+1);
-                e2 = ((c1 & 3) << 4) | (c2 >> 4);
-                c3 = s.charCodeAt(i+2);
-                if (l < i+2) { e3 = 64; } else { e3 = ((c2 & 0xf) << 2) | (c3 >> 6); }
-                if (l < i+3) { e4 = 64; } else { e4 = c3 & 0x3f; }
-                r+= ch.charAt(e1) + ch.charAt(e2) + ch.charAt(e3) + ch.charAt(e4);
-            } while ((i+= 3) < l);
-            return r;
-        }
-
-        // output a PNG string
-        this.getDump = function() {
-
-            // compute adler32 of output pixels + row filter bytes
-            var BASE = 65521; /* largest prime smaller than 65536 */
-            var NMAX = 5552;  /* NMAX is the largest n such that 255n(n+1)/2 + (n+1)(BASE-1) <= 2^32-1 */
-            var s1 = 1;
-            var s2 = 0;
-            var n = NMAX;
-
-            for (var y = 0; y < this.height; y++) {
-                for (var x = -1; x < this.width; x++) {
-                    s1+= this.buffer[this.index(x, y)].charCodeAt(0);
-                    s2+= s1;
-                    if ((n-= 1) == 0) {
-                        s1%= BASE;
-                        s2%= BASE;
-                        n = NMAX;
-                    }
-                }
-            }
-            s1%= BASE;
-            s2%= BASE;
-            write(this.buffer, this.idat_offs + this.idat_size - 8, byte4((s2 << 16) | s1));
-
-            // compute crc32 of the PNG chunks
-            function crc32(png, offs, size) {
-                var crc = -1;
-                for (var i = 4; i < size-4; i += 1) {
-                    crc = _crc32[(crc ^ png[offs+i].charCodeAt(0)) & 0xff] ^ ((crc >> 8) & 0x00ffffff);
-                }
-                write(png, offs+size-4, byte4(crc ^ -1));
-            }
-
-            crc32(this.buffer, this.ihdr_offs, this.ihdr_size);
-            crc32(this.buffer, this.plte_offs, this.plte_size);
-            crc32(this.buffer, this.trns_offs, this.trns_size);
-            crc32(this.buffer, this.idat_offs, this.idat_size);
-            crc32(this.buffer, this.iend_offs, this.iend_size);
-
-            // convert PNG to string
-            return "\211PNG\r\n\032\n"+this.buffer.join('');
-        }
-    }
-
-})();
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.mp4 b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.mp4
deleted file mode 100644
index 4bd6d59..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.mp4
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.png
deleted file mode 100644
index 605ac9b..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.theora.ogv b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.theora.ogv
deleted file mode 100644
index 1543915..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.theora.ogv
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.webmvp8.webm b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.webmvp8.webm
deleted file mode 100644
index 1d9d603..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-green.webmvp8.webm
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-indexed.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-indexed.png
deleted file mode 100644
index 3188d2d..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/red-indexed.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-cie-rgb-profile.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-cie-rgb-profile.png
deleted file mode 100644
index aa8bf37..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-cie-rgb-profile.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colormatch-profile.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colormatch-profile.png
deleted file mode 100644
index 63454ec..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colormatch-profile.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.jpg b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.jpg
deleted file mode 100644
index a918696..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.jpg
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.png
deleted file mode 100644
index 5922627..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-colorspin-profile.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-e-srgb-profile.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-e-srgb-profile.png
deleted file mode 100644
index 2792b0a..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-e-srgb-profile.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-smpte-c-profile.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-smpte-c-profile.png
deleted file mode 100644
index 2904e89..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-smpte-c-profile.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-srgb-iec61966-2.1-profile.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-srgb-iec61966-2.1-profile.png
deleted file mode 100644
index a0201f1..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/small-square-with-srgb-iec61966-2.1-profile.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-canvas.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-canvas.js
deleted file mode 100644
index 67c79f8..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-canvas.js
+++ /dev/null
@@ -1,221 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
-function generateTest(pixelFormat, pixelType, prologue) {
-    var wtu = WebGLTestUtils;
-    var gl = null;
-    var successfullyParsed = false;
-
-    var init = function()
-    {
-        initTestingHarnessWaitUntilDone();
-
-        description('Verify texImage2D and texSubImage2D code paths taking canvas elements (' + pixelFormat + '/' + pixelType + ')');
-
-        gl = wtu.create3DContext("example");
-
-        if (!prologue(gl)) {
-            finishTest();
-            return;
-        }
-
-        var program = wtu.setupTexturedQuad(gl);
-
-        gl.clearColor(0,0,0,1);
-        gl.clearDepth(1);
-
-        var testCanvas = document.createElement('canvas');
-        runTest(testCanvas);
-        //document.body.appendChild(testCanvas);
-    }
-
-    function setCanvasToRedGreen(ctx) {
-      var width = ctx.canvas.width;
-      var height = ctx.canvas.height;
-      var halfHeight = Math.floor(height / 2);
-      ctx.fillStyle = "#ff0000";
-      ctx.fillRect(0, 0, width, halfHeight);
-      ctx.fillStyle = "#00ff00";
-      ctx.fillRect(0, halfHeight, width, height - halfHeight);
-    }
-
-    function drawTextInCanvas(ctx) {
-      var width = ctx.canvas.width;
-      var height = ctx.canvas.height;
-      ctx.fillStyle = "#ffffff";
-      ctx.fillRect(0, 0, width, height);
-      ctx.font = '20pt Arial';
-      ctx.fillStyle = 'black';
-      ctx.textAlign = "center";
-      ctx.textBaseline = "middle";
-      ctx.fillText("1234567890", width / 2, height / 4);
-    }
-
-    function setCanvasTo257x257(ctx) {
-      ctx.canvas.width = 257;
-      ctx.canvas.height = 257;
-      setCanvasToRedGreen(ctx);
-    }
-
-    function setCanvasTo1x2(ctx) {
-      ctx.canvas.width = 1;
-      ctx.canvas.height = 2;
-      setCanvasToRedGreen(ctx);
-    }
-
-    function runOneIteration(canvas, useTexSubImage2D, flipY, topColor, bottomColor, opt_texture, opt_fontTest)
-    {
-        debug('Testing ' + (useTexSubImage2D ? 'texSubImage2D' : 'texImage2D') +
-              ' with flipY=' + flipY + ' canvas size: ' + canvas.width + 'x' + canvas.height +
-              (opt_fontTest ? " with fonts" : " with red-green"));
-        gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-        // Disable any writes to the alpha channel
-        // No idea why this was here. If it's important put it back and leave a comment as to why
-//        gl.colorMask(1, 1, 1, 0);
-        if (!opt_texture) {
-            var texture = gl.createTexture();
-            // Bind the texture to texture unit 0
-            gl.bindTexture(gl.TEXTURE_2D, texture);
-            // Set up texture parameters
-            gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-            gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-            gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-            gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-        } else {
-            var texture = opt_texture;
-        }
-        // Set up pixel store parameters
-        gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, flipY);
-        gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, false);
-        gl.pixelStorei(gl.UNPACK_COLORSPACE_CONVERSION_WEBGL, gl.NONE);
-        // Upload the image into the texture
-        if (useTexSubImage2D) {
-            // Initialize the texture to black first
-            gl.texImage2D(gl.TEXTURE_2D, 0, gl[pixelFormat], canvas.width, canvas.height, 0,
-                          gl[pixelFormat], gl[pixelType], null);
-            gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl[pixelFormat], gl[pixelType], canvas);
-        } else {
-            gl.texImage2D(gl.TEXTURE_2D, 0, gl[pixelFormat], gl[pixelFormat], gl[pixelType], canvas);
-        }
-
-        // Draw the triangles
-        wtu.drawQuad(gl, [0, 255, 0, 255]);
-
-        if (opt_fontTest) {
-            var width = gl.canvas.width;
-            var height = gl.canvas.height;
-            var halfHeight = Math.floor(height / 2);
-            var top = flipY ? 0 : (height - halfHeight);
-            var bottom = flipY ? (height - halfHeight) : 0;
-            // check half is a solid color.
-            wtu.checkCanvasRect(
-                  gl, 0, top, width, halfHeight,
-                  [255, 255, 255, 255],
-                  "should be white");
-            // check other half is not a solid color.
-            wtu.checkCanvasRectColor(
-                  gl, 0, bottom, width, halfHeight,
-                  [255, 255, 255, 255], 0,
-                  function() {
-                    testFailed("font missing");
-                  },
-                  function() {
-                    testPassed("font renderered");
-                  },
-                  debug);
-        } else {
-            // Check a few pixels near the top and bottom and make sure they have
-            // the right color.
-            var width = gl.canvas.width;
-            var height = gl.canvas.height;
-            var halfHeight = Math.floor(height / 2);
-            debug("Checking bottom");
-            wtu.checkCanvasRect(gl, 0, 0, width, halfHeight, bottomColor,
-                                "shouldBe " + bottomColor);
-            debug("Checking top");
-            wtu.checkCanvasRect(gl, 0, height - halfHeight, width, halfHeight, topColor,
-                                "shouldBe " + topColor);
-        }
-
-        if (false) {
-          var m = new Image();
-          m.src = gl.canvas.toDataURL();
-          document.getElementById("console").appendChild(m);
-          document.getElementById("console").appendChild(document.createElement("hr"));
-        }
-
-        return texture;
-    }
-
-    function runTest(canvas)
-    {
-        var ctx = canvas.getContext("2d");
-        var red = [255, 0, 0];
-        var green = [0, 255, 0];
-
-        var count = 4;
-        var caseNdx = 0;
-
-        var cases = [
-            { sub: false, flipY: true,  top: red,   bottom: green, font: false, init: setCanvasTo1x2 },
-            { sub: false, flipY: false, top: green, bottom: red,   font: false },
-            { sub: true,  flipY: true,  top: red,   bottom: green, font: false },
-            { sub: true,  flipY: false, top: green, bottom: red,   font: false },
-            { sub: false, flipY: true,  top: red,   bottom: green, font: false, init: setCanvasTo257x257 },
-            { sub: false, flipY: false, top: green, bottom: red,   font: false },
-            { sub: true,  flipY: true,  top: red,   bottom: green, font: false },
-            { sub: true,  flipY: false, top: green, bottom: red,   font: false },
-            { sub: false, flipY: true,  top: red,   bottom: green, font: true, init: drawTextInCanvas },
-            { sub: false, flipY: false, top: green, bottom: red,   font: true },
-            { sub: true,  flipY: true,  top: red,   bottom: green, font: true },
-            { sub: true,  flipY: false, top: green, bottom: red,   font: true },
-        ];
-
-        var texture;
-        function runNextTest() {
-            var c = cases[caseNdx];
-            if (c.init) {
-              c.init(ctx);
-            }
-            texture = runOneIteration(canvas, c.sub, c.flipY, c.top, c.bottom, texture, c.font);
-            // for the first 2 iterations always make a new texture.
-            if (count > 2) {
-              texture = undefined;
-            }
-            ++caseNdx;
-            if (caseNdx == cases.length) {
-                caseNdx = 0;
-                --count;
-                if (!count) {
-                    glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-                    finishTest();
-                    return;
-                }
-            }
-            wtu.waitForComposite(gl, runNextTest);
-        }
-        runNextTest();
-    }
-
-    return init;
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image-data.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image-data.js
deleted file mode 100644
index 8f96a92..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image-data.js
+++ /dev/null
@@ -1,135 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
-function generateTest(pixelFormat, pixelType, prologue) {
-    var wtu = WebGLTestUtils;
-    var gl = null;
-    var textureLoc = null;
-    var successfullyParsed = false;
-    var imageData = null;
-
-    var init = function()
-    {
-        initTestingHarnessWaitUntilDone();
-
-        description('Verify texImage2D and texSubImage2D code paths taking ImageData (' + pixelFormat + '/' + pixelType + ')');
-
-        gl = wtu.create3DContext("example");
-
-        if (!prologue(gl)) {
-            finishTest();
-            return;
-        }
-
-        var program = wtu.setupTexturedQuad(gl);
-        gl.clearColor(0,0,0,1);
-        gl.clearDepth(1);
-        gl.disable(gl.BLEND);
-
-        textureLoc = gl.getUniformLocation(program, "tex");
-
-        var canvas2d = document.getElementById("texcanvas");
-        var context2d = canvas2d.getContext("2d");
-        imageData = context2d.createImageData(1, 2);
-        var data = imageData.data;
-        data[0] = 255;
-        data[1] = 0;
-        data[2] = 0;
-        data[3] = 255;
-        data[4] = 0;
-        data[5] = 255;
-        data[6] = 0;
-        data[7] = 0;
-
-        runTest();
-    }
-
-    function runOneIteration(useTexSubImage2D, flipY, premultiplyAlpha, topColor, bottomColor)
-    {
-        debug('Testing ' + (useTexSubImage2D ? 'texSubImage2D' : 'texImage2D') +
-              ' with flipY=' + flipY + ' and premultiplyAlpha=' + premultiplyAlpha);
-        gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-        // Enable writes to the RGBA channels
-        gl.colorMask(1, 1, 1, 0);
-        var texture = gl.createTexture();
-        // Bind the texture to texture unit 0
-        gl.bindTexture(gl.TEXTURE_2D, texture);
-        // Set up texture parameters
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-        // Set up pixel store parameters
-        gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, flipY);
-        gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, premultiplyAlpha);
-        // Upload the image into the texture
-        if (useTexSubImage2D) {
-            // Initialize the texture to black first
-            gl.texImage2D(gl.TEXTURE_2D, 0, gl[pixelFormat], 1, 2, 0,
-                          gl[pixelFormat], gl[pixelType], null);
-            gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl[pixelFormat], gl[pixelType], imageData);
-        } else {
-            gl.texImage2D(gl.TEXTURE_2D, 0, gl[pixelFormat], gl[pixelFormat], gl[pixelType], imageData);
-        }
-
-        // Point the uniform sampler to texture unit 0
-        gl.uniform1i(textureLoc, 0);
-        // Draw the triangles
-        wtu.drawQuad(gl, [0, 0, 0, 255]);
-
-        // Check the top pixel and bottom pixel and make sure they have
-        // the right color.
-        debug("Checking bottom pixel");
-        wtu.checkCanvasRect(gl, 0, 0, 1, 1, bottomColor, "shouldBe " + bottomColor);
-        debug("Checking top pixel");
-        wtu.checkCanvasRect(gl, 0, 1, 1, 1, topColor, "shouldBe " + topColor);
-    }
-
-    function runTest()
-    {
-        var red = [255, 0, 0, 255];
-        var green = [0, 255, 0, 255];
-        var redPremultiplyAlpha = [255, 0, 0, 255];
-        var greenPremultiplyAlpha = [0, 0, 0, 255];
-
-        runOneIteration(false, true, false,
-                        red, green);
-        runOneIteration(false, false, false,
-                        green, red);
-        runOneIteration(false, true, true,
-                        redPremultiplyAlpha, greenPremultiplyAlpha);
-        runOneIteration(false, false, true,
-                        greenPremultiplyAlpha, redPremultiplyAlpha);
-        runOneIteration(true, true, false,
-                        red, green);
-        runOneIteration(true, false, false,
-                        green, red);
-        runOneIteration(true, true, true,
-                        redPremultiplyAlpha, greenPremultiplyAlpha);
-        runOneIteration(true, false, true,
-                        greenPremultiplyAlpha, redPremultiplyAlpha);
-
-        glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-        finishTest();
-    }
-
-    return init;
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image.js
deleted file mode 100644
index 01488f3..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-image.js
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
-function generateTest(pixelFormat, pixelType, pathToTestRoot, prologue) {
-    var wtu = WebGLTestUtils;
-    var gl = null;
-    var textureLoc = null;
-    var successfullyParsed = false;
-    var imgCanvas;
-    var red = [255, 0, 0];
-    var green = [0, 255, 0];
-
-    var init = function()
-    {
-        initTestingHarnessWaitUntilDone();
-
-        description('Verify texImage2D and texSubImage2D code paths taking image elements (' + pixelFormat + '/' + pixelType + ')');
-
-        gl = wtu.create3DContext("example");
-
-        if (!prologue(gl)) {
-            finishTest();
-            return;
-        }
-
-        var program = wtu.setupTexturedQuad(gl);
-
-        gl.clearColor(0,0,0,1);
-        gl.clearDepth(1);
-
-        textureLoc = gl.getUniformLocation(program, "tex");
-
-        wtu.loadTexture(gl, pathToTestRoot + "/resources/red-green.png", runTest);
-    }
-
-    function runOneIteration(image, useTexSubImage2D, flipY, topColor, bottomColor)
-    {
-        debug('Testing ' + (useTexSubImage2D ? 'texSubImage2D' : 'texImage2D') +
-              ' with flipY=' + flipY);
-        gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-        // Disable any writes to the alpha channel
-        gl.colorMask(1, 1, 1, 0);
-        var texture = gl.createTexture();
-        // Bind the texture to texture unit 0
-        gl.bindTexture(gl.TEXTURE_2D, texture);
-        // Set up texture parameters
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-        // Set up pixel store parameters
-        gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, flipY);
-        gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, false);
-        gl.pixelStorei(gl.UNPACK_COLORSPACE_CONVERSION_WEBGL, gl.NONE);
-        // Upload the image into the texture
-        if (useTexSubImage2D) {
-            // Initialize the texture to black first
-            gl.texImage2D(gl.TEXTURE_2D, 0, gl[pixelFormat], image.width, image.height, 0,
-                          gl[pixelFormat], gl[pixelType], null);
-            gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl[pixelFormat], gl[pixelType], image);
-        } else {
-            gl.texImage2D(gl.TEXTURE_2D, 0, gl[pixelFormat], gl[pixelFormat], gl[pixelType], image);
-        }
-
-        // Point the uniform sampler to texture unit 0
-        gl.uniform1i(textureLoc, 0);
-        // Draw the triangles
-        wtu.drawQuad(gl, [0, 0, 0, 255]);
-        // Check a few pixels near the top and bottom and make sure they have
-        // the right color.
-        debug("Checking lower left corner");
-        wtu.checkCanvasRect(gl, 4, 4, 2, 2, bottomColor,
-                            "shouldBe " + bottomColor);
-        debug("Checking upper left corner");
-        wtu.checkCanvasRect(gl, 4, gl.canvas.height - 8, 2, 2, topColor,
-                            "shouldBe " + topColor);
-    }
-
-    function runTestOnImage(image) {
-        runOneIteration(image, false, true, red, green);
-        runOneIteration(image, false, false, green, red);
-        runOneIteration(image, true, true, red, green);
-        runOneIteration(image, true, false, green, red);
-    }
-
-    function runTest(image)
-    {
-        runTestOnImage(image);
-
-        imgCanvas = document.createElement("canvas");
-        imgCanvas.width = 1;
-        imgCanvas.height = 2;
-        var imgCtx = imgCanvas.getContext("2d");
-        var imgData = imgCtx.createImageData(1, 2);
-        imgData.data[0] = red[0];
-        imgData.data[1] = red[1];
-        imgData.data[2] = red[2];
-        imgData.data[3] = 255;
-        imgData.data[4] = green[0];
-        imgData.data[5] = green[1];
-        imgData.data[6] = green[2];
-        imgData.data[7] = 255;
-        imgCtx.putImageData(imgData, 0, 0);
-
-        // apparently Image is different than <img>.
-        var newImage =  new Image();
-        newImage.onload = function() {
-            runTest2(newImage);
-        };
-        newImage.src = imgCanvas.toDataURL();
-    }
-
-    function runTest2(image) {
-        runTestOnImage(image);
-
-        var newImage = document.createElement("img");
-        newImage.onload = function() {
-            runTest3(newImage);
-        };
-        newImage.src = imgCanvas.toDataURL();
-    }
-
-    function runTest3(image) {
-        runTestOnImage(image);
-
-        glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-        finishTest();
-    }
-
-    return init;
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-video.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-video.js
deleted file mode 100644
index dffba59..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/tex-image-and-sub-image-2d-with-video.js
+++ /dev/null
@@ -1,169 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
-// 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
-initTestingHarnessWaitUntilDone();
-
-var old = debug;
-var debug = function(msg) {
-  console.log(msg);
-  old(msg);
-};
-
-function generateTest(pixelFormat, pixelType, prologue) {
-    var wtu = WebGLTestUtils;
-    var gl = null;
-    var textureLoc = null;
-    var successfullyParsed = false;
-
-    // Test each format separately because many browsers implement each
-    // differently. Some might be GPU accelerated, some might not. Etc...
-    var videos = [
-      { src: "../resources/red-green.mp4"         , type: 'video/mp4; codecs="avc1.42E01E, mp4a.40.2"', },
-      { src: "../resources/red-green.webmvp8.webm", type: 'video/webm; codecs="vp8, vorbis"',           },
-      { src: "../resources/red-green.theora.ogv",   type: 'video/ogg; codecs="theora, vorbis"',         },
-    ];
-
-    var videoNdx = 0;
-    var video;
-    var runNextVideo = function() {
-        if (videoNdx == videos.length) {
-            video.removeEventListener("playing", runTest);
-            finishTest();
-            return;
-        }
-        var info = videos[videoNdx++];
-        debug("");
-        debug("testing: " + info.type);
-        video = document.createElement("video");
-        var canPlay = true;
-        if (!video.canPlayType) {
-          testFailed("video.canPlayType required method missing");
-          runNextTest();
-          return;
-        }
-
-        if(!video.canPlayType(info.type).replace(/no/, '')) {
-          debug(info.type + " unsupported");
-          runNextVideo();
-          return;
-        };
-
-        document.body.appendChild(video);
-        video.addEventListener(
-            "playing", function() { runTest(video); }, true);
-        video.type = info.type;
-        video.src = info.src;
-        video.loop = true;
-        video.play();
-    }
-
-    var init = function()
-    {
-        description('Verify texImage2D and texSubImage2D code paths taking video elements (' + pixelFormat + '/' + pixelType + ')');
-
-        gl = wtu.create3DContext("example");
-
-        if (!prologue(gl)) {
-            finishTest();
-            return;
-        }
-
-        var program = wtu.setupTexturedQuad(gl);
-
-        gl.clearColor(0,0,0,1);
-        gl.clearDepth(1);
-
-        textureLoc = gl.getUniformLocation(program, "tex");
-        runNextVideo();
-    }
-
-    function runOneIteration(videoElement, useTexSubImage2D, flipY, topColor, bottomColor)
-    {
-        debug('Testing ' + (useTexSubImage2D ? 'texSubImage2D' : 'texImage2D') +
-              ' with flipY=' + flipY);
-        gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-        // Disable any writes to the alpha channel
-        gl.colorMask(1, 1, 1, 0);
-        var texture = gl.createTexture();
-        // Bind the texture to texture unit 0
-        gl.bindTexture(gl.TEXTURE_2D, texture);
-        // Set up texture parameters
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-        // Set up pixel store parameters
-        gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, flipY);
-        gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, false);
-        // Upload the videoElement into the texture
-        if (useTexSubImage2D) {
-            // Initialize the texture to black first
-            gl.texImage2D(gl.TEXTURE_2D, 0, gl[pixelFormat],
-                          videoElement.videoWidth, videoElement.videoHeight, 0,
-                          gl[pixelFormat], gl[pixelType], null);
-            gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl[pixelFormat], gl[pixelType], videoElement);
-        } else {
-            gl.texImage2D(gl.TEXTURE_2D, 0, gl[pixelFormat], gl[pixelFormat], gl[pixelType], videoElement);
-        }
-
-        var c = document.createElement("canvas");
-        c.width = 16;
-        c.height = 16;
-        c.style.border = "1px solid black";
-        var ctx = c.getContext("2d");
-        ctx.drawImage(videoElement, 0, 0, 16, 16);
-        document.body.appendChild(c);
-
-        // Point the uniform sampler to texture unit 0
-        gl.uniform1i(textureLoc, 0);
-        // Draw the triangles
-        wtu.drawQuad(gl, [0, 0, 0, 255]);
-        // Check a few pixels near the top and bottom and make sure they have
-        // the right color.
-        debug("Checking lower left corner");
-        wtu.checkCanvasRect(gl, 4, 4, 2, 2, bottomColor,
-                            "shouldBe " + bottomColor);
-        debug("Checking upper left corner");
-        wtu.checkCanvasRect(gl, 4, gl.canvas.height - 8, 2, 2, topColor,
-                            "shouldBe " + topColor);
-    }
-
-    function runTest(videoElement)
-    {
-        var red = [255, 0, 0];
-        var green = [0, 255, 0];
-        runOneIteration(videoElement, false, true, red, green);
-        runOneIteration(videoElement, false, false, green, red);
-        runOneIteration(videoElement, true, true, red, green);
-        runOneIteration(videoElement, true, false, green, red);
-
-        glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-
-        runNextVideo();
-    }
-
-    return init;
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/vertexShader.vert b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/vertexShader.vert
deleted file mode 100644
index 1a68be8..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/vertexShader.vert
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
-Copyright (C) 2009 Apple Inc.  All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-1. Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-2. Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
-
-THIS SOFTWARE IS PROVIDED BY APPLE INC. AS IS AND ANY
-EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE INC. OR
-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
-EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
-PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
-OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-*/
-attribute vec4 a_vertex;
-attribute vec3 a_normal;
-
-uniform mediump mat4 u_modelViewProjMatrix;
-
-varying vec3 v_normal;
-
-void main()
-{
-    v_normal = a_normal;
-    gl_Position =  u_modelViewProjMatrix * a_vertex;
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test-utils.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test-utils.js
deleted file mode 100644
index 062122c..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test-utils.js
+++ /dev/null
@@ -1,1998 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-var WebGLTestUtils = (function() {
-"use strict";
-
-/**
- * Wrapped logging function.
- * @param {string} msg The message to log.
- */
-var log = function(msg) {
-  if (window.console && window.console.log) {
-    window.console.log(msg);
-  }
-};
-
-/**
- * Wrapped logging function.
- * @param {string} msg The message to log.
- */
-var error = function(msg) {
-  if (window.console) {
-    if (window.console.error) {
-      window.console.error(msg);
-    }
-    else if (window.console.log) {
-      window.console.log(msg);
-    }
-  }
-};
-
-/**
- * Turn off all logging.
- */
-var loggingOff = function() {
-  log = function() {};
-  error = function() {};
-};
-
-/**
- * Converts a WebGL enum to a string
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} value The enum value.
- * @return {string} The enum as a string.
- */
-var glEnumToString = function(gl, value) {
-  for (var p in gl) {
-    if (gl[p] == value) {
-      return p;
-    }
-  }
-  return "0x" + value.toString(16);
-};
-
-var lastError = "";
-
-/**
- * Returns the last compiler/linker error.
- * @return {string} The last compiler/linker error.
- */
-var getLastError = function() {
-  return lastError;
-};
-
-/**
- * Whether a haystack ends with a needle.
- * @param {string} haystack String to search
- * @param {string} needle String to search for.
- * @param {boolean} True if haystack ends with needle.
- */
-var endsWith = function(haystack, needle) {
-  return haystack.substr(haystack.length - needle.length) === needle;
-};
-
-/**
- * Whether a haystack starts with a needle.
- * @param {string} haystack String to search
- * @param {string} needle String to search for.
- * @param {boolean} True if haystack starts with needle.
- */
-var startsWith = function(haystack, needle) {
-  return haystack.substr(0, needle.length) === needle;
-};
-
-/**
- * A vertex shader for a single texture.
- * @type {string}
- */
-var simpleTextureVertexShader = [
-  'attribute vec4 vPosition;',
-  'attribute vec2 texCoord0;',
-  'varying vec2 texCoord;',
-  'void main() {',
-  '    gl_Position = vPosition;',
-  '    texCoord = texCoord0;',
-  '}'].join('\n');
-
-/**
- * A fragment shader for a single texture.
- * @type {string}
- */
-var simpleTextureFragmentShader = [
-  'precision mediump float;',
-  'uniform sampler2D tex;',
-  'varying vec2 texCoord;',
-  'void main() {',
-  '    gl_FragData[0] = texture2D(tex, texCoord);',
-  '}'].join('\n');
-
-/**
- * A vertex shader for a single texture.
- * @type {string}
- */
-var noTexCoordTextureVertexShader = [
-  'attribute vec4 vPosition;',
-  'varying vec2 texCoord;',
-  'void main() {',
-  '    gl_Position = vPosition;',
-  '    texCoord = vPosition.xy * 0.5 + 0.5;',
-  '}'].join('\n');
-
-/**
- * A vertex shader for a uniform color.
- * @type {string}
- */
-var simpleColorVertexShader = [
-  'attribute vec4 vPosition;',
-  'void main() {',
-  '    gl_Position = vPosition;',
-  '}'].join('\n');
-
-/**
- * A fragment shader for a uniform color.
- * @type {string}
- */
-var simpleColorFragmentShader = [
-  'precision mediump float;',
-  'uniform vec4 u_color;',
-  'void main() {',
-  '    gl_FragData[0] = u_color;',
-  '}'].join('\n');
-
-/**
- * A vertex shader for vertex colors.
- * @type {string}
- */
-var simpleVertexColorVertexShader = [
-  'attribute vec4 vPosition;',
-  'attribute vec4 a_color;',
-  'varying vec4 v_color;',
-  'void main() {',
-  '    gl_Position = vPosition;',
-  '    v_color = a_color;',
-  '}'].join('\n');
-
-/**
- * A fragment shader for vertex colors.
- * @type {string}
- */
-var simpleVertexColorFragmentShader = [
-  'precision mediump float;',
-  'varying vec4 v_color;',
-  'void main() {',
-  '    gl_FragData[0] = v_color;',
-  '}'].join('\n');
-
-/**
- * Creates a simple texture vertex shader.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @return {!WebGLShader}
- */
-var setupSimpleTextureVertexShader = function(gl) {
-    return loadShader(gl, simpleTextureVertexShader, gl.VERTEX_SHADER);
-};
-
-/**
- * Creates a simple texture fragment shader.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @return {!WebGLShader}
- */
-var setupSimpleTextureFragmentShader = function(gl) {
-    return loadShader(
-        gl, simpleTextureFragmentShader, gl.FRAGMENT_SHADER);
-};
-
-/**
- * Creates a texture vertex shader that doesn't need texcoords.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @return {!WebGLShader}
- */
-var setupNoTexCoordTextureVertexShader = function(gl) {
-    return loadShader(gl, noTexCoordTextureVertexShader, gl.VERTEX_SHADER);
-};
-
-/**
- * Creates a simple vertex color vertex shader.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @return {!WebGLShader}
- */
-var setupSimpleVertexColorVertexShader = function(gl) {
-    return loadShader(gl, simpleVertexColorVertexShader, gl.VERTEX_SHADER);
-};
-
-/**
- * Creates a simple vertex color fragment shader.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @return {!WebGLShader}
- */
-var setupSimpleVertexColorFragmentShader = function(gl) {
-    return loadShader(
-        gl, simpleVertexColorFragmentShader, gl.FRAGMENT_SHADER);
-};
-
-/**
- * Creates a simple color vertex shader.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @return {!WebGLShader}
- */
-var setupSimpleColorVertexShader = function(gl) {
-    return loadShader(gl, simpleColorVertexShader, gl.VERTEX_SHADER);
-};
-
-/**
- * Creates a simple color fragment shader.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @return {!WebGLShader}
- */
-var setupSimpleColorFragmentShader = function(gl) {
-    return loadShader(
-        gl, simpleColorFragmentShader, gl.FRAGMENT_SHADER);
-};
-
-/**
- * Creates a program, attaches shaders, binds attrib locations, links the
- * program and calls useProgram.
- * @param {!Array.<!WebGLShader|string>} shaders The shaders to
- *        attach, or the source, or the id of a script to get
- *        the source from.
- * @param {!Array.<string>} opt_attribs The attribs names.
- * @param {!Array.<number>} opt_locations The locations for the attribs.
- */
-var setupProgram = function(gl, shaders, opt_attribs, opt_locations) {
-  var realShaders = [];
-  var program = gl.createProgram();
-  var shaderType = undefined;
-  for (var ii = 0; ii < shaders.length; ++ii) {
-    var shader = shaders[ii];
-    if (typeof shader == 'string') {
-      var element = document.getElementById(shader);
-      if (element) {
-        if (element.type != "x-shader/x-vertex" && element.type != "x-shader/x-fragment")
-          shaderType = ii ? gl.FRAGMENT_SHADER : gl.VERTEX_SHADER;
-        shader = loadShaderFromScript(gl, shader, shaderType);
-      } else if (endsWith(shader, ".vert")) {
-        shader = loadShaderFromFile(gl, shader, gl.VERTEX_SHADER);
-      } else if (endsWith(shader, ".frag")) {
-        shader = loadShaderFromFile(gl, shader, gl.FRAGMENT_SHADER);
-      } else {
-        shader = loadShader(gl, shader, ii ? gl.FRAGMENT_SHADER : gl.VERTEX_SHADER);
-      }
-    }
-    gl.attachShader(program, shader);
-  }
-  if (opt_attribs) {
-    for (var ii = 0; ii < opt_attribs.length; ++ii) {
-      gl.bindAttribLocation(
-          program,
-          opt_locations ? opt_locations[ii] : ii,
-          opt_attribs[ii]);
-    }
-  }
-  gl.linkProgram(program);
-
-  // Check the link status
-  var linked = gl.getProgramParameter(program, gl.LINK_STATUS);
-  if (!linked) {
-      // something went wrong with the link
-      lastError = gl.getProgramInfoLog (program);
-      error("Error in program linking:" + lastError);
-
-      gl.deleteProgram(program);
-      return null;
-  }
-
-  gl.useProgram(program);
-  return program;
-};
-
-/**
- * Creates a simple texture program.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} opt_positionLocation The attrib location for position.
- * @param {number} opt_texcoordLocation The attrib location for texture coords.
- * @return {WebGLProgram}
- */
-var setupSimpleTextureProgram = function(
-    gl, opt_positionLocation, opt_texcoordLocation) {
-  opt_positionLocation = opt_positionLocation || 0;
-  opt_texcoordLocation = opt_texcoordLocation || 1;
-  var vs = setupSimpleTextureVertexShader(gl);
-  var fs = setupSimpleTextureFragmentShader(gl);
-  if (!vs || !fs) {
-    return null;
-  }
-  var program = setupProgram(
-      gl,
-      [vs, fs],
-      ['vPosition', 'texCoord0'],
-      [opt_positionLocation, opt_texcoordLocation]);
-  if (!program) {
-    gl.deleteShader(fs);
-    gl.deleteShader(vs);
-  }
-  gl.useProgram(program);
-  return program;
-};
-
-/**
- * Creates a simple texture program.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @return {WebGLProgram}
- */
-var setupNoTexCoordTextureProgram = function(gl) {
-  var vs = setupNoTexCoordTextureVertexShader(gl);
-  var fs = setupSimpleTextureFragmentShader(gl);
-  if (!vs || !fs) {
-    return null;
-  }
-  var program = setupProgram(
-      gl,
-      [vs, fs],
-      ['vPosition'],
-      [0]);
-  if (!program) {
-    gl.deleteShader(fs);
-    gl.deleteShader(vs);
-  }
-  gl.useProgram(program);
-  return program;
-};
-
-/**
- * Creates a simple texture program.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} opt_positionLocation The attrib location for position.
- * @param {number} opt_texcoordLocation The attrib location for texture coords.
- * @return {WebGLProgram}
- */
-var setupSimpleTextureProgram = function(
-    gl, opt_positionLocation, opt_texcoordLocation) {
-  opt_positionLocation = opt_positionLocation || 0;
-  opt_texcoordLocation = opt_texcoordLocation || 1;
-  var vs = setupSimpleTextureVertexShader(gl);
-  var fs = setupSimpleTextureFragmentShader(gl);
-  if (!vs || !fs) {
-    return null;
-  }
-  var program = setupProgram(
-      gl,
-      [vs, fs],
-      ['vPosition', 'texCoord0'],
-      [opt_positionLocation, opt_texcoordLocation]);
-  if (!program) {
-    gl.deleteShader(fs);
-    gl.deleteShader(vs);
-  }
-  gl.useProgram(program);
-  return program;
-};
-
-/**
- * Creates a simple vertex color program.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} opt_positionLocation The attrib location for position.
- * @param {number} opt_vertexColorLocation The attrib location
- *        for vertex colors.
- * @return {WebGLProgram}
- */
-var setupSimpleVertexColorProgram = function(
-    gl, opt_positionLocation, opt_vertexColorLocation) {
-  opt_positionLocation = opt_positionLocation || 0;
-  opt_vertexColorLocation = opt_vertexColorLocation || 1;
-  var vs = setupSimpleVertexColorVertexShader(gl);
-  var fs = setupSimpleVertexColorFragmentShader(gl);
-  if (!vs || !fs) {
-    return null;
-  }
-  var program = setupProgram(
-      gl,
-      [vs, fs],
-      ['vPosition', 'a_color'],
-      [opt_positionLocation, opt_vertexColorLocation]);
-  if (!program) {
-    gl.deleteShader(fs);
-    gl.deleteShader(vs);
-  }
-  gl.useProgram(program);
-  return program;
-};
-
-/**
- * Creates a simple color program.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} opt_positionLocation The attrib location for position.
- * @return {WebGLProgram}
- */
-var setupSimpleColorProgram = function(gl, opt_positionLocation) {
-  opt_positionLocation = opt_positionLocation || 0;
-  var vs = setupSimpleColorVertexShader(gl);
-  var fs = setupSimpleColorFragmentShader(gl);
-  if (!vs || !fs) {
-    return null;
-  }
-  var program = setupProgram(
-      gl,
-      [vs, fs],
-      ['vPosition'],
-      [opt_positionLocation]);
-  if (!program) {
-    gl.deleteShader(fs);
-    gl.deleteShader(vs);
-  }
-  gl.useProgram(program);
-  return program;
-};
-
-/**
- * Creates buffers for a textured unit quad and attaches them to vertex attribs.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} opt_positionLocation The attrib location for position.
- * @param {number} opt_texcoordLocation The attrib location for texture coords.
- * @return {!Array.<WebGLBuffer>} The buffer objects that were
- *      created.
- */
-var setupUnitQuad = function(gl, opt_positionLocation, opt_texcoordLocation) {
-  return setupUnitQuadWithTexCoords(gl, [ 0.0, 0.0 ], [ 1.0, 1.0 ],
-                                    opt_positionLocation, opt_texcoordLocation);
-};
-
-/**
- * Creates buffers for a textured unit quad with specified lower left
- * and upper right texture coordinates, and attaches them to vertex
- * attribs.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Array.<number>} lowerLeftTexCoords The texture coordinates for the lower left corner.
- * @param {!Array.<number>} upperRightTexCoords The texture coordinates for the upper right corner.
- * @param {number} opt_positionLocation The attrib location for position.
- * @param {number} opt_texcoordLocation The attrib location for texture coords.
- * @return {!Array.<WebGLBuffer>} The buffer objects that were
- *      created.
- */
-var setupUnitQuadWithTexCoords = function(
-    gl, lowerLeftTexCoords, upperRightTexCoords,
-    opt_positionLocation, opt_texcoordLocation) {
-  opt_positionLocation = opt_positionLocation || 0;
-  opt_texcoordLocation = opt_texcoordLocation || 1;
-  var objects = [];
-
-  var vertexObject = gl.createBuffer();
-  gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
-  gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([
-       1.0,  1.0, 0.0,
-      -1.0,  1.0, 0.0,
-      -1.0, -1.0, 0.0,
-       1.0,  1.0, 0.0,
-      -1.0, -1.0, 0.0,
-       1.0, -1.0, 0.0]), gl.STATIC_DRAW);
-  gl.enableVertexAttribArray(opt_positionLocation);
-  gl.vertexAttribPointer(opt_positionLocation, 3, gl.FLOAT, false, 0, 0);
-  objects.push(vertexObject);
-
-  var llx = lowerLeftTexCoords[0];
-  var lly = lowerLeftTexCoords[1];
-  var urx = upperRightTexCoords[0];
-  var ury = upperRightTexCoords[1];
-
-  var vertexObject = gl.createBuffer();
-  gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
-  gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([
-      urx, ury,
-      llx, ury,
-      llx, lly,
-      urx, ury,
-      llx, lly,
-      urx, lly]), gl.STATIC_DRAW);
-  gl.enableVertexAttribArray(opt_texcoordLocation);
-  gl.vertexAttribPointer(opt_texcoordLocation, 2, gl.FLOAT, false, 0, 0);
-  objects.push(vertexObject);
-  return objects;
-};
-
-/**
- * Creates a program and buffers for rendering a textured quad.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} opt_positionLocation The attrib location for
- *        position. Default = 0.
- * @param {number} opt_texcoordLocation The attrib location for
- *        texture coords. Default = 0.
- * @return {!WebGLProgram}
- */
-var setupTexturedQuad = function(
-    gl, opt_positionLocation, opt_texcoordLocation) {
-  var program = setupSimpleTextureProgram(
-      gl, opt_positionLocation, opt_texcoordLocation);
-  setupUnitQuad(gl, opt_positionLocation, opt_texcoordLocation);
-  return program;
-};
-
-/**
- * Creates a program and buffers for rendering a color quad.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} opt_positionLocation The attrib location for position.
- * @return {!WebGLProgram}
- */
-var setupColorQuad = function(gl, opt_positionLocation) {
-  opt_positionLocation = opt_positionLocation || 0;
-  var program = setupSimpleColorProgram(gl);
-  setupUnitQuad(gl, opt_positionLocation);
-  return program;
-};
-
-/**
- * Creates a program and buffers for rendering a textured quad with
- * specified lower left and upper right texture coordinates.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Array.<number>} lowerLeftTexCoords The texture coordinates for the lower left corner.
- * @param {!Array.<number>} upperRightTexCoords The texture coordinates for the upper right corner.
- * @param {number} opt_positionLocation The attrib location for position.
- * @param {number} opt_texcoordLocation The attrib location for texture coords.
- * @return {!WebGLProgram}
- */
-var setupTexturedQuadWithTexCoords = function(
-    gl, lowerLeftTexCoords, upperRightTexCoords,
-    opt_positionLocation, opt_texcoordLocation) {
-  var program = setupSimpleTextureProgram(
-      gl, opt_positionLocation, opt_texcoordLocation);
-  setupUnitQuadWithTexCoords(gl, lowerLeftTexCoords, upperRightTexCoords,
-                             opt_positionLocation, opt_texcoordLocation);
-  return program;
-};
-
-/**
- * Creates a unit quad with only positions of a given resolution.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} gridRes The resolution of the mesh grid,
- *     expressed in the number of quads across and down.
- * @param {number} opt_positionLocation The attrib location for position.
- */
-var setupQuad = function (
-    gl, gridRes, opt_positionLocation, opt_flipOddTriangles) {
-  return setupQuadWithOptions(gl,
-    { gridRes: gridRes,
-      positionLocation: opt_positionLocation,
-      flipOddTriangles: opt_flipOddTriangles
-    });
-};
-
-/**
- * Creates a quad with various options.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Object) options The options. See below.
- * @return {!Array.<WebGLBuffer>} The created buffers.
- *     [positions, <colors>, indices]
- *
- * Options:
- *   gridRes: number of quads across and down grid.
- *   positionLocation: attrib location for position
- *   flipOddTriangles: reverse order of vertices of every other
- *       triangle
- *   positionOffset: offset added to each vertex
- *   positionMult: multipier for each vertex
- *   colorLocation: attrib location for vertex colors. If
- *      undefined no vertex colors will be created.
- */
-var setupQuadWithOptions = function (gl, options) {
-  var positionLocation = options.positionLocation || 0;
-  var objects = [];
-
-  var gridRes = options.gridRes || 1;
-  var positionOffset = options.positionOffset || 0;
-  var positionMult = options.positionMult || 1;
-  var vertsAcross = gridRes + 1;
-  var numVerts = vertsAcross * vertsAcross;
-  var positions = new Float32Array(numVerts * 3);
-  var indices = new Uint16Array(6 * gridRes * gridRes);
-  var poffset = 0;
-
-  for (var yy = 0; yy <= gridRes; ++yy) {
-    for (var xx = 0; xx <= gridRes; ++xx) {
-      positions[poffset + 0] = (-1 + 2 * xx / gridRes) * positionMult + positionOffset;
-      positions[poffset + 1] = (-1 + 2 * yy / gridRes) * positionMult + positionOffset;
-      positions[poffset + 2] = 0;
-
-      poffset += 3;
-    }
-  }
-
-  var buf = gl.createBuffer();
-  gl.bindBuffer(gl.ARRAY_BUFFER, buf);
-  gl.bufferData(gl.ARRAY_BUFFER, positions, gl.STATIC_DRAW);
-  gl.enableVertexAttribArray(positionLocation);
-  gl.vertexAttribPointer(positionLocation, 3, gl.FLOAT, false, 0, 0);
-  objects.push(buf);
-
-  if (options.colorLocation !== undefined) {
-    var colors = new Float32Array(numVerts * 4);
-    for (var yy = 0; yy <= gridRes; ++yy) {
-      for (var xx = 0; xx <= gridRes; ++xx) {
-        if (options.color !== undefined) {
-          colors[poffset + 0] = options.color[0];
-          colors[poffset + 1] = options.color[1];
-          colors[poffset + 2] = options.color[2];
-          colors[poffset + 3] = options.color[3];
-        } else {
-          colors[poffset + 0] = xx / gridRes;
-          colors[poffset + 1] = yy / gridRes;
-          colors[poffset + 2] = (xx / gridRes) * (yy / gridRes);
-          colors[poffset + 3] = (yy % 2) * 0.5 + 0.5;
-        }
-        poffset += 4;
-      }
-    }
-
-    var buf = gl.createBuffer();
-    gl.bindBuffer(gl.ARRAY_BUFFER, buf);
-    gl.bufferData(gl.ARRAY_BUFFER, colors, gl.STATIC_DRAW);
-    gl.enableVertexAttribArray(options.colorLocation);
-    gl.vertexAttribPointer(options.colorLocation, 4, gl.FLOAT, false, 0, 0);
-    objects.push(buf);
-  }
-
-  var tbase = 0;
-  for (var yy = 0; yy < gridRes; ++yy) {
-    var index = yy * vertsAcross;
-    for (var xx = 0; xx < gridRes; ++xx) {
-      indices[tbase + 0] = index + 0;
-      indices[tbase + 1] = index + 1;
-      indices[tbase + 2] = index + vertsAcross;
-      indices[tbase + 3] = index + vertsAcross;
-      indices[tbase + 4] = index + 1;
-      indices[tbase + 5] = index + vertsAcross + 1;
-
-      if (options.flipOddTriangles) {
-        indices[tbase + 4] = index + vertsAcross + 1;
-        indices[tbase + 5] = index + 1;
-      }
-
-      index += 1;
-      tbase += 6;
-    }
-  }
-
-  var buf = gl.createBuffer();
-  gl.bindBuffer(gl.ELEMENT_ARRAY_BUFFER, buf);
-  gl.bufferData(gl.ELEMENT_ARRAY_BUFFER, indices, gl.STATIC_DRAW);
-  objects.push(buf);
-
-  return objects;
-};
-
-/**
- * Fills the given texture with a solid color
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!WebGLTexture} tex The texture to fill.
- * @param {number} width The width of the texture to create.
- * @param {number} height The height of the texture to create.
- * @param {!Array.<number>} color The color to fill with. A 4 element array
- *        where each element is in the range 0 to 255.
- * @param {number} opt_level The level of the texture to fill. Default = 0.
- */
-var fillTexture = function(gl, tex, width, height, color, opt_level) {
-  opt_level = opt_level || 0;
-  var numPixels = width * height;
-  var size = numPixels * 4;
-  var buf = new Uint8Array(size);
-  for (var ii = 0; ii < numPixels; ++ii) {
-    var off = ii * 4;
-    buf[off + 0] = color[0];
-    buf[off + 1] = color[1];
-    buf[off + 2] = color[2];
-    buf[off + 3] = color[3];
-  }
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  gl.texImage2D(
-      gl.TEXTURE_2D, opt_level, gl.RGBA, width, height, 0,
-      gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  };
-
-/**
- * Creates a textures and fills it with a solid color
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} width The width of the texture to create.
- * @param {number} height The height of the texture to create.
- * @param {!Array.<number>} color The color to fill with. A 4 element array
- *        where each element is in the range 0 to 255.
- * @return {!WebGLTexture}
- */
-var createColoredTexture = function(gl, width, height, color) {
-  var tex = gl.createTexture();
-  fillTexture(gl, tex, width, height, color);
-  return tex;
-};
-
-var ubyteToFloat = function(c) {
-  return c / 255;
-};
-
-var ubyteColorToFloatColor = function(color) {
-  var floatColor = [];
-  for (var ii = 0; ii < color.length; ++ii) {
-    floatColor[ii] = ubyteToFloat(color[ii]);
-  }
-  return floatColor;
-};
-
-/**
- * Sets the "u_color" uniform of the current program to color.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Array.<number> color 4 element array of 0-1 color
- *      components.
- */
-var setFloatDrawColor = function(gl, color) {
-  var program = gl.getParameter(gl.CURRENT_PROGRAM);
-  var colorLocation = gl.getUniformLocation(program, "u_color");
-  gl.uniform4fv(colorLocation, color);
-};
-
-/**
- * Sets the "u_color" uniform of the current program to color.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Array.<number> color 4 element array of 0-255 color
- *      components.
- */
-var setUByteDrawColor = function(gl, color) {
-  setFloatDrawColor(gl, ubyteColorToFloatColor(color));
-};
-
-/**
- * Draws a previously setup quad in the given color.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Array.<number>} color The color to draw with. A 4
- *        element array where each element is in the range 0 to
- *        1.
- */
-var drawFloatColorQuad = function(gl, color) {
-  var program = gl.getParameter(gl.CURRENT_PROGRAM);
-  var colorLocation = gl.getUniformLocation(program, "u_color");
-  gl.uniform4fv(colorLocation, color);
-  gl.drawArrays(gl.TRIANGLES, 0, 6);
-};
-
-
-/**
- * Draws a previously setup quad in the given color.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Array.<number>} color The color to draw with. A 4
- *        element array where each element is in the range 0 to
- *        255.
- */
-var drawUByteColorQuad = function(gl, color) {
-  drawFloatColorQuad(gl, ubyteColorToFloatColor(color));
-};
-
-/**
- * Draws a previously setup quad.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Array.<number>} opt_color The color to fill clear with before
- *        drawing. A 4 element array where each element is in the range 0 to
- *        255. Default [255, 255, 255, 255]
- */
-var drawQuad = function(gl, opt_color) {
-  opt_color = opt_color || [255, 255, 255, 255];
-  gl.clearColor(
-      opt_color[0] / 255,
-      opt_color[1] / 255,
-      opt_color[2] / 255,
-      opt_color[3] / 255);
-  gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-  gl.drawArrays(gl.TRIANGLES, 0, 6);
-};
-
-/**
- * Draws a previously setup quad.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} gridRes Resolution of grid.
- * @param {!Array.<number>} opt_color The color to fill clear with before
- *        drawing. A 4 element array where each element is in the range 0 to
- *        255. Default [255, 255, 255, 255]
- */
-var drawIndexedQuad = function(gl, gridRes, opt_color) {
-  opt_color = opt_color || [255, 255, 255, 255];
-  gl.clearColor(
-      opt_color[0] / 255,
-      opt_color[1] / 255,
-      opt_color[2] / 255,
-      opt_color[3] / 255);
-  gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-  gl.drawElements(gl.TRIANGLES, gridRes * 6, gl.UNSIGNED_SHORT, 0);
-};
-
-/**
- * Checks that a portion of a canvas is 1 color.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} x left corner of region to check.
- * @param {number} y bottom corner of region to check.
- * @param {number} width width of region to check.
- * @param {number} height width of region to check.
- * @param {!Array.<number>} color The color to fill clear with before drawing. A
- *        4 element array where each element is in the range 0 to 255.
- * @param {number} opt_errorRange Optional. Acceptable error in
- *        color checking. 0 by default.
- * @param {!function()} sameFn Function to call if all pixels
- *        are the same as color.
- * @param {!function()} differentFn Function to call if a pixel
- *        is different than color
- * @param {!function()} logFn Function to call for logging.
- */
-var checkCanvasRectColor = function(gl, x, y, width, height, color, opt_errorRange, sameFn, differentFn, logFn) {
-  var errorRange = opt_errorRange || 0;
-  if (!errorRange.length) {
-    errorRange = [errorRange, errorRange, errorRange, errorRange]
-  }
-  var buf;
-  if (gl instanceof WebGLRenderingContext) {
-    buf = new Uint8Array(width * height * 4);
-    gl.readPixels(x, y, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  } else {
-    buf = gl.getImageData(x, y, width, height).data;
-  }
-  for (var i = 0; i < width * height; ++i) {
-    var offset = i * 4;
-    for (var j = 0; j < color.length; ++j) {
-      if (Math.abs(buf[offset + j] - color[j]) > errorRange[j]) {
-        differentFn();
-        var was = buf[offset + 0].toString();
-        for (j = 1; j < color.length; ++j) {
-          was += "," + buf[offset + j];
-        }
-        logFn('at (' + (i % width) + ', ' + Math.floor(i / width) +
-              ') expected: ' + color + ' was ' + was);
-        return;
-      }
-    }
-  }
-  sameFn();
-};
-
-/**
- * Checks that a portion of a canvas is 1 color.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} x left corner of region to check.
- * @param {number} y bottom corner of region to check.
- * @param {number} width width of region to check.
- * @param {number} height width of region to check.
- * @param {!Array.<number>} color The color to fill clear with before drawing. A
- *        4 element array where each element is in the range 0 to 255.
- * @param {string} opt_msg Message to associate with success. Eg
- *        ("should be red").
- * @param {number} opt_errorRange Optional. Acceptable error in
- *        color checking. 0 by default.
- */
-var checkCanvasRect = function(gl, x, y, width, height, color, opt_msg, opt_errorRange) {
-  var msg = opt_msg;
-  if (msg === undefined) {
-    msg = "should be " + color.toString();
-  }
-  checkCanvasRectColor(
-      gl, x, y, width, height, color, opt_errorRange,
-      function() {
-        testPassed(msg);
-      },
-      function() {
-        testFailed(msg);
-      },
-      debug);
-};
-
-/**
- * Checks that an entire canvas is 1 color.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!Array.<number>} color The color to fill clear with before drawing. A
- *        4 element array where each element is in the range 0 to 255.
- * @param {string} msg Message to associate with success. Eg ("should be red").
- * @param {number} errorRange Optional. Acceptable error in
- *        color checking. 0 by default.
- */
-var checkCanvas = function(gl, color, msg, errorRange) {
-  checkCanvasRect(gl, 0, 0, gl.canvas.width, gl.canvas.height, color, msg, errorRange);
-};
-
-/**
- * Loads a texture, calls callback when finished.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {string} url URL of image to load
- * @param {function(!Image): void} callback Function that gets called after
- *        image has loaded
- * @return {!WebGLTexture} The created texture.
- */
-var loadTexture = function(gl, url, callback) {
-    var texture = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-    var image = new Image();
-    image.onload = function() {
-        gl.bindTexture(gl.TEXTURE_2D, texture);
-        gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, true);
-        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, image);
-        callback(image);
-    };
-    image.src = url;
-    return texture;
-};
-
-/**
- * Makes a shallow copy of an object.
- * @param {!Object) src Object to copy
- * @return {!Object} The copy of src.
- */
-var shallowCopyObject = function(src) {
-  var dst = {};
-  for (var attr in src) {
-    if (src.hasOwnProperty(attr)) {
-      dst[attr] = src[attr];
-    }
-  }
-  return dst;
-};
-
-/**
- * Checks if an attribute exists on an object case insensitive.
- * @param {!Object) obj Object to check
- * @param {string} attr Name of attribute to look for.
- * @return {string?} The name of the attribute if it exists,
- *         undefined if not.
- */
-var hasAttributeCaseInsensitive = function(obj, attr) {
-  var lower = attr.toLowerCase();
-  for (var key in obj) {
-    if (obj.hasOwnProperty(key) && key.toLowerCase() == lower) {
-      return key;
-    }
-  }
-};
-
-/**
- * Creates a webgl context.
- * @param {!Canvas|string} opt_canvas The canvas tag to get
- *     context from. If one is not passed in one will be
- *     created. If it's a string it's assumed to be the id of a
- *     canvas.
- * @return {!WebGLContext} The created context.
- */
-var create3DContext = function(opt_canvas, opt_attributes) {
-  if (window.initTestingHarness) {
-    window.initTestingHarness();
-  }
-  var attributes = shallowCopyObject(opt_attributes || {});
-  if (!hasAttributeCaseInsensitive(attributes, "antialias")) {
-    attributes.antialias = false;
-  }
-
-  opt_canvas = opt_canvas || document.createElement("canvas");
-  if (typeof opt_canvas == 'string') {
-    opt_canvas = document.getElementById(opt_canvas);
-  }
-  var context = null;
-  var names = ["webgl", "experimental-webgl"];
-  for (var i = 0; i < names.length; ++i) {
-    try {
-      context = opt_canvas.getContext(names[i], attributes);
-    } catch (e) {
-    }
-    if (context) {
-      break;
-    }
-  }
-  if (!context) {
-    testFailed("Unable to fetch WebGL rendering context for Canvas");
-  }
-  return context;
-}
-
-/**
- * Gets a GLError value as a string.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} err The webgl error as retrieved from gl.getError().
- * @return {string} the error as a string.
- */
-var getGLErrorAsString = function(gl, err) {
-  if (err === gl.NO_ERROR) {
-    return "NO_ERROR";
-  }
-  for (var name in gl) {
-    if (gl[name] === err) {
-      return name;
-    }
-  }
-  return err.toString();
-};
-
-/**
- * Wraps a WebGL function with a function that throws an exception if there is
- * an error.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {string} fname Name of function to wrap.
- * @return {function} The wrapped function.
- */
-var createGLErrorWrapper = function(context, fname) {
-  return function() {
-    var rv = context[fname].apply(context, arguments);
-    var err = context.getError();
-    if (err != context.NO_ERROR)
-      throw "GL error " + getGLErrorAsString(context, err) + " in " + fname;
-    return rv;
-  };
-};
-
-/**
- * Creates a WebGL context where all functions are wrapped to throw an exception
- * if there is an error.
- * @param {!Canvas} canvas The HTML canvas to get a context from.
- * @return {!Object} The wrapped context.
- */
-function create3DContextWithWrapperThatThrowsOnGLError(canvas) {
-  var context = create3DContext(canvas);
-  var wrap = {};
-  for (var i in context) {
-    try {
-      if (typeof context[i] == 'function') {
-        wrap[i] = createGLErrorWrapper(context, i);
-      } else {
-        wrap[i] = context[i];
-      }
-    } catch (e) {
-      error("createContextWrapperThatThrowsOnGLError: Error accessing " + i);
-    }
-  }
-  wrap.getError = function() {
-      return context.getError();
-  };
-  return wrap;
-};
-
-/**
- * Tests that an evaluated expression generates a specific GL error.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} glError The expected gl error.
- * @param {string} evalSTr The string to evaluate.
- */
-var shouldGenerateGLError = function(gl, glError, evalStr) {
-  var exception;
-  try {
-    eval(evalStr);
-  } catch (e) {
-    exception = e;
-  }
-  if (exception) {
-    testFailed(evalStr + " threw exception " + exception);
-  } else {
-    var err = gl.getError();
-    if (err != glError) {
-      testFailed(evalStr + " expected: " + getGLErrorAsString(gl, glError) + ". Was " + getGLErrorAsString(gl, err) + ".");
-    } else {
-      testPassed(evalStr + " was expected value: " + getGLErrorAsString(gl, glError) + ".");
-    }
-  }
-};
-
-/**
- * Tests that the first error GL returns is the specified error.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number} glError The expected gl error.
- * @param {string} opt_msg
- */
-var glErrorShouldBe = function(gl, glError, opt_msg) {
-  opt_msg = opt_msg || "";
-  var err = gl.getError();
-  if (err != glError) {
-    testFailed("getError expected: " + getGLErrorAsString(gl, glError) +
-               ". Was " + getGLErrorAsString(gl, err) + " : " + opt_msg);
-  } else {
-    testPassed("getError was expected value: " +
-                getGLErrorAsString(gl, glError) + " : " + opt_msg);
-  }
-};
-
-/**
- * Links a WebGL program, throws if there are errors.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!WebGLProgram} program The WebGLProgram to link.
- * @param {function(string): void) opt_errorCallback callback for errors. 
- */
-var linkProgram = function(gl, program, opt_errorCallback) {
-  var errFn = opt_errorCallback || testFailed;
-  // Link the program
-  gl.linkProgram(program);
-
-  // Check the link status
-  var linked = gl.getProgramParameter(program, gl.LINK_STATUS);
-  if (!linked) {
-    // something went wrong with the link
-    var error = gl.getProgramInfoLog (program);
-
-    errFn("Error in program linking:" + error);
-
-    gl.deleteProgram(program);
-  }
-};
-
-/**
- * Loads text from an external file. This function is synchronous.
- * @param {string} url The url of the external file.
- * @param {!function(bool, string): void} callback that is sent a bool for
- *     success and the string.
- */
-var loadTextFileAsync = function(url, callback) {
-  log ("loading: " + url);
-  var error = 'loadTextFileSynchronous failed to load url "' + url + '"';
-  var request;
-  if (window.XMLHttpRequest) {
-    request = new XMLHttpRequest();
-    if (request.overrideMimeType) {
-      request.overrideMimeType('text/plain');
-    }
-  } else {
-    throw 'XMLHttpRequest is disabled';
-  }
-  try {
-    request.open('GET', url, true);
-    request.onreadystatechange = function() {
-      if (request.readyState == 4) {
-        var text = '';
-        // HTTP reports success with a 200 status. The file protocol reports
-        // success with zero. HTTP does not use zero as a status code (they
-        // start at 100).
-        // https://developer.mozilla.org/En/Using_XMLHttpRequest
-        var success = request.status == 200 || request.status == 0;
-        if (success) {
-          text = request.responseText;
-        }
-        log("loaded: " + url);
-        callback(success, text);
-      }
-    };
-    request.send(null);
-  } catch (e) {
-    log("failed to load: " + url);
-    callback(false, '');
-  }
-};
-
-/**
- * Recursively loads a file as a list. Each line is parsed for a relative
- * path. If the file ends in .txt the contents of that file is inserted in
- * the list.
- *
- * @param {string} url The url of the external file.
- * @param {!function(bool, Array<string>): void} callback that is sent a bool
- *     for success and the array of strings.
- */
-var getFileListAsync = function(url, callback) {
-  var files = [];
-
-  var getFileListImpl = function(url, callback) {
-    var files = [];
-    if (url.substr(url.length - 4) == '.txt') {
-      loadTextFileAsync(url, function() {
-        return function(success, text) {
-          if (!success) {
-            callback(false, '');
-            return;
-          }
-          var lines = text.split('\n');
-          var prefix = '';
-          var lastSlash = url.lastIndexOf('/');
-          if (lastSlash >= 0) {
-            prefix = url.substr(0, lastSlash + 1);
-          }
-          var fail = false;
-          var count = 1;
-          var index = 0;
-          for (var ii = 0; ii < lines.length; ++ii) {
-            var str = lines[ii].replace(/^\s\s*/, '').replace(/\s\s*$/, '');
-            if (str.length > 4 &&
-                str[0] != '#' &&
-                str[0] != ";" &&
-                str.substr(0, 2) != "//") {
-              var names = str.split(/ +/);
-              new_url = prefix + str;
-              if (names.length == 1) {
-                new_url = prefix + str;
-                ++count;
-                getFileListImpl(new_url, function(index) {
-                  return function(success, new_files) {
-                    log("got files: " + new_files.length);
-                    if (success) {
-                      files[index] = new_files;
-                    }
-                    finish(success);
-                  };
-                }(index++));
-              } else {
-                var s = "";
-                var p = "";
-                for (var jj = 0; jj < names.length; ++jj) {
-                  s += p + prefix + names[jj];
-                  p = " ";
-                }
-                files[index++] = s;
-              }
-            }
-          }
-          finish(true);
-
-          function finish(success) {
-            if (!success) {
-              fail = true;
-            }
-            --count;
-            log("count: " + count);
-            if (!count) {
-              callback(!fail, files);
-            }
-          }
-        }
-      }());
-
-    } else {
-      files.push(url);
-      callback(true, files);
-    }
-  };
-
-  getFileListImpl(url, function(success, files) {
-    // flatten
-    var flat = [];
-    flatten(files);
-    function flatten(files) {
-      for (var ii = 0; ii < files.length; ++ii) {
-        var value = files[ii];
-        if (typeof(value) == "string") {
-          flat.push(value);
-        } else {
-          flatten(value);
-        }
-      }
-    }
-    callback(success, flat);
-  });
-};
-
-/**
- * Gets a file from a file/URL
- * @param {string} file the URL of the file to get.
- * @return {string} The contents of the file.
- */
-var readFile = function(file) {
-  var xhr = new XMLHttpRequest();
-  xhr.open("GET", file, false);
-  xhr.send();
-  return xhr.responseText.replace(/\r/g, "");
-};
-
-var readFileList = function(url) {
-  var files = [];
-  if (url.substr(url.length - 4) == '.txt') {
-    var lines = readFile(url).split('\n');
-    var prefix = '';
-    var lastSlash = url.lastIndexOf('/');
-    if (lastSlash >= 0) {
-      prefix = url.substr(0, lastSlash + 1);
-    }
-    for (var ii = 0; ii < lines.length; ++ii) {
-      var str = lines[ii].replace(/^\s\s*/, '').replace(/\s\s*$/, '');
-      if (str.length > 4 &&
-          str[0] != '#' &&
-          str[0] != ";" &&
-          str.substr(0, 2) != "//") {
-        var names = str.split(/ +/);
-        if (names.length == 1) {
-          new_url = prefix + str;
-          files = files.concat(readFileList(new_url));
-        } else {
-          var s = "";
-          var p = "";
-          for (var jj = 0; jj < names.length; ++jj) {
-            s += p + prefix + names[jj];
-            p = " ";
-          }
-          files.push(s);
-        }
-      }
-    }
-  } else {
-    files.push(url);
-  }
-  return files;
-};
-
-/**
- * Loads a shader.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {string} shaderSource The shader source.
- * @param {number} shaderType The type of shader. 
- * @param {function(string): void) opt_errorCallback callback for errors. 
- * @return {!WebGLShader} The created shader.
- */
-var loadShader = function(gl, shaderSource, shaderType, opt_errorCallback) {
-  var errFn = opt_errorCallback || error;
-  // Create the shader object
-  var shader = gl.createShader(shaderType);
-  if (shader == null) {
-    errFn("*** Error: unable to create shader '"+shaderSource+"'");
-    return null;
-  }
-
-  // Load the shader source
-  gl.shaderSource(shader, shaderSource);
-  var err = gl.getError();
-  if (err != gl.NO_ERROR) {
-    errFn("*** Error loading shader '" + shader + "':" + glEnumToString(gl, err));
-    return null;
-  }
-
-  // Compile the shader
-  gl.compileShader(shader);
-
-  // Check the compile status
-  var compiled = gl.getShaderParameter(shader, gl.COMPILE_STATUS);
-  if (!compiled) {
-    // Something went wrong during compilation; get the error
-    lastError = gl.getShaderInfoLog(shader);
-    errFn("*** Error compiling " + glEnumToString(gl, shaderType) + " '" + shader + "':" + lastError);
-    gl.deleteShader(shader);
-    return null;
-  }
-
-  return shader;
-}
-
-/**
- * Loads a shader from a URL.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {file} file The URL of the shader source.
- * @param {number} type The type of shader.
- * @param {function(string): void) opt_errorCallback callback for errors. 
- * @return {!WebGLShader} The created shader.
- */
-var loadShaderFromFile = function(gl, file, type, opt_errorCallback) {
-  var shaderSource = readFile(file);
-  return loadShader(gl, shaderSource, type, opt_errorCallback);
-};
-
-/**
- * Gets the content of script.
- */
-var getScript = function(scriptId) {
-  var shaderScript = document.getElementById(scriptId);
-  if (!shaderScript) {
-    throw("*** Error: unknown script element" + scriptId);
-  }
-  return shaderScript.text;
-};
-
-/**
- * Loads a shader from a script tag.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {string} scriptId The id of the script tag.
- * @param {number} opt_shaderType The type of shader. If not passed in it will
- *     be derived from the type of the script tag.
- * @param {function(string): void) opt_errorCallback callback for errors. 
- * @return {!WebGLShader} The created shader.
- */
-var loadShaderFromScript = function(
-    gl, scriptId, opt_shaderType, opt_errorCallback) {
-  var shaderSource = "";
-  var shaderType;
-  var shaderScript = document.getElementById(scriptId);
-  if (!shaderScript) {
-    throw("*** Error: unknown script element " + scriptId);
-  }
-  shaderSource = shaderScript.text;
-
-  if (!opt_shaderType) {
-    if (shaderScript.type == "x-shader/x-vertex") {
-      shaderType = gl.VERTEX_SHADER;
-    } else if (shaderScript.type == "x-shader/x-fragment") {
-      shaderType = gl.FRAGMENT_SHADER;
-    } else if (shaderType != gl.VERTEX_SHADER && shaderType != gl.FRAGMENT_SHADER) {
-      throw("*** Error: unknown shader type");
-      return null;
-    }
-  }
-
-  return loadShader(
-      gl, shaderSource, opt_shaderType ? opt_shaderType : shaderType,
-      opt_errorCallback);
-};
-
-var loadStandardProgram = function(gl) {
-  var program = gl.createProgram();
-  gl.attachShader(program, loadStandardVertexShader(gl));
-  gl.attachShader(program, loadStandardFragmentShader(gl));
-  linkProgram(gl, program);
-  return program;
-};
-
-/**
- * Loads shaders from files, creates a program, attaches the shaders and links.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {string} vertexShaderPath The URL of the vertex shader.
- * @param {string} fragmentShaderPath The URL of the fragment shader.
- * @param {function(string): void) opt_errorCallback callback for errors. 
- * @return {!WebGLProgram} The created program.
- */
-var loadProgramFromFile = function(
-    gl, vertexShaderPath, fragmentShaderPath, opt_errorCallback) {
-  var program = gl.createProgram();
-  var vs = loadShaderFromFile(
-      gl, vertexShaderPath, gl.VERTEX_SHADER, opt_errorCallback);
-  var fs = loadShaderFromFile(
-      gl, fragmentShaderPath, gl.FRAGMENT_SHADER, opt_errorCallback);
-  if (vs && fs) {
-    gl.attachShader(program, vs);
-    gl.attachShader(program, fs);
-    linkProgram(gl, program, opt_errorCallback);
-  }
-  if (vs) {
-    gl.deleteShader(vs);
-  }
-  if (fs) {
-    gl.deleteShader(fs);
-  }
-  return program;
-};
-
-/**
- * Loads shaders from script tags, creates a program, attaches the shaders and
- * links.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {string} vertexScriptId The id of the script tag that contains the
- *        vertex shader.
- * @param {string} fragmentScriptId The id of the script tag that contains the
- *        fragment shader.
- * @param {function(string): void) opt_errorCallback callback for errors. 
- * @return {!WebGLProgram} The created program.
- */
-var loadProgramFromScript = function loadProgramFromScript(
-    gl, vertexScriptId, fragmentScriptId, opt_errorCallback) {
-  var program = gl.createProgram();
-  gl.attachShader(
-      program,
-      loadShaderFromScript(
-          gl, vertexScriptId, gl.VERTEX_SHADER, opt_errorCallback));
-  gl.attachShader(
-      program,
-      loadShaderFromScript(
-          gl, fragmentScriptId,  gl.FRAGMENT_SHADER, opt_errorCallback));
-  linkProgram(gl, program, opt_errorCallback);
-  return program;
-};
-
-/**
- * Loads shaders from source, creates a program, attaches the shaders and
- * links.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {!WebGLShader} vertexShader The vertex shader.
- * @param {!WebGLShader} fragmentShader The fragment shader.
- * @param {function(string): void) opt_errorCallback callback for errors.
- * @return {!WebGLProgram} The created program.
- */
-var createProgram = function(gl, vertexShader, fragmentShader, opt_errorCallback) {
-  var program = gl.createProgram();
-  gl.attachShader(program, vertexShader);
-  gl.attachShader(program, fragmentShader);
-  linkProgram(gl, program, opt_errorCallback);
-  return program;
-};
-
-/**
- * Loads shaders from source, creates a program, attaches the shaders and
- * links.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {string} vertexShader The vertex shader source.
- * @param {string} fragmentShader The fragment shader source.
- * @param {function(string): void) opt_errorCallback callback for errors. 
- * @return {!WebGLProgram} The created program.
- */
-var loadProgram = function(
-    gl, vertexShader, fragmentShader, opt_errorCallback) {
-  var program;
-  var vs = loadShader(
-      gl, vertexShader, gl.VERTEX_SHADER, opt_errorCallback);
-  var fs = loadShader(
-      gl, fragmentShader, gl.FRAGMENT_SHADER, opt_errorCallback);
-  if (vs && fs) {
-    program = createProgram(gl, vs, fs, opt_errorCallback)
-  }
-  if (vs) {
-    gl.deleteShader(vs);
-  }
-  if (fs) {
-    gl.deleteShader(fs);
-  }
-  return program;
-};
-
-/**
- * Loads shaders from source, creates a program, attaches the shaders and
- * links but expects error.
- *
- * GLSL 1.0.17 10.27 effectively says that compileShader can
- * always succeed as long as linkProgram fails so we can't
- * rely on compileShader failing. This function expects
- * one of the shader to fail OR linking to fail.
- *
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {string} vertexShaderScriptId The vertex shader.
- * @param {string} fragmentShaderScriptId The fragment shader.
- * @return {WebGLProgram} The created program.
- */
-var loadProgramFromScriptExpectError = function(
-    gl, vertexShaderScriptId, fragmentShaderScriptId) {
-  var vertexShader = loadShaderFromScript(gl, vertexShaderScriptId);
-  if (!vertexShader) {
-    return null;
-  }
-  var fragmentShader = loadShaderFromScript(gl, fragmentShaderScriptId);
-  if (!fragmentShader) {
-    return null;
-  }
-  var linkSuccess = true;
-  var program = gl.createProgram();
-  gl.attachShader(program, vertexShader);
-  gl.attachShader(program, fragmentShader);
-  linkSuccess = true;
-  linkProgram(gl, program, function() {
-      linkSuccess = false;
-    });
-  return linkSuccess ? program : null;
-};
-
-
-var getActiveMap = function(gl, program, typeInfo) {
-  var numVariables = gl.getProgramParameter(program, gl[typeInfo.param]);
-  var variables = {};
-  for (var ii = 0; ii < numVariables; ++ii) {
-    var info = gl[typeInfo.activeFn](program, ii);
-    variables[info.name] = {
-      name: info.name,
-      size: info.size,
-      type: info.type,
-      location: gl[typeInfo.locFn](program, info.name)
-    };
-  }
-  return variables;
-};
-
-/**
- * Returns a map of attrib names to info about those
- * attribs
- *
- * eg:
- *    { "attrib1Name":
- *      {
- *        name: "attrib1Name",
- *        size: 1,
- *        type: gl.FLOAT_MAT2,
- *        location: 0
- *      },
- *      "attrib2Name[0]":
- *      {
- *         name: "attrib2Name[0]",
- *         size: 4,
- *         type: gl.FLOAT,
- *         location: 1
- *      },
- *    }
- *
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {WebGLProgram} The program to query for attribs.
- * @return the map.
- */
-var getAttribMap = function(gl, program) {
-  return getActiveMap(gl, program, {
-      param: "ACTIVE_ATTRIBS",
-      activeFn: "getActiveAttrib",
-      locFn: "getAttribLocation"
-  });
-};
-
-/**
- * Returns a map of uniform names to info about those uniform
- *
- * eg:
- *    { "uniform1Name":
- *      {
- *        name: "uniform1Name",
- *        size: 1,
- *        type: gl.FLOAT_MAT2,
- *        location: WebGLUniformLocation
- *      },
- *      "uniform2Name[0]":
- *      {
- *         name: "uniform2Name[0]",
- *         size: 4,
- *         type: gl.FLOAT,
- *         location: WebGLUniformLocation
- *      },
- *    }
- *
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {WebGLProgram} The program to query for uniforms.
- * @return the map.
- */
-var getUniformMap = function(gl, program) {
-  return getActiveMap(gl, program, {
-      param: "ACTIVE_UNIFORMS",
-      activeFn: "getActiveUniform",
-      locFn: "getUniformLocation"
-  });
-};
-
-var basePath;
-var getBasePath = function() {
-  if (!basePath) {
-    var expectedBase = "webgl-test-utils.js";
-    var scripts = document.getElementsByTagName('script');
-    for (var script, i = 0; script = scripts[i]; i++) {
-      var src = script.src;
-      var l = src.length;
-      if (src.substr(l - expectedBase.length) == expectedBase) {
-        basePath = src.substr(0, l - expectedBase.length);
-      }
-    }
-  }
-  return basePath;
-};
-
-var loadStandardVertexShader = function(gl) {
-  return loadShaderFromFile(
-      gl, getBasePath() + "vertexShader.vert", gl.VERTEX_SHADER);
-};
-
-var loadStandardFragmentShader = function(gl) {
-  return loadShaderFromFile(
-      gl, getBasePath() + "fragmentShader.frag", gl.FRAGMENT_SHADER);
-};
-
-/**
- * Loads an image asynchronously.
- * @param {string} url URL of image to load.
- * @param {!function(!Element): void} callback Function to call
- *     with loaded image.
- */
-var loadImageAsync = function(url, callback) {
-  var img = document.createElement('img');
-  img.onload = function() {
-    callback(img);
-  };
-  img.src = url;
-};
-
-/**
- * Loads an array of images.
- * @param {!Array.<string>} urls URLs of images to load.
- * @param {!function(!{string, img}): void} callback. Callback
- *     that gets passed map of urls to img tags.
- */
-var loadImagesAsync = function(urls, callback) {
-  var count = 1;
-  var images = { };
-  function countDown() {
-    --count;
-    if (count == 0) {
-      callback(images);
-    }
-  }
-  function imageLoaded(url) {
-    return function(img) {
-      images[url] = img;
-      countDown();
-    }
-  }
-  for (var ii = 0; ii < urls.length; ++ii) {
-    ++count;
-    loadImageAsync(urls[ii], imageLoaded(urls[ii]));
-  }
-  countDown();
-};
-
-var getUrlArguments = function() {
-  var args = {};
-  try {
-    var s = window.location.href;
-    var q = s.indexOf("?");
-    var e = s.indexOf("#");
-    if (e < 0) {
-      e = s.length;
-    }
-    var query = s.substring(q + 1, e);
-    var pairs = query.split("&");
-    for (var ii = 0; ii < pairs.length; ++ii) {
-      var keyValue = pairs[ii].split("=");
-      var key = keyValue[0];
-      var value = decodeURIComponent(keyValue[1]);
-      args[key] = value;
-    }
-  } catch (e) {
-    throw "could not parse url";
-  }
-  return args;
-};
-
-var makeImage = function(canvas) {
-  var img = document.createElement('img');
-  img.src = canvas.toDataURL();
-  return img;
-};
-
-var insertImage = function(element, caption, img) {
-  var div = document.createElement("div");
-  div.appendChild(img);
-  var label = document.createElement("div");
-  label.appendChild(document.createTextNode(caption));
-  div.appendChild(label);
-   element.appendChild(div);
-};
-
-var addShaderSource = function(element, label, source, opt_url) {
-  var div = document.createElement("div");
-  var s = document.createElement("pre");
-  s.className = "shader-source";
-  s.style.display = "none";
-  var ol = document.createElement("ol");
-  //s.appendChild(document.createTextNode(source));
-  var lines = source.split("\n");
-  for (var ii = 0; ii < lines.length; ++ii) {
-    var line = lines[ii];
-    var li = document.createElement("li");
-    li.appendChild(document.createTextNode(line));
-    ol.appendChild(li);
-  }
-  s.appendChild(ol);
-  var l = document.createElement("a");
-  l.href = "show-shader-source";
-  l.appendChild(document.createTextNode(label));
-  l.addEventListener('click', function(event) {
-      if (event.preventDefault) {
-        event.preventDefault();
-      }
-      s.style.display = (s.style.display == 'none') ? 'block' : 'none';
-      return false;
-    }, false);
-  div.appendChild(l);
-  if (opt_url) {
-    var u = document.createElement("a");
-    u.href = opt_url;
-    div.appendChild(document.createTextNode(" "));
-    u.appendChild(document.createTextNode("(" + opt_url + ")"));
-    div.appendChild(u);
-  }
-  div.appendChild(s);
-  element.appendChild(div);
-};
-
-// Add your prefix here.
-var browserPrefixes = [
-  "",
-  "MOZ_",
-  "OP_",
-  "WEBKIT_"
-];
-
-/**
- * Given an extension name like WEBGL_compressed_texture_s3tc
- * returns the name of the supported version extension, like
- * WEBKIT_WEBGL_compressed_teture_s3tc
- * @param {string} name Name of extension to look for
- * @return {string} name of extension found or undefined if not
- *     found.
- */
-var getSupportedExtensionWithKnownPrefixes = function(gl, name) {
-  var supported = gl.getSupportedExtensions();
-  for (var ii = 0; ii < browserPrefixes.length; ++ii) {
-    var prefixedName = browserPrefixes[ii] + name;
-    if (supported.indexOf(prefixedName) >= 0) {
-      return prefixedName;
-    }
-  }
-};
-
-/**
- * Given an extension name like WEBGL_compressed_texture_s3tc
- * returns the supported version extension, like
- * WEBKIT_WEBGL_compressed_teture_s3tc
- * @param {string} name Name of extension to look for
- * @return {WebGLExtension} The extension or undefined if not
- *     found.
- */
-var getExtensionWithKnownPrefixes = function(gl, name) {
-  for (var ii = 0; ii < browserPrefixes.length; ++ii) {
-    var prefixedName = browserPrefixes[ii] + name;
-    var ext = gl.getExtension(prefixedName);
-    if (ext) {
-      return ext;
-    }
-  }
-};
-
-
-var replaceRE = /\$\((\w+)\)/g;
-
-/**
- * Replaces strings with property values.
- * Given a string like "hello $(first) $(last)" and an object
- * like {first:"John", last:"Smith"} will return
- * "hello John Smith".
- * @param {string} str String to do replacements in
- * @param {...} 1 or more objects conaining properties.
- */
-var replaceParams = function(str) {
-  var args = arguments;
-  return str.replace(replaceRE, function(str, p1, offset, s) {
-    for (var ii = 1; ii < args.length; ++ii) {
-      if (args[ii][p1] !== undefined) {
-        return args[ii][p1];
-      }
-    }
-    throw "unknown string param '" + p1 + "'";
-  });
-};
-
-
-/**
- * Provides requestAnimationFrame in a cross browser way.
- */
-var requestAnimFrameImpl_;
-
-var requestAnimFrame = function(callback, element) {
-  if (!requestAnimFrameImpl_) {
-    requestAnimFrameImpl_ = function() {
-      var functionNames = [
-        "requestAnimationFrame",
-        "webkitRequestAnimationFrame",
-        "mozRequestAnimationFrame",
-        "oRequestAnimationFrame",
-        "msRequestAnimationFrame"
-      ];
-      for (var jj = 0; jj < functionNames.length; ++jj) {
-        var functionName = functionNames[jj];
-        if (window[functionName]) {
-          return function(name) {
-            return function(callback, element) {
-              return window[name].call(window, callback, element);
-            };
-          }(functionName);
-        }
-      }
-      return function(callback, element) {
-           return window.setTimeout(callback, 1000 / 70);
-        };
-    }();
-  }
-
-  return requestAnimFrameImpl_(callback, element);
-};
-
-/**
- * Provides cancelAnimationFrame in a cross browser way.
- */
-var cancelAnimFrame = (function() {
-  return window.cancelAnimationFrame ||
-         window.webkitCancelAnimationFrame ||
-         window.mozCancelAnimationFrame ||
-         window.oCancelAnimationFrame ||
-         window.msCancelAnimationFrame ||
-         window.clearTimeout;
-})();
-
-/**
- * Waits for the browser to composite the canvas associated with
- * the WebGL context passed in.
- */
-var waitForComposite = function(gl, callback) {
-  var frames = 5;
-  var countDown = function() {
-    if (frames == 0) {
-      callback();
-    } else {
-      --frames;
-      requestAnimFrame(countDown);
-    }
-  };
-  countDown();
-};
-
-return {
-  addShaderSource: addShaderSource,
-  cancelAnimFrame: cancelAnimFrame,
-  create3DContext: create3DContext,
-  create3DContextWithWrapperThatThrowsOnGLError:
-      create3DContextWithWrapperThatThrowsOnGLError,
-  checkCanvas: checkCanvas,
-  checkCanvasRect: checkCanvasRect,
-  checkCanvasRectColor: checkCanvasRectColor,
-  createColoredTexture: createColoredTexture,
-  createProgram: createProgram,
-  drawQuad: drawQuad,
-  drawIndexedQuad: drawIndexedQuad,
-  drawUByteColorQuad: drawUByteColorQuad,
-  drawFloatColorQuad: drawFloatColorQuad,
-  endsWith: endsWith,
-  fillTexture: fillTexture,
-  getExtensionWithKnownPrefixes: getExtensionWithKnownPrefixes,
-  getFileListAsync: getFileListAsync,
-  getLastError: getLastError,
-  getScript: getScript,
-  getSupportedExtensionWithKnownPrefixes: getSupportedExtensionWithKnownPrefixes,
-  getUrlArguments: getUrlArguments,
-  getAttribMap: getAttribMap,
-  getUniformMap: getUniformMap,
-  glEnumToString: glEnumToString,
-  glErrorShouldBe: glErrorShouldBe,
-  hasAttributeCaseInsensitive: hasAttributeCaseInsensitive,
-  insertImage: insertImage,
-  loadImageAsync: loadImageAsync,
-  loadImagesAsync: loadImagesAsync,
-  loadProgram: loadProgram,
-  loadProgramFromFile: loadProgramFromFile,
-  loadProgramFromScript: loadProgramFromScript,
-  loadProgramFromScriptExpectError: loadProgramFromScriptExpectError,
-  loadShader: loadShader,
-  loadShaderFromFile: loadShaderFromFile,
-  loadShaderFromScript: loadShaderFromScript,
-  loadStandardProgram: loadStandardProgram,
-  loadStandardVertexShader: loadStandardVertexShader,
-  loadStandardFragmentShader: loadStandardFragmentShader,
-  loadTextFileAsync: loadTextFileAsync,
-  loadTexture: loadTexture,
-  log: log,
-  loggingOff: loggingOff,
-  makeImage: makeImage,
-  error: error,
-  shallowCopyObject: shallowCopyObject,
-  setupColorQuad: setupColorQuad,
-  setupProgram: setupProgram,
-  setupQuad: setupQuad,
-  setupQuadWithOptions: setupQuadWithOptions,
-  setupSimpleColorFragmentShader: setupSimpleColorFragmentShader,
-  setupSimpleColorVertexShader: setupSimpleColorVertexShader,
-  setupSimpleColorProgram: setupSimpleColorProgram,
-  setupSimpleTextureFragmentShader: setupSimpleTextureFragmentShader,
-  setupSimpleTextureProgram: setupSimpleTextureProgram,
-  setupSimpleTextureVertexShader: setupSimpleTextureVertexShader,
-  setupSimpleVertexColorFragmentShader: setupSimpleVertexColorFragmentShader,
-  setupSimpleVertexColorProgram: setupSimpleVertexColorProgram,
-  setupSimpleVertexColorVertexShader: setupSimpleVertexColorVertexShader,
-  setupNoTexCoordTextureProgram: setupNoTexCoordTextureProgram,
-  setupNoTexCoordTextureVertexShader: setupNoTexCoordTextureVertexShader,
-  setupTexturedQuad: setupTexturedQuad,
-  setupTexturedQuadWithTexCoords: setupTexturedQuadWithTexCoords,
-  setupUnitQuad: setupUnitQuad,
-  setupUnitQuadWithTexCoords: setupUnitQuadWithTexCoords,
-  setFloatDrawColor: setFloatDrawColor,
-  setUByteDrawColor: setUByteDrawColor,
-  startsWith: startsWith,
-  shouldGenerateGLError: shouldGenerateGLError,
-  readFile: readFile,
-  readFileList: readFileList,
-  replaceParams: replaceParams,
-  requestAnimFrame: requestAnimFrame,
-  waitForComposite: waitForComposite,
-
-  none: false
-};
-
-}());
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test.js
deleted file mode 100644
index 516244e..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/webgl-test.js
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
-function webglTestLog(msg) {
-  if (window.console && window.console.log) {
-    window.console.log(msg);
-  }
-  if (document.getElementById("console")) {
-    var log = document.getElementById("console");
-    log.innerHTML += msg + "<br>";
-  }
-}
-
-function getGLErrorAsString(ctx, err) {
-  if (err === ctx.NO_ERROR) {
-    return "NO_ERROR";
-  }
-  for (var name in ctx) {
-    if (ctx[name] === err) {
-      return name;
-    }
-  }
-  return "0x" + err.toString(16);
-}
-
-// Pass undefined for glError to test that it at least throws some error
-function shouldGenerateGLError(ctx, glErrors, evalStr) {
-  if (!glErrors.length) {
-    glErrors = [glErrors];
-  }
-  var exception;
-  try {
-    eval(evalStr);
-  } catch (e) {
-    exception = e;
-  }
-  if (exception) {
-    testFailed(evalStr + " threw exception " + exception);
-  } else {
-    var err = ctx.getError();
-    var errStrs = [];
-    for (var ii = 0; ii < glErrors.length; ++ii) {
-      errStrs.push(getGLErrorAsString(ctx, glErrors[ii]));
-    }
-    var expected = errStrs.join(" or ");
-    if (glErrors.indexOf(err) < 0) {
-      testFailed(evalStr + " expected: " + expected + ". Was " + getGLErrorAsString(ctx, err) + ".");
-    } else {
-      var msg = (glErrors.length == 1) ? " generated expected GL error: " :
-                                         " generated one of expected GL errors: ";
-      testPassed(evalStr + msg + expected + ".");
-    }
-  }
-}
-
-/**
- * Tests that the first error GL returns is the specified error.
- * @param {!WebGLContext} gl The WebGLContext to use.
- * @param {number|!Array.<number>} glError The expected gl
- *        error. Multiple errors can be passed in using an
- *        array.
- * @param {string} opt_msg Optional additional message.
- */
-function glErrorShouldBe(gl, glErrors, opt_msg) {
-  if (!glErrors.length) {
-    glErrors = [glErrors];
-  }
-  opt_msg = opt_msg || "";
-  var err = gl.getError();
-  var ndx = glErrors.indexOf(err);
-  var errStrs = [];
-  for (var ii = 0; ii < glErrors.length; ++ii) {
-    errStrs.push(getGLErrorAsString(gl, glErrors[ii]));
-  }
-  var expected = errStrs.join(" or ");
-  if (ndx < 0) {
-    var msg = "getError expected" + ((glErrors.length > 1) ? " one of: " : ": ");
-    testFailed(msg + expected +  ". Was " + getGLErrorAsString(gl, err) + " : " + opt_msg);
-  } else {
-    var msg = "getError was " + ((glErrors.length > 1) ? "one of: " : "expected value: ");
-    testPassed(msg + expected + " : " + opt_msg);
-  }
-};
-
-
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/zero-alpha.png b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/zero-alpha.png
deleted file mode 100644
index e55630c..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/resources/zero-alpha.png
+++ /dev/null
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/00_test_list.txt b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/00_test_list.txt
deleted file mode 100644
index 369a268..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/00_test_list.txt
+++ /dev/null
@@ -1,50 +0,0 @@
-compressed-tex-image.html
-copy-tex-image-and-sub-image-2d.html
---min-version 1.0.2 copy-tex-image-2d-formats.html
---min-version 1.0.2 gl-get-tex-parameter.html
-gl-pixelstorei.html
-gl-teximage.html
-origin-clean-conformance.html
-tex-image-and-sub-image-2d-with-array-buffer-view.html
-tex-image-and-sub-image-2d-with-canvas.html
-tex-image-and-sub-image-2d-with-canvas-rgb565.html
-tex-image-and-sub-image-2d-with-canvas-rgba4444.html
-tex-image-and-sub-image-2d-with-canvas-rgba5551.html
-tex-image-and-sub-image-2d-with-image-data.html
-tex-image-and-sub-image-2d-with-image-data-rgb565.html
-tex-image-and-sub-image-2d-with-image-data-rgba4444.html
-tex-image-and-sub-image-2d-with-image-data-rgba5551.html
-tex-image-and-sub-image-2d-with-image.html
-tex-image-and-sub-image-2d-with-image-rgb565.html
-tex-image-and-sub-image-2d-with-image-rgba4444.html
-tex-image-and-sub-image-2d-with-image-rgba5551.html
-tex-image-and-sub-image-2d-with-video.html
-tex-image-and-sub-image-2d-with-video-rgb565.html
-tex-image-and-sub-image-2d-with-video-rgba4444.html
-tex-image-and-sub-image-2d-with-video-rgba5551.html
-tex-image-and-uniform-binding-bugs.html
---min-version 1.0.2 tex-image-webgl.html
-tex-image-with-format-and-type.html
-tex-image-with-invalid-data.html
-tex-input-validation.html
-tex-sub-image-2d-bad-args.html
-tex-sub-image-2d.html
-texparameter-test.html
-texture-active-bind-2.html
-texture-active-bind.html
---min-version 1.0.2 texture-attachment-formats.html
---min-version 1.0.2 texture-clear.html
-texture-complete.html
---min-version 1.0.2 texture-hd-dpi.html
---min-version 1.0.2 texture-formats-test.html
-texture-mips.html
-texture-npot-video.html
-texture-npot.html
-texture-size.html
-texture-size-cube-maps.html
---min-version 1.0.2 texture-size-limit.html
---min-version 1.0.2 texture-sub-image-cube-maps.html
-texture-transparent-pixels-initialized.html
---min-version 1.0.2 texture-upload-cube-maps.html
---min-version 1.0.2 mipmap-fbo.html
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/compressed-tex-image.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/compressed-tex-image.html
deleted file mode 100644
index 0e7b92c..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/compressed-tex-image.html
+++ /dev/null
@@ -1,83 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL CompressedTexImage and CompressedTexSubImage Tests</title>
-<LINK rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description("This test ensures WebGL implementations correctly implement compressedTexImage2D and compressedTexSubImage2D.");
-
-debug("");
-
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext();
-
-var COMPRESSED_RGB_S3TC_DXT1_EXT        = 0x83F0;
-var COMPRESSED_RGBA_S3TC_DXT1_EXT       = 0x83F1;
-var COMPRESSED_RGBA_S3TC_DXT5_EXT       = 0x83F3;
-var ETC1_RGB8_OES                       = 0x8D64;
-var COMPRESSED_RGB_PVRTC_4BPPV1_IMG     = 0x8C00;
-var COMPRESSED_RGBA_PVRTC_4BPPV1_IMG    = 0x8C02;
-
-var formats = null;
-
-if (!gl) {
-  testFailed("context does not exist");
-} else {
-  testPassed("context exists");
-
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-
-  shouldGenerateGLError(gl, gl.INVALID_ENUM, "gl.compressedTexImage2D(gl.TEXTURE_2D, 0, COMPRESSED_RGB_S3TC_DXT1_EXT, 4, 4, 0, new Uint8Array(8))");
-  shouldGenerateGLError(gl, gl.INVALID_ENUM, "gl.compressedTexImage2D(gl.TEXTURE_2D, 0, COMPRESSED_RGBA_S3TC_DXT1_EXT, 4, 4, 0, new Uint8Array(8))");
-  shouldGenerateGLError(gl, gl.INVALID_ENUM, "gl.compressedTexImage2D(gl.TEXTURE_2D, 0, COMPRESSED_RGBA_S3TC_DXT5_EXT, 4, 4, 0, new Uint8Array(16))");
-  shouldGenerateGLError(gl, gl.INVALID_ENUM, "gl.compressedTexImage2D(gl.TEXTURE_2D, 0, ETC1_RGB8_OES, 4, 4, 0, new Uint8Array(8))");
-  shouldGenerateGLError(gl, gl.INVALID_ENUM, "gl.compressedTexImage2D(gl.TEXTURE_2D, 0, COMPRESSED_RGB_PVRTC_4BPPV1_IMG, 8, 8, 0, new Uint8Array(8))");
-  shouldGenerateGLError(gl, gl.INVALID_ENUM, "gl.compressedTexImage2D(gl.TEXTURE_2D, 0, COMPRESSED_RGBA_PVRTC_4BPPV1_IMG, 8, 8, 0, new Uint8Array(8))");
-
-  shouldGenerateGLError(gl, gl.NO_ERROR, "formats = gl.getParameter(gl.COMPRESSED_TEXTURE_FORMATS)");
-  shouldBeNonNull("formats");
-  shouldBe("formats.length", "0");
-}
-
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-2d-formats.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-2d-formats.html
deleted file mode 100644
index 212cd3f..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-2d-formats.html
+++ /dev/null
@@ -1,183 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<title>Verify copyTexImage2D follows format restictions</title>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<div id="description"></div>
-<canvas id="canvas" width="2" height="2"></canvas>
-<canvas id="canvasNoAlpha" width="2" height="2"></canvas>
-<div id="console"></div>
-<script>
-"use strict";
-
-function getChannelsFromFormat(format) {
-  switch (gl[format]) {
-  case gl.ALPHA:
-    return 0x0001;
-  case gl.LUMINANCE:
-  case gl.RGB:
-    return 0x1110;
-  case gl.LUMINANCE_ALPHA:
-  case gl.RGBA:
-    return 0x1111;
-  default:
-    return 0;
-  }
-}
-
-var formats = [
-  'ALPHA',
-  'LUMINANCE',
-  'LUMINANCE_ALPHA',
-  'RGB',
-  'RGBA'
-];
-
-var gl = null;
-var wtu = WebGLTestUtils;
-
-description();
-
-var canvas = document.getElementById("canvas");
-var canvasNoAlpha = document.getElementById("canvasNoAlpha");
-var gl = wtu.create3DContext(canvas, {alpha:true});
-var glNoAlpha = wtu.create3DContext(canvasNoAlpha, {alpha:false});
-
-debug("test with an RGBA backbuffer");
-var program = wtu.setupTexturedQuad(gl);
-glErrorShouldBe(gl, gl.NO_ERROR, "During Initialization");
-testFormats('RGBA');
-
-testBackbufferFormats();
-
-debug("test with an RGB backbuffer");
-var gl = glNoAlpha;
-var program = wtu.setupTexturedQuad(gl);
-glErrorShouldBe(gl, gl.NO_ERROR, "During Initialization");
-testFormats('RGB');
-
-function testBackbufferFormats() {
-  var fbo = gl.createFramebuffer();
-  gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);
-
-  for (var ii = 0; ii < formats.length; ++ii) {
-    var backFormat = formats[ii];
-
-    var tex = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, tex);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl[backFormat], 2, 2, 0, gl[backFormat], gl.UNSIGNED_BYTE, null);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-
-    gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, tex, 0);
-    var status = gl.checkFramebufferStatus(gl.FRAMEBUFFER);
-
-    debug('');
-    if (status == gl.FRAMEBUFFER_COMPLETE) {
-      debug('test with ' + backFormat + ' fbo');
-      testFormats(backFormat);
-    } else {
-      debug(backFormat + ' not supported as a renderbuffer attachment');
-    }
-  }
-}
-
-function testFormats(backFormat) {
-  for (var ii = 0; ii < formats.length; ++ii) {
-    testCopyTexImage2D(backFormat, formats[ii]);
-  }
-}
-
-function toChannels(value) {
-  return ((value & 0x1000) ? 'R' : '_') +
-         ((value & 0x0100) ? 'G' : '_') +
-         ((value & 0x0010) ? 'B' : '_') +
-         ((value & 0x0001) ? 'A' : '_');
-}
-
-function testCopyTexImage2D(backFormat, texFormat) {
-  var need = getChannelsFromFormat(texFormat);
-  var have = getChannelsFromFormat(backFormat);
-  var shouldPass = (need & have) == need
-
-  //debug("need: " + toChannels(need));
-  //debug("have: " + toChannels(have));
-  //debug("both: " + toChannels(have & need));
-
-  // clear backbuffer
-  gl.clearColor(0.25, 1, 0.75, 0.5);
-  gl.clear(gl.COLOR_BUFFER_BIT);
-
-  var texture = gl.createTexture();
-  // Bind the texture to texture unit 0
-  gl.bindTexture(gl.TEXTURE_2D, texture);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-
-  gl.copyTexImage2D(gl.TEXTURE_2D, 0, gl[texFormat], 0, 0, 2, 2, 0);
-  if (!shouldPass) {
-    glErrorShouldBe(
-        gl, gl.INVALID_OPERATION,
-        "should not be able to copyTexImage2D " + texFormat + " from " + backFormat);
-    return;
-  }
-
-  glErrorShouldBe(
-      gl, gl.NO_ERROR,
-      "should be able to copyTexImage2D " + texFormat + " from " + backFormat);
-
-  // Draw
-  wtu.clearAndDrawUnitQuad(gl);
-
-  var expectedColors = {
-    'ALPHA': [0, 0, 0, 127],
-    'LUMINANCE': [64, 64, 64, 255],
-    'LUMINANCE_ALPHA': [64, 64, 64, 127],
-    'RGB': [64, 255, 191, 255],
-    'RGBA': [64, 255, 191, 127]
-  };
-
-  var color = expectedColors[texFormat];
-
-  wtu.checkCanvas(gl, color, "should be " + color, 16);
-
-  glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-}
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-and-sub-image-2d.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-and-sub-image-2d.html
deleted file mode 100644
index f5eb8f9..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/copy-tex-image-and-sub-image-2d.html
+++ /dev/null
@@ -1,157 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-
-<script>
-"use strict";
-var successfullyParsed = false;
-
-function init()
-{
-    initTestingHarnessWaitUntilDone();
-
-    description('Verify copyTexImage2D and copyTexSubImage2D');
-
-    runTest();
-}
-
-var gl = null;
-var wtu = WebGLTestUtils;
-
-function runTestIteration(antialias)
-{
-    var canvas = document.getElementById(
-        antialias ? "antialiasOn" : "antialiasOff");
-    var attribs = antialias ? { antialias: true } : { antialias: false };
-    gl = wtu.create3DContext(canvas, attribs);
-    var program = wtu.setupTexturedQuad(gl);
-    var textureLoc = gl.getUniformLocation(program, "tex");
-    glErrorShouldBe(gl, gl.NO_ERROR, "During Initialization");
-
-    gl.colorMask(1, 1, 1, 1);
-    gl.disable(gl.BLEND);
-    debug('Testing copyTexImage2D');
-
-    // Red canvas
-    gl.clearColor(1, 0, 0, 1);
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-
-    var texture = gl.createTexture();
-    // Bind the texture to texture unit 0
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-    // Set up texture
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 2, 2, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-    gl.uniform1i(textureLoc, 0);
-
-    var colors = [
-      [1, 0, 0, 1],
-      [0, 1, 0, 1],
-      [0, 0, 1, 1],
-      [0.5, 0.5, 0.5, 0.5],
-    ];
-    var count = 0;
-    for (var yy = -2; yy <= 2; ++yy) {
-      for (var xx = -2; xx <= 2; ++xx) {
-         for (var ii = 0; ii < 2; ++ii) {
-          var texColor = colors[count];
-          var clearColor = colors[(count + 1) % colors.length];
-          // clear to some color
-          gl.clearColor(texColor[0], texColor[1], texColor[2], texColor[3]);
-          gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-
-          // copy that color to the texture.
-          switch (ii) {
-          case 0:
-            gl.copyTexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, xx, yy, 2, 2, 0);
-            glErrorShouldBe(gl, gl.NO_ERROR,
-                "using copyTexImage2D: x =" + xx + ", y = " + yy);
-            break;
-          case 1:
-            gl.copyTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, xx, yy, 2, 2);
-            glErrorShouldBe(gl, gl.NO_ERROR,
-                "using copyTexSubImage2D: x =" + xx + ", y = " + yy);
-            break;
-          }
-
-          // clear to some other color.
-          gl.clearColor(clearColor[0], clearColor[1], clearColor[2], clearColor[3]);
-          gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-
-          // Draw the triangles
-          wtu.clearAndDrawUnitQuad(gl);
-
-          // check the rendering results
-          for (var iy = 0; iy < 2; ++iy) {
-            for (var ix = 0; ix < 2; ++ix) {
-              var x = xx + ix;
-              var y = yy + iy;
-              var expectedColor = (x < 0 || y < 0 || x >= 2 || y >= 2) ?
-                  [0,0,0,0] :
-                  [Math.floor(255 * texColor[0]),
-                   Math.floor(255 * texColor[1]),
-                   Math.floor(255 * texColor[2]),
-                   Math.floor(255 * texColor[3])];
-              wtu.checkCanvasRect(gl, ix, iy, 1, 1, expectedColor,
-                  "" + ix + ", " + iy + " should render " + expectedColor + " (+/-1)", 1);
-            }
-          }
-          count = (count + 1) % colors.length;
-        }
-      }
-    }
-
-    debug("");
-}
-
-function runTest(antialias)
-{
-    debug("Testing with antialias on");
-    runTestIteration(true);
-    debug("Testing with antialias off");
-    runTestIteration(false);
-
-    finishTest();
-}
-</script>
-</head>
-<body onload="init()">
-<canvas id="antialiasOn" width="2" height="2"></canvas>
-<canvas id="antialiasOff" width="2" height="2"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-get-tex-parameter.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-get-tex-parameter.html
deleted file mode 100644
index e9cdf5d..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-get-tex-parameter.html
+++ /dev/null
@@ -1,135 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL getTexParameter test</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="4" height="4" style="width: 40px; height: 30px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description();
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("example");
-
-// NOTE: We explicitly do this in a funky order
-// to hopefully find subtle bugs.
-
-var targets = [
-  'TEXTURE_2D',
-  'TEXTURE_2D',
-  'TEXTURE_CUBE_MAP',
-  'TEXTURE_CUBE_MAP'
-];
-// Create textures on different active textures.
-for (var ii = 0; ii < targets.length; ++ii) {
-  var target = targets[ii];
-  var tex = gl.createTexture();
-  gl.activeTexture(gl.TEXTURE0 + ii);
-  gl.bindTexture(gl[target], tex);
-}
-
-glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-
-var states = [
-  { state:'TEXTURE_WRAP_S',     default: 'REPEAT',                value1: 'CLAMP_TO_EDGE',        value2: 'REPEAT'        },
-  { state:'TEXTURE_WRAP_T',     default: 'REPEAT',                value1: 'CLAMP_TO_EDGE',        value2: 'REPEAT'        },
-  { state:'TEXTURE_MAG_FILTER', default: 'LINEAR',                value1: 'NEAREST',              value2: 'LINEAR'        },
-  { state:'TEXTURE_MIN_FILTER', default: 'NEAREST_MIPMAP_LINEAR', value1: 'LINEAR_MIPMAP_LINEAR', value2: 'NEAREST'       }
-];
-
-function applyStates(fn) {
-  for (var ss = 0; ss < states.length; ++ss) {
-    var stateInfo = states[ss];
-    for (var ii = 0; ii < targets.length; ++ii) {
-	  var target = targets[ii];
-      gl.activeTexture(gl.TEXTURE0 + ii);
-      fn(target, stateInfo);
-    }
-  }
-}
-
-// test the default state.
-applyStates(function(target, stateInfo) {
-  var a = 'gl.getTexParameter(gl["' + target + '"], gl["' + stateInfo.state + '"])';
-  var b = 'gl["' + stateInfo.default + '"]';
-  shouldBe(a, b);
-});
-
-// test new state
-applyStates(function(target, stateInfo) {
-  gl.texParameteri(gl[target], gl[stateInfo.state], gl[stateInfo.value1]);
-});
-
-applyStates(function(target, stateInfo) {
-  var a = 'gl.getTexParameter(gl["' + target + '"], gl["' + stateInfo.state + '"])';
-  var b = 'gl["' + stateInfo.value1 + '"]';
-  shouldBe(a, b);
-});
-
-// test different states on each target.
-function getStateValue(count, stateInfo) {
-  return (count % 2) ? stateInfo.value2 : stateInfo.value1;
-}
-
-applyStates(function() {
-  var count = 0;
-  return function(target, stateInfo) {
-    gl.texParameteri(gl[target], gl[stateInfo.state], gl[getStateValue(count, stateInfo)]);
-    ++count;
-  }
-}());
-
-applyStates(function() {
-  var count = 0;
-  return function(target, stateInfo) {
-    var a = 'gl.getTexParameter(gl["' + target + '"], gl["' + stateInfo.state + '"])';
-    var b = 'gl["' + getStateValue(count, stateInfo) + '"]';
-    shouldBe(a, b);
-    ++count;
-  };
-}());
-
-glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-pixelstorei.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-pixelstorei.html
deleted file mode 100644
index dc0c451..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-pixelstorei.html
+++ /dev/null
@@ -1,119 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL pixelStorei Test</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"> </script>
-<script src="../../resources/desktop-gl-constants.js" type="text/javascript"></script>
-</head>
-<body>
-<canvas id="example" width="50" height="50"></canvas>
-<canvas id="2d00" width="50" height="50"></canvas>
-<canvas id="2d01" width="50" height="50"></canvas>
-<canvas id="2d02" width="50" height="50"></canvas>
-<canvas id="2d03" width="50" height="50"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-attribute vec4 vPosition;
-void main() {
-  gl_Position = vPosition;
-}
-</script>
-
-<script id="fshader" type="x-shader/x-fragment">
-void main() {
-  gl_FragColor = vec4(1.0,0.0,0.0,1.0);
-}
-</script>
-
-<script>
-"use strict";
-function init() {
-  description("This test checks that drawImage and readPixels are not effected by gl.Pixelstorei(gl.PACK_ALIGNMENT) and visa versa");
-
-  debug("There should be 5 red triangles on 5 black squares above");
-  debug("");
-
-  var wtu = WebGLTestUtils;
-  var canvas3d = document.getElementById("example");
-  var gl = wtu.create3DContext("example");
-  var program = wtu.setupProgram(gl, ["vshader", "fshader"], ["vPosition"]);
-
-  var vertexObject = gl.createBuffer();
-  gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
-  gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([ 0,0.5,0, -0.5,-0.5,0, 0.5,-0.5,0 ]), gl.STATIC_DRAW);
-  gl.enableVertexAttribArray(0);
-  gl.vertexAttribPointer(0, 3, gl.FLOAT, false, 0, 0);
-
-  gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-  gl.drawArrays(gl.TRIANGLES, 0, 3);
-
-  function checkData(ctx, name) {
-    // Test several locations
-    // First line should be all black
-    wtu.checkCanvasRect(ctx, 0, 0, 50, 1, [0, 0, 0, 0]);
-
-    // Line 25 should be red for at least 6 red pixels starting 22 pixels in
-    wtu.checkCanvasRect(ctx, 22, 25, 6, 1, [255, 0, 0, 255]);
-
-    // Last line should be all black
-    wtu.checkCanvasRect(ctx, 0, 49, 50, 1, [0, 0, 0, 0]);
-  }
-
-  var ctx2d;
-
-  function checkColors() {
-    checkData(gl, "3d context");
-    checkData(ctx2d, "2d context");
-  }
-
-  var table = [1, 2, 4, 8];
-  for (var ii = 0; ii < table.length; ++ii) {
-    gl.pixelStorei(gl.PACK_ALIGNMENT, table[ii]);
-    ctx2d = document.getElementById("2d0" + ii).getContext("2d");
-    ctx2d.globalCompositeOperation = 'copy';
-    ctx2d.drawImage(canvas3d, 0, 0);
-    checkColors();
-    assertMsg(gl.getParameter(gl.PACK_ALIGNMENT) == table[ii],
-        "PACK_ALIGNMENT is " + table[ii]);
-  }
-}
-
-init();
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-teximage.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-teximage.html
deleted file mode 100644
index b296032..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/gl-teximage.html
+++ /dev/null
@@ -1,446 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL texImage2D conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="256" height="16" style="width: 256px; height: 48px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description("Test texImage2D conversions.");
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("example");
-gl.disable(gl.DITHER);
-var program = wtu.setupTexturedQuad(gl);
-var successfullyParsed;
-
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-var imgURLs = [
-  '../resources/gray-ramp-256-with-128-alpha.png',
-  '../resources/gray-ramp-256.png',
-  '../resources/gray-ramp-default-gamma.png',
-  '../resources/gray-ramp-gamma0.1.png',
-  '../resources/gray-ramp-gamma1.0.png',
-  '../resources/gray-ramp-gamma2.0.png',
-  '../resources/gray-ramp-gamma4.0.png',
-  '../resources/gray-ramp-gamma9.0.png',
-  '../resources/gray-ramp.png',
-  '../resources/zero-alpha.png',
-  '../resources/3x3.png',
-  '../resources/blue-1x1.jpg',
-  '../resources/red-indexed.png',
-  '../resources/green-2x2-16bit.png',
-  '../resources/small-square-with-colorspin-profile.jpg',
-  '../resources/small-square-with-colorspin-profile.png',
-  '../resources/small-square-with-cie-rgb-profile.png',
-  '../resources/small-square-with-colormatch-profile.png',
-  '../resources/small-square-with-e-srgb-profile.png',
-  '../resources/small-square-with-smpte-c-profile.png',
-  '../resources/small-square-with-srgb-iec61966-2.1-profile.png'];
-
-
-wtu.loadImagesAsync(imgURLs, runTests);
-
-function runTests(imgs) {
-  var loc = gl.getUniformLocation(program, "tex");
-  gl.uniform1i(loc, 0);
-
-  gl.disable(gl.BLEND);
-  gl.disable(gl.DEPTH_TEST);
-
-  var width = gl.canvas.width;
-  var height = gl.canvas.height;
-
-  function checkPixel(buf, x, y, color) {
-    var off = (y * width + x) * 4;
-    var msg = "pixel " + x + ", " + y + " should be " +
-              color[0] + ", " +
-              color[1] + ", " +
-              color[2] + ", " +
-              color[3] + " was " +
-              buf[off + 0] + ", " +
-              buf[off + 1] + ", " +
-              buf[off + 2] + ", " +
-              buf[off + 3];
-
-    for (var ii = 0; ii < 4; ++ii) {
-      if (buf[off + ii] != color[ii]) {
-        testFailed(msg);
-        return;
-      }
-    }
-    testPassed(msg);
-  }
-
-  function checkPixelRange(buf, x, y, color, allowedRange) {
-    var off = (y * width + x) * 4;
-    var msg = "pixel " + x + ", " + y + " should be within " +
-              allowedRange + " units of " +
-              color[0] + ", " +
-              color[1] + ", " +
-              color[2] + ", " +
-              color[3];
-    var subMsg = " was " +
-              buf[off + 0] + ", " +
-              buf[off + 1] + ", " +
-              buf[off + 2] + ", " +
-              buf[off + 3];
-    // When running in WebKit's test harness, we don't want to print the
-    // pixel value when the test passes, because different machines might
-    // have different results and we record the text output.
-    var inDumpRenderTree = window.layoutTestController;
-    for (var ii = 0; ii < 4; ++ii) {
-      if (Math.abs(buf[off + ii] - color[ii]) > allowedRange) {
-        testFailed(msg + subMsg);
-        return;
-      }
-    }
-    testPassed(msg + (inDumpRenderTree ? "" : subMsg));
-  }
-
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-
-  var buf = new Uint8Array(width * height * 4);
-
-  debug("");
-  debug("check pixels are NOT pre-multiplied");
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                imgs['../resources/zero-alpha.png']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-
-  var left = 0;
-  var middle = Math.floor(width / 2);
-  var right = width - 1;
-  var bottom = 0;
-  var center = Math.floor(height / 2);
-  var top = height - 1;
-  checkPixel(buf, left,   top,    [  0,   0,   0, 255]);
-  checkPixel(buf, middle, top,    [255,   0, 255, 255]);
-  checkPixel(buf, right,  top,    [  0,   0, 255, 255]);
-  checkPixel(buf, left,   center, [128, 128, 128, 255]);
-  checkPixel(buf, middle, center, [255, 255, 255, 255]);
-  checkPixel(buf, right,  center, [  0, 255, 255, 255]);
-  checkPixel(buf, left,   bottom, [255,   0,   0, 255]);
-  checkPixel(buf, middle, bottom, [255, 255,   0, 255]);
-  checkPixel(buf, right,  bottom, [  0, 255,   0, 255]);
-
-  debug("");
-  debug("check quantization");
-  var quantInfo = [
-    {format: gl.RGBA, type: gl.UNSIGNED_BYTE,          counts: [256, 256, 256, 256]},
-    {format: gl.RGBA, type: gl.UNSIGNED_SHORT_4_4_4_4, counts: [ 16,  16,  16,  16]},
-    {format: gl.RGB,  type: gl.UNSIGNED_SHORT_5_6_5,   counts: [ 32,  64,  32,   1]},
-    {format: gl.RGBA, type: gl.UNSIGNED_SHORT_5_5_5_1, counts: [ 32,  32,  32,   2]}];
-  for (var qq = 0; qq < quantInfo.length; ++qq) {
-    var info = quantInfo[qq];
-    gl.texImage2D(
-        gl.TEXTURE_2D, 0, info.format, info.format, info.type,
-        imgs['../resources/gray-ramp-256.png']);
-    glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-    wtu.clearAndDrawUnitQuad(gl);
-    gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-    var counts = [{ }, { }, { }, { }];
-    var numUniqueValues = [0, 0, 0, 0];
-    // Count the number of unique values in each channel.
-    for (var ii = 0; ii < width * height * 4; ii += 4) {
-      for (var jj = 0; jj < 4; ++jj) {
-        var v = buf[ii + jj];
-        if (!counts[jj][v]) {
-          counts[jj][v] = 1;
-          ++numUniqueValues[jj];
-        } else {
-          ++counts[jj][v];
-        }
-      }
-    }
-    for (var ii = 0; ii < 4; ++ii) {
-      assertMsg(numUniqueValues[ii] == info.counts[ii],
-                "There should be " + info.counts[ii] +
-                " unique values in channel " + ii + ". Found " +
-                numUniqueValues[ii]);
-    }
-  }
-
-  debug("");
-  debug("Check that gamma settings don't effect 8bit pngs");
-  gl.pixelStorei(gl.UNPACK_COLORSPACE_CONVERSION_WEBGL, gl.NONE);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                imgs['../resources/gray-ramp-default-gamma.png']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-  wtu.clearAndDrawUnitQuad(gl);
-  var ref = new Uint8Array(width * height * 4);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, ref);
-
-  var gammaImages = [
-    '../resources/gray-ramp-gamma0.1.png',
-    '../resources/gray-ramp-gamma1.0.png',
-    '../resources/gray-ramp-gamma2.0.png',
-    '../resources/gray-ramp-gamma4.0.png',
-    '../resources/gray-ramp-gamma9.0.png'];
-  for (var ii = 0; ii < gammaImages.length; ++ii) {
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                  imgs[gammaImages[ii]]);
-    wtu.clearAndDrawUnitQuad(gl);
-    gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-    var same = true;
-    for (var jj = 0; jj < width * height * 4; ++jj) {
-      if (buf[jj] != ref[jj]) {
-        same = false;
-        break;
-      }
-    }
-    assertMsg(same, "pixels should be same regardless of gamma settings.");
-  }
-
-  debug("");
-  debug("check pixels are UN pre-multiplied");
-  for (var ii = 0; ii < 2; ++ii) {
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
-    if (ii == 0) {
-      var canvas2d = document.createElement("canvas");
-      canvas2d.width = 256;
-      canvas2d.height = 1;
-      var ctx = canvas2d.getContext("2d");
-      ctx.drawImage(imgs['../resources/gray-ramp-256-with-128-alpha.png'], 0, 0);
-      gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE, canvas2d);
-    } else {
-      gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                    imgs['../resources/gray-ramp-256-with-128-alpha.png']);
-    }
-    glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-    wtu.clearAndDrawUnitQuad(gl);
-    var buf = new Uint8Array(width * height * 4);
-    gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-    var lt128Count = [0, 0, 0];
-    var ge128Count = [0, 0, 0];
-    for (var jj = 0; jj < width; ++jj) {
-      var off = jj * 4;
-      for (var cc = 0; cc < 3; ++cc) {
-        if (buf[off + cc] < 128) {
-          ++lt128Count[cc];
-        } else {
-          ++ge128Count[cc];
-        }
-      }
-    }
-    // Not sure the exact count here because gamma does effect drawing into the
-    // canvas but it should be close to 50% so I'll pass 45%
-    for (var jj = 0; jj < 3; ++jj) {
-      assertMsg(ge128Count[jj] > 256 * 0.45,
-                "Half the pixels in channel " + jj +
-                " should be >= 128,128,128. found " +
-                ((ge128Count[jj] / 256) * 100).toFixed() + "%");
-      assertMsg(lt128Count[jj] > 256 * 0.45,
-                "Half the pixels in channel " + jj +
-                " should be < 128,128,128. found " +
-                ((lt128Count[jj] / 256) * 100).toFixed() + "%");
-    }
-  }
-
-  debug("");
-  debug("check canvas pixels are UN pre-multiplied");
-  var canvas2d = document.createElement("canvas");
-  canvas2d.width = 1;
-  canvas2d.height = 1;
-  var ctx = canvas2d.getContext("2d");
-  ctx.fillStyle ="rgba(255,255,255,0.5)";
-  ctx.fillRect(0, 0, 256, 1);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas2d);
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-  checkPixelRange(buf, 0, 0, [255, 255, 255, 127], 4);
-
-  debug("");
-  debug("check canvas pixels are pre-multiplied");
-  gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, true);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas2d);
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-  checkPixelRange(buf, 0, 0, [127, 127, 127, 127], 4);
-
-
-  debug("");
-  debug("check pixels are pre-multiplied");
-  gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, true);
-  // TODO(gman): use different texture that won't pass on failure
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE,
-                imgs['../resources/zero-alpha.png']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-
-  var same = true;
-  for (var jj = 0; jj < width * height * 4; ++jj) {
-    if (buf[jj] != 0) {
-      same = false;
-      break;
-    }
-  }
-  assertMsg(same, "pixels should all be 0.");
-
-  debug("");
-  debug("check pixels are flipped");
-  gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, false);
-  gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, true);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                imgs['../resources/3x3.png']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-
-  checkPixel(buf, left,   top,    [255,   0,   0, 255]);
-  checkPixel(buf, middle, top,    [255, 255,   0, 255]);
-  checkPixel(buf, right,  top,    [255,   0,   0, 255]);
-  checkPixel(buf, left,   center, [255,   0, 255, 255]);
-  checkPixel(buf, middle, center, [255,   0,   0, 255]);
-  checkPixel(buf, right,  center, [  0, 255,   0, 255]);
-  checkPixel(buf, left,   bottom, [  0,   0,   0, 255]);
-  checkPixel(buf, middle, bottom, [  0,   0, 255, 255]);
-  checkPixel(buf, right,  bottom, [255,   0,   0, 255]);
-
-  debug("");
-  debug("check uploading of images with no alpha channel works");
-  gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, false);
-  gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, false);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                imgs['../resources/blue-1x1.jpg']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  checkPixelRange(buf, middle, center, [   0,   0, 255, 255], 10);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors");
-
-  debug("");
-  debug("check uploading of 16-bit images");
-  gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, false);
-  gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, false);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                imgs['../resources/green-2x2-16bit.png']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  checkPixelRange(buf, middle, center, [   15, 121,   0, 255], 10);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors");
-
-  debug("");
-  debug("check uploading of images with ICC profiles");
-  gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, false);
-  gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, false);
-  gl.pixelStorei(gl.UNPACK_COLORSPACE_CONVERSION_WEBGL, gl.NONE);
-
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                imgs['../resources/small-square-with-colorspin-profile.jpg']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  // The image is red.  However, if we ignore the color profile, it is blue.
-  checkPixelRange(buf, middle, center, [ 0, 0, 255, 255], 10);
-
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                imgs['../resources/small-square-with-colorspin-profile.png']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  // The image is red.  However, if we ignore the color profile, it is blue.
-  checkPixelRange(buf, middle, center, [ 0, 0, 255, 255], 10);
-
-  var iccPNGs = [
-    '../resources/small-square-with-cie-rgb-profile.png',
-    '../resources/small-square-with-colormatch-profile.png',
-    '../resources/small-square-with-e-srgb-profile.png',
-    '../resources/small-square-with-smpte-c-profile.png',
-    '../resources/small-square-with-srgb-iec61966-2.1-profile.png'];
-  for (var ii = 0; ii < iccPNGs.length; ++ii) {
-    var buf2 = new Uint8Array(width * height * 4);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                  imgs[iccPNGs[ii]]);
-    glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-    wtu.clearAndDrawUnitQuad(gl);
-    gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf2);
-    glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors");
-    var same = true;
-    for (var jj = 0; jj < buf.length; ++jj) {
-      if (buf[jj] != buf2[jj]) {
-        same = false;
-        break;
-      }
-    }
-    assertMsg(same, "uploading PNGs with same data but various ICC profiles should generate the same results");
-  }
-
-  debug("");
-  debug("check uploading of indexed PNG images");
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE,
-                imgs['../resources/red-indexed.png']);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  // The image should be red.
-  checkPixelRange(buf, middle, center, [ 255, 0, 0, 255 ], 10);
-
-  debug("")
-  debug("check calling texImage2D with NULL clears the texture");
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB,
-                imgs['../resources/red-indexed.png'].width,
-                imgs['../resources/red-indexed.png'].height,
-                0, gl.RGB, gl.UNSIGNED_BYTE, null);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup");
-  wtu.clearAndDrawUnitQuad(gl);
-  gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  // The image should be white.
-  checkPixelRange(buf, middle, center, [ 0, 0, 0, 255 ], 10);
-
-  debug("");
-  successfullyParsed = true;
-  shouldBeTrue("successfullyParsed");
-  debug('<br /><span class="pass">TEST COMPLETE</span>');
-  notifyFinishedToHarness();
-}
-</script>
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/mipmap-fbo.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/mipmap-fbo.html
deleted file mode 100644
index c025d0b..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/mipmap-fbo.html
+++ /dev/null
@@ -1,88 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-  <head>
-<meta charset="utf-8">
-    <title>Tests if mipmap generation on a texture filled by an FBO works correctly</title>
-    <link rel="stylesheet" href="../../resources/js-test-style.css"/>
-    <script src="../../resources/js-test-pre.js"></script>
-    <script src="../resources/webgl-test.js"> </script>
-    <script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="24" height="24"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-function init(){
-    var wtu = WebGLTestUtils;
-    description();
-
-    var gl = wtu.create3DContext("example");
-    var program = wtu.setupTexturedQuad(gl);
-
-    // setup render target texture //
-    var texture = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_LINEAR);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, 2, 2, 0, gl.RGB, gl.UNSIGNED_BYTE, null);
-    gl.bindTexture(gl.TEXTURE_2D, null);
-                
-    // setup framebuffer //
-    var fbo = gl.createFramebuffer();
-    gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);
-    gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);
-    gl.bindFramebuffer(gl.FRAMEBUFFER, null);
-                
-    // fill the framebuffer //
-    gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);
-    gl.clearColor(1, 0, 1, 1);
-    gl.clear(gl.COLOR_BUFFER_BIT);
-    gl.bindFramebuffer(gl.FRAMEBUFFER, null);
-                
-    // generate mipmap //
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-    gl.generateMipmap(gl.TEXTURE_2D);
-
-    gl.drawArrays(gl.TRIANGLES, 0, 6);
-                
-    // readback //
-    wtu.checkCanvas(gl, [255, 0, 255, 255]);
-}
-
-init();
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/origin-clean-conformance.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/origin-clean-conformance.html
deleted file mode 100644
index b4185b5..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/origin-clean-conformance.html
+++ /dev/null
@@ -1,157 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Origin Restrictions Conformance Tests</title>
-<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/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-<script>
-"use strict";
-var wtu = WebGLTestUtils;
-// This function returns the last 2 words of the domain of a URL
-// This is probably not the correct check but it will do for now.
-function getBaseDomain(str) {
-  str = str.replace("\\", "/");
-  var pos = str.indexOf("://");
-  if (pos >= 0) {
-    str = str.substr(pos + 3);
-  }
-  var parts = str.split('/');
-  var domain = parts[0].match(/\w+\.\w+$/);
-  return domain || '';
-}
-
-// Checks if function throws an exception.
-function causedException(func) {
-  var hadException = false;
-  try {
-    func();
-  } catch(e) {
-    hadException = true;
-  }
-  return hadException;
-}
-
-var imgDomain;
-var pageDomain;
-var successfullyParsed;
-
-window.onload = function() {
-  description("This test ensures WebGL implementations follow proper same-origin restrictions.");
-  var img = document.getElementById("img");
-  assertMsg(img.width > 0 && img.height > 0, "img was loaded");
-  imgDomain = getBaseDomain(img.src);
-  pageDomain = getBaseDomain(window.location.toString());
-  assertMsg(imgDomain != pageDomain,
-            "img domain (" + imgDomain + ") and page domain (" + pageDomain + ") are not the same.");
-
-  function makeTexImage2D(gl, src) {
-    return function() {
-      gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, src);
-    };
-  }
-
-  function makeTexSubImage2D(gl, src) {
-    return function() {
-      gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, src);
-    };
-  }
-
-  function makeReadPixels(gl) {
-    return function() {
-      var buf = new Uint8Array(4);
-      gl.readPixels(0, 0, 1, 1, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-    };
-  }
-
-  function makeToDataURL(canvas) {
-    return function() {
-      var data = canvas.toDataURL();
-    }
-  }
-
-  var canvas1 = document.getElementById("canvas1");
-  var gl = wtu.create3DContext(canvas1);
-
-  debug("");
-  debug("check that an attempt to upload an image from another origin throws an exception.");
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 256, 256, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
-  assertMsg(causedException(makeTexImage2D(gl, img)),
-            "texImage2D with cross-origin image should throw exception.");
-  assertMsg(causedException(makeTexSubImage2D(gl, img)),
-            "texSubImage2D with cross-origin image should throw exception.");
-
-  debug("check that readPixels and toDataURL continue to work against this canvas.");
-  assertMsg(!causedException(makeReadPixels(gl)),
-            "readPixels should never throw exception -- not possible to dirty origin of WebGL canvas.");
-  assertMsg(!causedException(makeToDataURL(canvas1)),
-            "should not throw exception by toDataURL for WebGL canvas, which should stay origin clean.");
-
-  debug("check that an attempt to upload a tainted canvas throws an exception.");
-  var canvas2 = document.getElementById("canvas2");
-  var ctx2d = canvas2.getContext("2d");
-  ctx2d.drawImage(img, 0, 0);
-  assertMsg(causedException(makeToDataURL(canvas2)),
-            "should throw exception by toDataURL for NON origin clean canvas.");
-  assertMsg(causedException(makeTexImage2D(gl, canvas2)),
-            "texImage2D with NON origin clean canvas should throw exception.");
-  assertMsg(causedException(makeTexSubImage2D(gl, canvas2)),
-            "texSubImage2D with NON origin clean canvas should throw exception.");
-
-  debug("check that readPixels and toDataURL continue to work against this canvas.");
-  assertMsg(!causedException(makeReadPixels(gl)),
-            "readPixels should never throw exception -- not possible to dirty origin of WebGL canvas.");
-  assertMsg(!causedException(makeToDataURL(canvas1)),
-            "should not throw exception by toDataURL for WebGL canvas, which should stay origin clean.");
-
-  // TODO: Should check video.
-  // TODO: Should check CORS support.
-
-  debug("");
-  successfullyParsed = true;
-  shouldBeTrue("successfullyParsed");
-  debug('<br /><span class="pass">TEST COMPLETE</span>');
-  notifyFinishedToHarness();
-}
-</script>
-</head>
-<body>
-<div id="description"></div>
-<div id="console"></div>
-<canvas id="canvas1"></canvas>
-<canvas id="canvas2"></canvas>
-<img id="img" src="http://www.opengl.org/img/opengl_logo.jpg" style="display:none;">
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-array-buffer-view.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-array-buffer-view.html
deleted file mode 100644
index 20f74df..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-array-buffer-view.html
+++ /dev/null
@@ -1,259 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="16" height="16"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description('Verifies texImage2D and texSubImage2D code paths taking ArrayBufferView');
-
-var wtu = WebGLTestUtils;
-var gl = null;
-var textureLoc = null;
-var successfullyParsed = false;
-
-function roundUpToAlignment(value, alignment) {
-  return Math.floor((value + alignment - 1) / alignment) * alignment;
-}
-
-function generateRGBAData(type, unpackAlignment, sourceData, width, height)
-{
-    var numColors = sourceData.length / 4;
-    var colorOffset = function(y) {
-      return 4 * Math.floor(y * numColors / height);
-    };
-
-    switch (type) {
-    case gl.UNSIGNED_BYTE: {
-        var rowWidth = roundUpToAlignment(width * 4, unpackAlignment);
-        var data = new Uint8Array(height * rowWidth);
-        for (var y = 0; y < height; ++y) {
-            var index = y * rowWidth;
-            var offset = colorOffset(y);
-            for (var element = 0; element < width * 4; ++element) {
-                data[index + element] = sourceData[offset + element % 4];
-            }
-        }
-        return data;
-    }
-    case gl.UNSIGNED_SHORT_4_4_4_4: {
-        var rowWidth = roundUpToAlignment(width * 2, unpackAlignment) / 2;
-        var data = new Uint16Array(height * rowWidth);
-        for (var y = 0; y < height; ++y) {
-            var offset = colorOffset(y);
-            for (var x = 0; x < width; ++x) {
-                var index = y * rowWidth + x;
-                data[index] = (((sourceData[offset + 0] & 0xF0) << 8)
-                             | ((sourceData[offset + 1] & 0xF0) << 4)
-                             | ((sourceData[offset + 2] & 0xF0) >> 0)
-                             | ((sourceData[offset + 3] & 0xF0) >> 4));
-            }
-        }
-        return data;
-    }
-    case gl.UNSIGNED_SHORT_5_5_5_1: {
-        var rowWidth = roundUpToAlignment(width * 2, unpackAlignment) / 2;
-        var data = new Uint16Array(height * rowWidth);
-        for (var y = 0; y < height; ++y) {
-            var offset = colorOffset(y);
-            for (var x = 0; x < width; ++x) {
-                var index = y * rowWidth + x;
-                data[index] = (((sourceData[offset + 0] & 0xF8) << 8)
-                             | ((sourceData[offset + 1] & 0xF8) << 3)
-                             | ((sourceData[offset + 2] & 0xF8) >> 2)
-                             | ((sourceData[offset + 3] & 0x80) >> 7));
-            }
-        }
-        return data;
-    }
-    }
-}
-
-function typeToString(type)
-{
-    switch (type) {
-    case gl.UNSIGNED_BYTE:           return 'UNSIGNED_BYTE';
-    case gl.UNSIGNED_SHORT_5_5_5_1:  return 'UNSIGNED_SHORT_5_5_5_1';
-    case gl.UNSIGNED_SHORT_4_4_4_4:  return 'UNSIGNED_SHORT_4_4_4_4';
-    }
-    return 'Unknown type ' + type;
-}
-
-function runOneIteration(useTexSubImage2D, type, unpackAlignment, flipY, premultiplyAlpha, topColor, bottomColor, extraColor)
-{
-    debug('Testing ' + (useTexSubImage2D ? 'texSubImage2D' : 'texImage2D') +
-          ' with type=' + typeToString(type) +
-          ', unpackAlignment=' + unpackAlignment +
-          ', flipY=' + flipY + ', premultiplyAlpha=' + premultiplyAlpha);
-    gl.colorMask(true, true, true, true);
-    gl.clearColor(0, 0, 0, 1.0);
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    // Enable writes to the RGB channels
-    gl.colorMask(true, true, true, false);
-    var texture = gl.createTexture();
-    // Bind the texture to texture unit 0
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-    // Set up texture parameters
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-    // Set up pixel store parameters
-    gl.pixelStorei(gl.UNPACK_ALIGNMENT, unpackAlignment);
-    gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, flipY);
-    gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, premultiplyAlpha);
-    // Generate the data
-    var sourceData = [ 255,   0,   0, 255,
-                       0,   255,   0,   0 ];
-    var texWidth = 5;   // this must be mod 4 + 1 to test unpackAlignment
-    var texHeight = 16;
-    var data = generateRGBAData(type, unpackAlignment, sourceData, texWidth, texHeight);
-    if (gl.getError() != gl.NO_ERROR)
-        testFailed("GL error before texture upload");
-    // Upload the image into the texture
-    if (useTexSubImage2D) {
-        // Initialize the texture to black first
-        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, texWidth, texHeight, 0,
-                      gl.RGBA, type, null);
-        if (gl.getError() != gl.NO_ERROR)
-            testFailed("GL error after texImage2D(null)");
-        gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, texWidth, texHeight, gl.RGBA, type, data);
-        if (gl.getError() != gl.NO_ERROR)
-            testFailed("GL error after texSubImage2D");
-    } else {
-        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, texWidth, texHeight, 0, gl.RGBA, type, data);
-        if (gl.getError() != gl.NO_ERROR)
-            testFailed("GL error after texImage2D");
-    }
-
-    // Point the uniform sampler to texture unit 0
-    gl.uniform1i(textureLoc, 0);
-    // Draw the triangles
-    wtu.clearAndDrawUnitQuad(gl, [0, 0, 0, 255]);
-
-    // Check the top pixel and bottom pixel and make sure they have
-    // the right color.
-    var testWidth  = gl.drawingBufferWidth;
-    var testHeight = gl.drawingBufferHeight / 2;
-    wtu.checkCanvasRect(gl, 0, 0, testWidth, testHeight, bottomColor, "bottom pixel should be " + bottomColor);
-    wtu.checkCanvasRect(gl, 0, testHeight, testWidth, testHeight, topColor, "top pixel should be " + topColor);
-
-    // Change part of the texture.
-    var partWidth = 8;
-    var partHeight = 16;
-    // make texture double res of part.
-    var data = generateRGBAData(type, unpackAlignment, sourceData, partWidth * 2, partHeight * 2);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, partWidth * 2, partHeight * 2, 0, gl.RGBA, type, data);
-    // set part.
-    var extraData = [
-      255,   0,   0, 255,
-        0,   0, 255,   0
-    ];
-    var data = generateRGBAData(type, unpackAlignment, extraData, partWidth, partHeight);
-    gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, partWidth, partHeight, gl.RGBA, type, data);
-    wtu.clearAndDrawUnitQuad(gl, [0, 0, 0, 255]);
-    var halfWidth  = gl.drawingBufferWidth / 2;
-    var halfHeight = gl.drawingBufferHeight / 2;
-    var quarterHeight = gl.drawingBufferHeight / 4;
-    var red = [255, 0, 0, 255];
-    var tcolor0 = flipY ? extraColor : red;
-    var tcolor1 = flipY ? red : extraColor;
-    wtu.checkCanvasRect(gl, 0, 0, halfWidth, quarterHeight, tcolor0, "bottom left bottom pixels should be " + tcolor0);
-    wtu.checkCanvasRect(gl, 0, quarterHeight, halfWidth, quarterHeight, tcolor1, "bottom left top pixels should be " + tcolor1);
-    wtu.checkCanvasRect(gl, halfWidth, 0, halfWidth, halfHeight, bottomColor, "bottom right pixels should be " + bottomColor);
-    wtu.checkCanvasRect(gl, 0, halfHeight, testWidth, halfHeight, topColor, "top pixels should be " + topColor);
-    // set far corner.
-    gl.texSubImage2D(gl.TEXTURE_2D, 0, partWidth, partHeight, partWidth, partHeight, gl.RGBA, type, data);
-    wtu.clearAndDrawUnitQuad(gl, [0, 0, 0, 255]);
-    wtu.checkCanvasRect(gl, 0, 0, halfWidth, quarterHeight, tcolor0, "bottom left bottom pixels should be " + tcolor0);
-    wtu.checkCanvasRect(gl, 0, quarterHeight, halfWidth, quarterHeight, tcolor1, "bottom left top pixels should be " + tcolor1);
-    wtu.checkCanvasRect(gl, halfWidth, 0, halfWidth, halfHeight, bottomColor, "bottom left pixels should be " + bottomColor);
-    wtu.checkCanvasRect(gl, 0, halfHeight, halfWidth, halfHeight, topColor, "top right pixels should be " + topColor);
-    wtu.checkCanvasRect(gl, halfWidth, halfHeight, halfWidth, quarterHeight, tcolor0, "top right bottom pixels should be " + tcolor0);
-    wtu.checkCanvasRect(gl, halfWidth, halfHeight + quarterHeight, halfWidth, quarterHeight, tcolor1, "top right top pixels should be " + tcolor1);
-}
-
-function runTest()
-{
-    var red = [255, 0, 0, 255];
-    var green = [0, 255, 0, 255];
-    var blue = [0, 0, 255, 255];
-    var redPremultiplyAlpha = [255, 0, 0, 255];
-    var greenPremultiplyAlpha = [0, 0, 0, 255];
-    var bluePremultiplyAlpha = [0, 0, 0, 255];
-
-    var types = [ gl.UNSIGNED_BYTE, gl.UNSIGNED_SHORT_5_5_5_1, gl.UNSIGNED_SHORT_4_4_4_4 ];
-    var unpackAlignments = [ 1, 2, 4, 8 ];
-
-    for (var i = 0; i < types.length; ++i) {
-        var type = types[i];
-        for (var j = 0; j < unpackAlignments.length; ++j) {
-            var unpackAlignment = unpackAlignments[j];
-            runOneIteration(false, type, unpackAlignment, true, false,
-                            red, green, blue);
-            runOneIteration(false, type, unpackAlignment, false, false,
-                            green, red, blue);
-            runOneIteration(false, type, unpackAlignment, true, true,
-                            redPremultiplyAlpha, greenPremultiplyAlpha, bluePremultiplyAlpha);
-            runOneIteration(false, type, unpackAlignment, false, true,
-                            greenPremultiplyAlpha, redPremultiplyAlpha, bluePremultiplyAlpha);
-            runOneIteration(true, type, unpackAlignment, true, false,
-                            red, green, blue);
-            runOneIteration(true, type, unpackAlignment, false, false,
-                            green, red, blue);
-            runOneIteration(true, type, unpackAlignment, true, true,
-                            redPremultiplyAlpha, greenPremultiplyAlpha, bluePremultiplyAlpha);
-            runOneIteration(true, type, unpackAlignment, false, true,
-                            greenPremultiplyAlpha, redPremultiplyAlpha, bluePremultiplyAlpha);
-        }
-    }
-
-}
-
-var gl = wtu.create3DContext("example");
-var program = wtu.setupTexturedQuad(gl);
-
-textureLoc = gl.getUniformLocation(program, "tex");
-
-runTest();
-glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgb565.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgb565.html
deleted file mode 100644
index 48908d8..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgb565.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGB", "UNSIGNED_SHORT_5_6_5", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba4444.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba4444.html
deleted file mode 100644
index ffd38ed..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba4444.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_SHORT_4_4_4_4", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba5551.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba5551.html
deleted file mode 100644
index e90a38a..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas-rgba5551.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_SHORT_5_5_5_1", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas.html
deleted file mode 100644
index 85232b1..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-canvas.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_BYTE", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgb565.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgb565.html
deleted file mode 100644
index b09f390..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgb565.html
+++ /dev/null
@@ -1,50 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGB", "UNSIGNED_SHORT_5_6_5", testPrologue)()'>
-<canvas id="texcanvas" width="1" height="2"></canvas>
-<canvas id="example" width="1" height="2"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba4444.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba4444.html
deleted file mode 100644
index 6a1d243..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba4444.html
+++ /dev/null
@@ -1,50 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_SHORT_4_4_4_4", testPrologue)()'>
-<canvas id="texcanvas" width="1" height="2"></canvas>
-<canvas id="example" width="1" height="2"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba5551.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba5551.html
deleted file mode 100644
index 5bbd01d..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data-rgba5551.html
+++ /dev/null
@@ -1,50 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_SHORT_5_5_5_1", testPrologue)()'>
-<canvas id="texcanvas" width="1" height="2"></canvas>
-<canvas id="example" width="1" height="2"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data.html
deleted file mode 100644
index 89a4680..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-data.html
+++ /dev/null
@@ -1,50 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_BYTE", testPrologue)()'>
-<canvas id="texcanvas" width="1" height="2"></canvas>
-<canvas id="example" width="1" height="2"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgb565.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgb565.html
deleted file mode 100644
index 85025b1..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgb565.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGB", "UNSIGNED_SHORT_5_6_5", "..", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba4444.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba4444.html
deleted file mode 100644
index 3c33b48..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba4444.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_SHORT_4_4_4_4", "..", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba5551.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba5551.html
deleted file mode 100644
index c040554..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image-rgba5551.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_SHORT_5_5_5_1", "..", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image.html
deleted file mode 100644
index c4f2d55..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-image.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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>
-<script>
-"use strict";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_BYTE", "..", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgb565.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgb565.html
deleted file mode 100644
index 2ac11e2..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgb565.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGB", "UNSIGNED_SHORT_5_6_5", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba4444.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba4444.html
deleted file mode 100644
index da911aa..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba4444.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_SHORT_4_4_4_4", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba5551.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba5551.html
deleted file mode 100644
index 27ef62f..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video-rgba5551.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_SHORT_5_5_5_1", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video.html
deleted file mode 100644
index 65c4a7f..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-sub-image-2d-with-video.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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";
-function testPrologue(gl) {
-    return true;
-}
-</script>
-</head>
-<body onload='generateTest("RGBA", "UNSIGNED_BYTE", testPrologue)()'>
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-uniform-binding-bugs.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-uniform-binding-bugs.html
deleted file mode 100644
index b7f70e1..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-and-uniform-binding-bugs.html
+++ /dev/null
@@ -1,64 +0,0 @@
-<!--
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
--->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<div id="description"></div>
-<div id="console"></div>
-
-<script>
-"use strict";
-
-description('Tests passing a vec4 to a uniform and a canvas to texImage2D');
-
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext();
-var floatProgram = wtu.loadProgramFromFile(gl, "../resources/floatUniformShader.vert", "../resources/noopUniformShader.frag");
-shouldBeUndefined("gl.useProgram(floatProgram)");
-var fval4Loc = gl.getUniformLocation(floatProgram, "fval4");
-glErrorShouldBe(gl, gl.NO_ERROR);
-shouldBeUndefined("gl.uniform4fv(fval4Loc, new Float32Array([0.1, 0.2, 0.4, 1.0]));");
-
-var tmpcanvas = document.createElement("canvas");
-tmpcanvas.width = 2;
-tmpcanvas.height = 2;
-var texture = gl.createTexture();
-shouldBeUndefined("gl.bindTexture(gl.TEXTURE_2D, texture)");
-shouldBeUndefined("gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, tmpcanvas)");
-
-var successfullyParsed = true;
-
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-webgl.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-webgl.html
deleted file mode 100644
index b28b751..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-webgl.html
+++ /dev/null
@@ -1,87 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL texImage2D from WebGL conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="256" height="16" style="width: 256px; height: 48px;"></canvas>
-<canvas id="source" width="256" height="16" style="width: 256px; height: 48px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description("Test texImage2D from a webgl canvas.");
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("example");
-gl.disable(gl.DITHER);
-var program = wtu.setupTexturedQuad(gl);
-var gl1 = wtu.create3DContext("source");
-gl1.disable(gl.DITHER);
-
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-glErrorShouldBe(gl1, gl1.NO_ERROR, "Should be no errors from setup.");
-
-gl.disable(gl.BLEND);
-gl.disable(gl.DEPTH_TEST);
-
-gl1.clearColor(1.0, 0.0, 0.0, 1.0);
-gl1.clear(gl1.COLOR_BUFFER_BIT);
-
-var tex = gl.createTexture();
-gl.bindTexture(gl.TEXTURE_2D, tex);
-gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE, gl1.canvas);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-wtu.clearAndDrawUnitQuad(gl);
-
-wtu.checkCanvas(gl, [255, 0, 0, 255], "Canvas should be red");
-
-gl1.clearColor(0.0, 1.0, 0.0, 1.0);
-gl1.clear(gl1.COLOR_BUFFER_BIT);
-
-gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE, gl1.canvas);
-wtu.clearAndDrawUnitQuad(gl);
-
-wtu.checkCanvas(gl, [0, 255, 0, 255], "Canvas should be green");
-
-debug("");
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-format-and-type.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-format-and-type.html
deleted file mode 100644
index d771ef6..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-format-and-type.html
+++ /dev/null
@@ -1,747 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/pnglib.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-
-<script>
-"use strict";
-var wtu = WebGLTestUtils;
-var gl = null;
-var textureLoc = null;
-var successfullyParsed = false;
-
-//----------------------------------------------------------------------
-// Harness
-
-var testCases = [];
-
-var DataMode = {
-    IMAGE: 0,
-    IMAGE_DATA: 1,
-
-    NUM_HTML_MODES: 2,
-
-    RAW_DATA: 2,
-
-    // This must remain the last mode.
-    NUM_MODES: 3
-};
-
-function init()
-{
-    initTestingHarnessWaitUntilDone();
-
-    description('Verify texImage2D and texSubImage2D code paths taking both HTML and user-specified data with all format/type combinations');
-
-    var canvas = document.getElementById("example");
-    gl = wtu.create3DContext(canvas);
-    gl.disable(gl.DITHER);
-    var program = wtu.setupTexturedQuad(gl);
-
-    gl.clearColor(0,0,0,1);
-    gl.clearDepth(1);
-    gl.disable(gl.BLEND);
-
-    textureLoc = gl.getUniformLocation(program, "tex");
-
-    initializeTests();
-}
-
-function initializeTests()
-{
-    // Verify that uploading to packed pixel formats performs the
-    // required conversion and associated loss of precision.
-    for (var dataMode = 0; dataMode < DataMode.NUM_HTML_MODES; ++dataMode) {
-        for (var useTexSubImage2D = 0; useTexSubImage2D < 2; ++useTexSubImage2D) {
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateOpaqueGrayscaleRamp,
-                premultiplyAlpha: false,
-                format: gl.RGBA,
-                type: gl.UNSIGNED_BYTE,
-                verifier: allChannelsIncreaseByNoMoreThan,
-                threshold: 1,
-                numOccurrences: 1,
-                description: "RGBA/UNSIGNED_BYTE should maintain full precision of data"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateOpaqueGrayscaleRamp,
-                premultiplyAlpha: false,
-                format: gl.RGBA,
-                type: gl.UNSIGNED_SHORT_4_4_4_4,
-                verifier: allChannelsIncreaseByAtLeast,
-                threshold: 15,
-                numOccurrences: 10,
-                description: "RGBA/UNSIGNED_SHORT_4_4_4_4 must drop low four bits of precision"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateOpaqueGrayscaleRamp,
-                premultiplyAlpha: false,
-                format: gl.RGBA,
-                type: gl.UNSIGNED_SHORT_5_5_5_1,
-                verifier: allChannelsIncreaseByAtLeast,
-                threshold: 7,
-                numOccurrences: 20,
-                description: "RGBA/UNSIGNED_SHORT_5_5_5_1 must drop low three bits of precision"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateOpaqueGrayscaleRamp,
-                premultiplyAlpha: false,
-                format: gl.RGB,
-                type: gl.UNSIGNED_BYTE,
-                verifier: allChannelsIncreaseByNoMoreThan,
-                threshold: 1,
-                numOccurrences: 1,
-                description: "RGB/UNSIGNED_BYTE should maintain full precision of data"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateOpaqueGrayscaleRamp,
-                premultiplyAlpha: false,
-                format: gl.RGB,
-                type: gl.UNSIGNED_SHORT_5_6_5,
-                verifier: allChannelsIncreaseByAtLeast,
-                threshold: 3,
-                numOccurrences: 20,
-                description: "RGB/UNSIGNED_SHORT_5_6_5 must drop low two or three bits of precision"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateTranslucentGrayscaleRamp,
-                premultiplyAlpha: false,
-                format: gl.ALPHA,
-                type: gl.UNSIGNED_BYTE,
-                verifier: alphaChannelIncreasesByNoMoreThan,
-                threshold: 1,
-                numOccurrences: 1,
-                description: "ALPHA/UNSIGNED_BYTE should maintain full precision of data"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateOpaqueGrayscaleRamp,
-                premultiplyAlpha: false,
-                format: gl.LUMINANCE,
-                type: gl.UNSIGNED_BYTE,
-                verifier: allChannelsIncreaseByNoMoreThan,
-                threshold: 1,
-                numOccurrences: 1,
-                description: "LUMINANCE/UNSIGNED_BYTE should maintain full precision of data"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateOpaqueGrayscaleRamp,
-                premultiplyAlpha: false,
-                format: gl.LUMINANCE_ALPHA,
-                type: gl.UNSIGNED_BYTE,
-                verifier: allChannelsIncreaseByNoMoreThan,
-                threshold: 1,
-                numOccurrences: 1,
-                description: "LUMINANCE_ALPHA/UNSIGNED_BYTE should maintain full precision of data"
-            });
-        }
-    }
-
-    // Verify that setting the UNPACK_PREMULTIPLY_ALPHA_WEBGL pixel
-    // store parameter and sending down a zero alpha causes the color
-    // channels to go to zero.
-    for (var dataMode = 0; dataMode < DataMode.NUM_MODES; ++dataMode) {
-        for (var useTexSubImage2D = 0; useTexSubImage2D < 2; ++useTexSubImage2D) {
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateTransparentGrayscaleRamp,
-                premultiplyAlpha: true,
-                format: gl.RGBA,
-                type: gl.UNSIGNED_BYTE,
-                verifier: colorChannelsAreZero,
-                description: "UNPACK_PREMULTIPLY_ALPHA_WEBGL with RGBA/UNSIGNED_BYTE"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateTransparentGrayscaleRamp,
-                premultiplyAlpha: true,
-                format: gl.RGBA,
-                type: gl.UNSIGNED_SHORT_4_4_4_4,
-                verifier: colorChannelsAreZero,
-                description: "UNPACK_PREMULTIPLY_ALPHA_WEBGL with RGBA/UNSIGNED_SHORT_4_4_4_4"
-            });
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateTransparentGrayscaleRamp,
-                premultiplyAlpha: true,
-                format: gl.RGBA,
-                type: gl.UNSIGNED_SHORT_5_5_5_1,
-                verifier: colorChannelsAreZero,
-                description: "UNPACK_PREMULTIPLY_ALPHA_WEBGL with RGBA/UNSIGNED_SHORT_5_5_5_1"
-            });
-            // The following few tests are invalid for the raw data
-            // mode because there is either no alpha channel or no
-            // separate alpha channel.
-            if (dataMode != DataMode.RAW_DATA) {
-                testCases.push({
-                    dataMode: dataMode,
-                    useTexSubImage2D: !!useTexSubImage2D,
-                    width: 256,
-                    height: 1,
-                    generator: generateTransparentGrayscaleRamp,
-                    premultiplyAlpha: true,
-                    format: gl.RGB,
-                    type: gl.UNSIGNED_BYTE,
-                    verifier: colorChannelsAreZero,
-                    description: "UNPACK_PREMULTIPLY_ALPHA_WEBGL with RGB/UNSIGNED_BYTE"
-                });
-                testCases.push({
-                    dataMode: dataMode,
-                    useTexSubImage2D: !!useTexSubImage2D,
-                    width: 256,
-                    height: 1,
-                    generator: generateTransparentGrayscaleRamp,
-                    premultiplyAlpha: true,
-                    format: gl.RGB,
-                    type: gl.UNSIGNED_SHORT_5_6_5,
-                    verifier: colorChannelsAreZero,
-                    description: "UNPACK_PREMULTIPLY_ALPHA_WEBGL with RGB/UNSIGNED_SHORT_5_6_5"
-                });
-                testCases.push({
-                    dataMode: dataMode,
-                    useTexSubImage2D: !!useTexSubImage2D,
-                    width: 256,
-                    height: 1,
-                    generator: generateTransparentGrayscaleRamp,
-                    premultiplyAlpha: true,
-                    format: gl.ALPHA,
-                    type: gl.UNSIGNED_BYTE,
-                    verifier: colorChannelsAreZero,
-                    description: "UNPACK_PREMULTIPLY_ALPHA_WEBGL with ALPHA/UNSIGNED_BYTE"
-                });
-                testCases.push({
-                    dataMode: dataMode,
-                    useTexSubImage2D: !!useTexSubImage2D,
-                    width: 256,
-                    height: 1,
-                    generator: generateTransparentGrayscaleRamp,
-                    premultiplyAlpha: true,
-                    format: gl.LUMINANCE,
-                    type: gl.UNSIGNED_BYTE,
-                    verifier: colorChannelsAreZero,
-                    description: "UNPACK_PREMULTIPLY_ALPHA_WEBGL with LUMINANCE/UNSIGNED_BYTE"
-                });
-            }
-            testCases.push({
-                dataMode: dataMode,
-                useTexSubImage2D: !!useTexSubImage2D,
-                width: 256,
-                height: 1,
-                generator: generateTransparentGrayscaleRamp,
-                premultiplyAlpha: true,
-                format: gl.LUMINANCE_ALPHA,
-                type: gl.UNSIGNED_BYTE,
-                verifier: colorChannelsAreZero,
-                description: "UNPACK_PREMULTIPLY_ALPHA_WEBGL with LUMINANCE_ALPHA/UNSIGNED_BYTE"
-            });
-        }
-    }
-
-    // Produce data for all testcases. Because we load images, some of
-    // these may generate their data asynchronously.
-    generateTestData();
-}
-
-function generateTestData()
-{
-    for (var i = 0; i < testCases.length; i++) {
-        var testCase = testCases[i];
-        var wrapper = null;
-        switch (testCase.dataMode) {
-        case DataMode.IMAGE:
-            wrapper = new ImageWrapper(testCase.width, testCase.height);
-            break;
-        case DataMode.IMAGE_DATA:
-            wrapper = new ImageDataWrapper(testCase.width, testCase.height);
-            break;
-        case DataMode.RAW_DATA:
-            switch (testCase.type) {
-            case gl.UNSIGNED_BYTE:
-                switch (testCase.format) {
-                case gl.RGBA:
-                    wrapper = new RGBA8DataWrapper(testCase.width, testCase.height);
-                    break;
-                case gl.RGB:
-                    wrapper = new RGB8DataWrapper(testCase.width, testCase.height);
-                    break;
-                case gl.ALPHA:
-                    wrapper = new A8DataWrapper(testCase.width, testCase.height);
-                    break;
-                case gl.LUMINANCE:
-                    wrapper = new L8DataWrapper(testCase.width, testCase.height);
-                    break;
-                case gl.LUMINANCE_ALPHA:
-                    wrapper = new LA8DataWrapper(testCase.width, testCase.height);
-                    break;
-                }
-                break;
-            case gl.UNSIGNED_SHORT_4_4_4_4:
-                wrapper = new RGBA4444DataWrapper(testCase.width, testCase.height);
-                break;
-            case gl.UNSIGNED_SHORT_5_5_5_1:
-                wrapper = new RGBA5551DataWrapper(testCase.width, testCase.height);
-                break;
-            case gl.UNSIGNED_SHORT_5_6_5:
-                wrapper = new RGB565DataWrapper(testCase.width, testCase.height);
-                break;
-            }
-        }
-        testCase.wrapper = wrapper;
-        testCase.generator(wrapper);
-        testCase.wrapper.generateData();
-    }
-
-    // See whether we need to run the tests, in case all of them
-    // generated their results synchronously.
-    maybeRunTests();
-}
-
-var ranTests = false;
-
-function maybeRunTests()
-{
-    if (!ranTests)
-        for (var i = 0; i < testCases.length; ++i)
-            if (!testCases[i].wrapper || !testCases[i].wrapper.data)
-                return;
-
-    ranTests = true;
-
-    for (var i = 0; i < testCases.length; ++i)
-        runOneTest(testCases[i]);
-
-    finishTest();
-}
-
-function testCaseToString(testCase)
-{
-    var mode;
-    switch (testCase.dataMode) {
-    case DataMode.IMAGE:
-        mode = "Image";
-        break;
-    case DataMode.IMAGE_DATA:
-        mode = "ImageData";
-        break;
-    case DataMode.RAW_DATA:
-        mode = "raw data";
-        break;
-    }
-    return (testCase.useTexSubImage2D ? "texSubImage2D" : "texImage2D") +
-            " with " + mode +  " at " + testCase.width + "x" + testCase.height;
-}
-
-function runOneTest(testCase)
-{
-    debug("Testing " + testCaseToString(testCase));
-    var data = testCase.wrapper.data;
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    var texture = gl.createTexture();
-    // Bind the texture to texture unit 0.
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-    // Set up texture parameters.
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-    // Set up pixel store parameters.
-    gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, testCase.premultiplyAlpha);
-    // Upload the image into the texture.
-    if (testCase.useTexSubImage2D) {
-        // Initialize the texture to black first.
-        gl.texImage2D(gl.TEXTURE_2D, 0, testCase.format, testCase.width, testCase.height, 0,
-                      testCase.format, testCase.type, null);
-    }
-    switch (testCase.dataMode) {
-    case DataMode.IMAGE:
-    case DataMode.IMAGE_DATA:
-        if (testCase.useTexSubImage2D)
-            gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, testCase.format, testCase.type, data);
-        else
-            gl.texImage2D(gl.TEXTURE_2D, 0, testCase.format, testCase.format, testCase.type, data);
-        break;
-    case DataMode.RAW_DATA:
-        if (testCase.useTexSubImage2D)
-            gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, testCase.width, testCase.height, testCase.format, testCase.type, data);
-        else
-            gl.texImage2D(gl.TEXTURE_2D, 0, testCase.format, testCase.width, testCase.height, 0, testCase.format, testCase.type, data);
-        break;
-    }
-    // Point the uniform sampler to texture unit 0.
-    gl.uniform1i(textureLoc, 0);
-    // Draw the triangles.
-    gl.drawArrays(gl.TRIANGLES, 0, 6);
-    // Clean up the texture.
-    gl.deleteTexture(texture);
-
-    // Read back the rendering results.
-    var buf = new Uint8Array(testCase.width * testCase.height * 4);
-    gl.readPixels(0, 0, testCase.width, testCase.height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-    // Run the verification routine.
-    if (testCase.verifier(buf, testCase.threshold, testCase.numOccurrences))
-        testPassed(testCase.description);
-    else
-        testFailed(testCase.description);
-}
-
-//----------------------------------------------------------------------
-// Wrappers for programmatic construction of Image, ImageData and raw texture data
-//
-
-function ImageWrapper(width, height)
-{
-    this.pngBuilder_ = new PNGlib(width, height, 256);
-}
-
-ImageWrapper.prototype.getWidth = function() {
-    return this.pngBuilder_.width;
-};
-
-ImageWrapper.prototype.getHeight = function() {
-    return this.pngBuilder_.height;
-};
-
-ImageWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    this.pngBuilder_.buffer[this.pngBuilder_.index(x, y)] = this.pngBuilder_.color(r, g, b, a);
-};
-
-// Generates data into "data" property, possibly asynchronously.
-ImageWrapper.prototype.generateData = function() {
-    var that = this;
-    var img = new Image();
-    img.onload = function() {
-        that.data = img;
-        maybeRunTests();
-    };
-    img.src = "data:image/png;base64," + this.pngBuilder_.getBase64();
-};
-
-function ImageDataWrapper(width, height)
-{
-    if (!ImageDataWrapper.tempCanvas) {
-        ImageDataWrapper.tempCanvas = document.createElement("canvas");
-    }
-    this.imageData_ = ImageDataWrapper.tempCanvas.getContext("2d").createImageData(width, height);
-}
-
-ImageDataWrapper.tempCanvas = null;
-
-ImageDataWrapper.prototype.getWidth = function() {
-    return this.imageData_.width;
-};
-
-ImageDataWrapper.prototype.getHeight = function() {
-    return this.imageData_.height;
-};
-
-ImageDataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    var index = 4 * (this.imageData_.width * y + x);
-    this.imageData_.data[index] = r;
-    this.imageData_.data[index + 1] = g;
-    this.imageData_.data[index + 2] = b;
-    this.imageData_.data[index + 3] = a;
-};
-
-ImageDataWrapper.prototype.generateData = function() {
-    this.data = this.imageData_;
-    maybeRunTests();
-};
-
-function TextureDataWrapper(width, height)
-{
-    this.width_ = width;
-    this.height_ = height;
-}
-
-TextureDataWrapper.prototype.getWidth = function() {
-    return this.width_;
-};
-
-TextureDataWrapper.prototype.getHeight = function() {
-    return this.height_;
-};
-
-TextureDataWrapper.prototype.generateData = function() {
-    this.data = this.data_;
-    maybeRunTests();
-};
-
-function RGBA8DataWrapper(width, height)
-{
-    TextureDataWrapper.call(this, width, height);
-    this.data_ = new Uint8Array(4 * width * height);
-}
-
-RGBA8DataWrapper.prototype = new TextureDataWrapper;
-
-RGBA8DataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    var index = 4 * (this.width_ * y + x);
-    this.data_[index] = r;
-    this.data_[index + 1] = g;
-    this.data_[index + 2] = b;
-    this.data_[index + 3] = a;
-};
-
-function RGBA5551DataWrapper(width, height)
-{
-    TextureDataWrapper.call(this, width, height);
-    this.data_ = new Uint16Array(width * height);
-}
-
-RGBA5551DataWrapper.prototype = new TextureDataWrapper;
-
-RGBA5551DataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    var value = (((r & 0xF8) << 8)
-                 | ((g & 0xF8) << 3)
-                 | ((b & 0xF8) >> 2)
-                 | (a >> 7));
-    this.data_[this.width_ * y + x] = value;
-};
-
-function RGBA4444DataWrapper(width, height)
-{
-    TextureDataWrapper.call(this, width, height);
-    this.data_ = new Uint16Array(width * height);
-}
-
-RGBA4444DataWrapper.prototype = new TextureDataWrapper;
-
-RGBA4444DataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    var value = (((r & 0xF0) << 8)
-                 | ((g & 0xF0) << 4)
-                 | (b & 0xF0)
-                 | (a >> 4));
-    this.data_[this.width_ * y + x] = value;
-};
-
-function RGB8DataWrapper(width, height)
-{
-    TextureDataWrapper.call(this, width, height);
-    this.data_ = new Uint8Array(3 * width * height);
-}
-
-RGB8DataWrapper.prototype = new TextureDataWrapper;
-
-RGB8DataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    var index = 3 * (this.width_ * y + x);
-    this.data_[index] = r;
-    this.data_[index + 1] = g;
-    this.data_[index + 2] = b;
-};
-
-function RGB565DataWrapper(width, height)
-{
-    TextureDataWrapper.call(this, width, height);
-    this.data_ = new Uint16Array(width * height);
-}
-
-RGB565DataWrapper.prototype = new TextureDataWrapper;
-
-RGB565DataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    var value = (((r & 0xF8) << 8)
-                 | ((g & 0xFC) << 3)
-                 | ((b & 0xF8) >> 3));
-    this.data_[this.width_ * y + x] = value;
-};
-
-function A8DataWrapper(width, height)
-{
-    TextureDataWrapper.call(this, width, height);
-    this.data_ = new Uint8Array(width * height);
-}
-
-A8DataWrapper.prototype = new TextureDataWrapper;
-
-A8DataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    this.data_[this.width_ * y + x] = a;
-};
-
-function L8DataWrapper(width, height)
-{
-    TextureDataWrapper.call(this, width, height);
-    this.data_ = new Uint8Array(width * height);
-}
-
-L8DataWrapper.prototype = new TextureDataWrapper;
-
-L8DataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    this.data_[this.width_ * y + x] = r;
-};
-
-function LA8DataWrapper(width, height)
-{
-    TextureDataWrapper.call(this, width, height);
-    this.data_ = new Uint8Array(2 * width * height);
-}
-
-LA8DataWrapper.prototype = new TextureDataWrapper;
-
-LA8DataWrapper.prototype.setPixel = function(x, y, r, g, b, a) {
-    var index = 2 * (this.width_ * y + x);
-    this.data_[index] = r;
-    this.data_[index + 1] = a;
-};
-
-//----------------------------------------------------------------------
-// Color ramp generation functions
-//
-
-function generateOpaqueGrayscaleRamp(wrapper)
-{
-    var width = wrapper.getWidth();
-    var height = wrapper.getHeight();
-    for (var x = 0; x < width; ++x) {
-        var value = Math.round(255.0 * x / width);
-        for (var y = 0; y < height; ++y)
-            wrapper.setPixel(x, y, value, value, value, 255);
-    }
-}
-
-function generateTranslucentGrayscaleRamp(wrapper)
-{
-    var width = wrapper.getWidth();
-    var height = wrapper.getHeight();
-    for (var x = 0; x < width; ++x) {
-        var value = Math.round(255.0 * x / width);
-        for (var y = 0; y < height; ++y)
-            wrapper.setPixel(x, y, value, value, value, value);
-    }
-}
-
-function generateTransparentGrayscaleRamp(wrapper)
-{
-    var width = wrapper.getWidth();
-    var height = wrapper.getHeight();
-    for (var x = 0; x < width; ++x) {
-        var value = Math.round(255.0 * x / width);
-        for (var y = 0; y < height; ++y)
-            wrapper.setPixel(x, y, value, value, value, 0);
-    }
-}
-
-//----------------------------------------------------------------------
-// Verification routines
-//
-
-function allChannelsIncreaseByNoMoreThan(array, threshold, numOccurrences) {
-    var numFound = 0;
-    for (var i = 4; i < array.length; i += 4)
-        for (var j = 0; j < 4; j++)
-            if (array[i + j] - array[i + j - 4] > threshold)
-                ++numFound;
-
-    return numFound < numOccurrences;
-}
-
-function alphaChannelIncreasesByNoMoreThan(array, threshold, numOccurrences) {
-    var numFound = 0;
-    for (var i = 7; i < array.length; i += 4)
-        if (array[i] - array[i - 4] > threshold)
-            ++numFound;
-
-    return numFound < numOccurrences;
-}
-
-function allChannelsIncreaseByAtLeast(array, threshold, numOccurrences) {
-    var numFound = 0;
-    for (var i = 4; i < array.length; i += 4)
-        for (var j = 0; j < 4; ++j)
-            if (array[i + j] - array[i + j - 4] > threshold)
-                ++numFound;
-
-    return numFound > numOccurrences;
-}
-
-function colorChannelsAreZero(array, threshold, numOccurrences) {
-    var passed = true;
-    var numFailures = 0;
-
-    for (var i = 4; i < array.length; i += 4)
-        for (var j = 0; j < 3; ++j)
-            if (array[i + j] != 0) {
-                passed = false;
-                if (++numFailures <= 5)
-                    debug("  array[" + (i + j) + "] should have been 0, was " + array[i + j]);
-            }
-
-    return passed;
-}
-
-</script>
-</head>
-<body onload="init()">
-<canvas id="example" width="256" height="1"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-invalid-data.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-invalid-data.html
deleted file mode 100644
index c623be2..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-image-with-invalid-data.html
+++ /dev/null
@@ -1,129 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-    <title>texImage2D and texSubImage2D tests with invalid data</title>
-  <link rel="stylesheet" href="../../resources/js-test-style.css"/>
-  <script src="../../resources/js-test-pre.js"></script>
-  <script src="../resources/webgl-test.js"></script>
-  <script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<div id="description"></div>
-<div id="console"></div>
-<canvas id="canvas" width="2" height="2"> </canvas>
-<script type="text/javascript">
-description("texImage2D and texSubImage2D tests with invalid data");
-
-var wtu = WebGLTestUtils;
-var canvas = document.getElementById("canvas");
-var gl = wtu.create3DContext(canvas);
-if (!gl)
-  testFailed("Context created.");
-else
-  testPassed("Context created.");
-
-var tex;
-
-function setup() {
-    tex = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, bug32619_tests.tex);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 64, 64, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
-}
-
-function teardown() {
-    gl.deleteTexture(tex);
-}
-
-function test(desc, func, expected) {
-    debug(desc);
-
-    var exc = null;
-    try {
-        func();
-    } catch (x) {
-        exc = x;
-    }
-
-    if (expected == gl.INVALID_OPERATION) {
-      glErrorShouldBe(gl, expected);
-    } else if (expected == "exception") {
-        if (exc) {
-            testPassed("threw exception");
-        } else {
-            testFailed("did not throw exception");
-        }
-    }
-}
-
-test("Passing a buffer not large enough to texImage2D should generate an INVALID_OPERATION",
-     function () {
-     var tooSmall = new Uint8Array(64);
-        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 64, 64, 0, gl.RGBA, gl.UNSIGNED_BYTE, tooSmall);
-     },
-     gl.INVALID_OPERATION);
-
-test("Passing texImage2D parameter data of Number type should throw an exception",
-     function () {
-        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 64, 64, 0, gl.RGBA, gl.UNSIGNED_BYTE, 42);
-     },
-     "exception");
-
-test("Passing texImage2D parameter data of String type should throw a TypeError",
-     function () {
-        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 64, 64, 0, gl.RGBA, gl.UNSIGNED_BYTE, "not a buffer");
-     },
-     "exception");
-test("Passing a buffer not large enough to texSubImage2D should generate an INVALID_OPERATION",
-     function () {
-        var tooSmall = new Uint8Array(64);
-        gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, 64, 64, gl.RGBA, gl.UNSIGNED_BYTE, tooSmall);
-     },
-     gl.INVALID_OPERATION);
-
-test("Passing texSubImage2D parameter data of Number type should throw a TypeError",
-     function () {
-        gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, 64, 64, gl.RGBA, gl.UNSIGNED_BYTE, 42);
-     },
-     "exception");
-
-test("Passing texSubImage2D parameter data of String type should throw a TypeError",
-     function () {
-        gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, 64, 64, gl.RGBA, gl.UNSIGNED_BYTE, "not a buffer");
-     },
-     "exception");
-
-debug("");
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-input-validation.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-input-validation.html
deleted file mode 100644
index 683fcbf..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-input-validation.html
+++ /dev/null
@@ -1,384 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<div id="description"></div>
-<div id="console"></div>
-
-<script>
-"use strict";
-var wtu = WebGLTestUtils;
-var gl = null;
-var tex = null;
-var error = 0;
-
-function enumToString(value) {
-  return wtu.glEnumToString(gl, value);
-}
-
-function testTexImage2D(testCase)
-{
-    var level = 0;
-    var width = 16;
-    var height = 16;
-    var msg = "" +
-      " internalFormat: " + enumToString(testCase.internalFormat) +
-      " target: " + enumToString(testCase.target) +
-      " format: " + enumToString(testCase.format) +
-      " type: " + enumToString(testCase.type) +
-      " border: " + testCase.border;
-
-    gl.texImage2D(testCase.target, level, testCase.internalFormat, width, height, testCase.border, testCase.format, testCase.type, null);
-    error = testCase.expectedError;
-    glErrorShouldBe(gl, error, msg);
-}
-
-function testTexSubImage2D(testCase)
-{
-    var level = 0;
-    var xoffset = 0;
-    var yoffset = 0;
-    var width = 16;
-    var height = 16;
-    var msg = ""+
-        " format: " + enumToString(testCase.format) +
-        " type: " + enumToString(testCase.type);
-    var array = new Uint8Array(width * height * 4);
-    gl.texSubImage2D(testCase.target, level, xoffset, yoffset, width, height, testCase.format, testCase.type, array);
-    error = testCase.expectedError;
-    glErrorShouldBe(gl, error, msg);
-}
-
-function testTexParameter(testCase)
-{
-    var msg = "paramName: " + enumToString(testCase.pname);
-    error = testCase.expectedError;
-    gl.texParameteri(testCase.target, testCase.pname, testCase.param);
-    glErrorShouldBe(gl, error, msg);
-    gl.texParameterf(testCase.target, testCase.pname, testCase.param);
-    glErrorShouldBe(gl, error, msg);
-}
-
-function testGetTexParameter(testCase)
-{
-    var msg = "paramName: " + enumToString(testCase.pname);
-    error = testCase.expectedError;
-    gl.getTexParameter(testCase.target, testCase.pname);
-    glErrorShouldBe(gl, error, msg);
-}
-
-function testCopyTexImage2D(testCase)
-{
-    var level = 0;
-    var x = 0;
-    var y = 0;
-    var width = 16;
-    var height = 16;
-
-    var msg = "" +
-      " colorBufferFormat: " + enumToString(testCase.colorBufferFormat) +
-      " internalFormat: " + enumToString(testCase.internalFormat) +
-      " target: " + enumToString(testCase.target) +
-      " border: " + testCase.border;
-
-    gl.renderbufferStorage(gl.RENDERBUFFER, testCase.colorBufferFormat, width, height);
-    glErrorShouldBe(gl, gl.NO_ERROR);
-    shouldBe("gl.checkFramebufferStatus(gl.FRAMEBUFFER)", "gl.FRAMEBUFFER_COMPLETE");
-
-    gl.copyTexImage2D(testCase.target, level, testCase.internalFormat, x, y, width, height, testCase.border);
-    error = testCase.expectedError;
-    glErrorShouldBe(gl, error, msg);
-}
-
-function testCopyTexSubImage2D(testCase)
-{
-    var level = 0;
-    var x = 0;
-    var y = 0;
-    var width = 16;
-    var height = 16;
-    var xoffset = 0;
-    var yoffset = 0;
-    var border = 0;
-    var type = gl.UNSIGNED_BYTE;
-    var msg = "" +
-      " colorBufferFormat: " + enumToString(testCase.colorBufferFormat) +
-      " internalFormat: " + enumToString(testCase.internalFormat) +
-      " target: " + enumToString(testCase.target);
-
-    gl.renderbufferStorage(gl.RENDERBUFFER, testCase.colorBufferFormat, width, height);
-    glErrorShouldBe(gl, gl.NO_ERROR);
-    shouldBe("gl.checkFramebufferStatus(gl.FRAMEBUFFER)", "gl.FRAMEBUFFER_COMPLETE");
-
-    gl.texImage2D(testCase.target, level, testCase.internalFormat, xoffset + width, yoffset + height, border, testCase.internalFormat, type, null);
-    glErrorShouldBe(gl, gl.NO_ERROR);
-
-    gl.copyTexSubImage2D(testCase.target, level, xoffset, yoffset, x, y, width, height);
-    error = testCase.expectedError;
-    glErrorShouldBe(gl, error, msg);
-}
-
-function testCopyFromInternalFBO(testCase)
-{
-    var target = gl.TEXTURE_2D;
-    var level = 0;
-    var x = 0;
-    var y = 0;
-    var width = 16;
-    var height = 16;
-    var xoffset = 0;
-    var yoffset = 0;
-    var border = 0;
-    var type = gl.UNSIGNED_BYTE;
-    var msg = "" +
-      " colorBufferFormat: " + enumToString(testCase.contextAlpha ? gl.RGBA : gl.RGB) +
-      " internalFormat: " + enumToString(testCase.internalFormat);
-
-    if (testCase.contextAlpha)
-        gl = wtu.create3DContext(null, { alpha: true });
-    else
-        gl = wtu.create3DContext(null, { alpha: false });
-    shouldBeNonNull("gl");
-    shouldBeNonNull("tex = gl.createTexture()");
-    gl.bindTexture(target, tex);
-    if (testCase.subImage) {
-        gl.texImage2D(target, level, testCase.internalFormat, xoffset + width, yoffset + height, border, testCase.internalFormat, type, null);
-        glErrorShouldBe(gl, gl.NO_ERROR);
-        gl.copyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
-    } else {
-        glErrorShouldBe(gl, gl.NO_ERROR);
-        gl.copyTexImage2D(target, level, testCase.internalFormat, x, y, width, height, border);
-    }
-    error = testCase.expectedError;
-    glErrorShouldBe(gl, error, msg);
-}
-
-description("Validate tex functions input parameters");
-
-shouldBeNonNull("gl = wtu.create3DContext()");
-shouldBeNonNull("tex = gl.createTexture()");
-gl.bindTexture(gl.TEXTURE_2D, tex);
-glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("");
-debug("Checking TexImage2D: a set of inputs that are valid in GL but invalid in GLES2");
-
-var testCases =
-  [ {target: 0x8064, // GL_PROXY_TEXTURE_2D
-     internalFormat: gl.RGBA,
-     border: 0,
-     format: gl.RGBA,
-     type: gl.UNSIGNED_BYTE,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     internalFormat: 0x1903, // GL_RED
-     border: 0,
-     format: 0x1903, // GL_RED
-     type: gl.UNSIGNED_BYTE,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     internalFormat: gl.RGBA,
-     border: 1,
-     format: gl.RGBA,
-     type: gl.UNSIGNED_BYTE,
-     expectedError: gl.INVALID_VALUE},
-    {target: gl.TEXTURE_2D,
-     internalFormat: gl.RGBA,
-     border: 0,
-     format: gl.RGB,
-     type: gl.UNSIGNED_BYTE,
-     expectedError: gl.INVALID_OPERATION},
-    {target: gl.TEXTURE_2D,
-     internalFormat: gl.RGBA,
-     border: 0,
-     format: gl.RGBA,
-     type: gl.BYTE,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     internalFormat: gl.RGBA,
-     border: 0,
-     format: gl.RGBA,
-     type: gl.UNSIGNED_BYTE,
-     expectedError: gl.NO_ERROR} ];
-
-for (var ii = 0; ii < testCases.length; ++ii)
-    testTexImage2D(testCases[ii]);
-
-debug("");
-debug("Checking TexSubImage2D: a set of inputs that are valid in GL but invalid in GLES2");
-
-testCases =
-  [ {target: gl.TEXTURE_2D,
-     format: 0x1903, // GL_RED
-     type: gl.UNSIGNED_BYTE,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     format: gl.RGBA,
-     type: gl.BYTE,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     format: gl.RGBA,
-     type: gl.UNSIGNED_BYTE,
-     expectedError: gl.NO_ERROR} ];
-
-for (var ii = 0; ii < testCases.length; ++ii)
-    testTexSubImage2D(testCases[ii]);
-
-debug("");
-debug("Checking TexParameter: a set of inputs that are valid in GL but invalid in GLES2");
-
-testCases =
-  [ {target: 0x0DE0, // GL_TEXTURE_1D
-     pname: gl.TEXTURE_WRAP_T,
-     param: gl.REPEAT,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     pname: 0x813A, // GL_TEXTURE_MIN_LOD
-     param: 0,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     pname: gl.TEXTURE_WRAP_T,
-     param: 0x2900, // GL_CLAMP
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     pname: gl.TEXTURE_WRAP_T,
-     param: gl.REPEAT,
-     expectedError: gl.NO_ERROR} ];
-
-for (var ii = 0; ii < testCases.length; ++ii)
-    testTexParameter(testCases[ii]);
-
-debug("");
-debug("Checking GetTexParameter: a set of inputs that are valid in GL but invalid in GLES2");
-
-testCases =
-  [ {target: 0x0DE0, // GL_TEXTURE_1D
-     pname: gl.TEXTURE_WRAP_T,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     pname: 0x813A, // GL_TEXTURE_MIN_LOD
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     pname: gl.TEXTURE_WRAP_T,
-     expectedError: gl.NO_ERROR} ];
-
-for (var ii = 0; ii < testCases.length; ++ii)
-    testGetTexParameter(testCases[ii]);
-
-debug("");
-debug("Checking CopyTexImage2D: a set of inputs that are valid in GL but invalid in GLES2");
-
-var colorBuffer = null;
-var fbo = null;
-
-shouldBeNonNull("fbo = gl.createFramebuffer()");
-gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);
-shouldBeNonNull("colorBuffer = gl.createRenderbuffer()");
-gl.bindRenderbuffer(gl.RENDERBUFFER, colorBuffer);
-gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.RENDERBUFFER, colorBuffer);
-glErrorShouldBe(gl, gl.NO_ERROR);
-
-testCases =
-  [ {target: gl.TEXTURE_2D,
-     colorBufferFormat: gl.RGB565,
-     internalFormat: 0x8054, // GL_RGB16
-     border: 0,
-     expectedError: gl.INVALID_ENUM},
-    {target: gl.TEXTURE_2D,
-     colorBufferFormat: gl.RGB565,
-     internalFormat: gl.RGBA,
-     border: 1,
-     expectedError: gl.INVALID_VALUE},
-    {target: gl.TEXTURE_2D,
-     colorBufferFormat: gl.RGB565,
-     internalFormat: gl.RGBA,
-     border: 0,
-     expectedError: gl.INVALID_OPERATION},
-    {target: gl.TEXTURE_2D,
-     colorBufferFormat: gl.RGB565,
-     internalFormat: gl.RGB,
-     border: 0,
-     expectedError: gl.NO_ERROR} ];
-
-for (var ii = 0; ii < testCases.length; ++ii)
-    testCopyTexImage2D(testCases[ii]);
-
-debug("");
-debug("Checking CopyTexSubImage2D: a set of inputs that are valid in GL but invalid in GLES2");
-
-testCases =
-  [ {target: gl.TEXTURE_2D,
-     colorBufferFormat: gl.RGB5_A1,
-     internalFormat: gl.RGBA,
-     expectedError: gl.NO_ERROR},
-    {target: gl.TEXTURE_2D,
-     colorBufferFormat: gl.RGB565,
-     internalFormat: gl.RGBA,
-     expectedError: gl.INVALID_OPERATION} ];
-
-for (var ii = 0; ii < testCases.length; ++ii)
-    testCopyTexSubImage2D(testCases[ii]);
-
-debug("");
-debug("Checking CopyTex{Sub}Image2D: copy from WebGL internal framebuffer");
-
-testCases =
-  [ {contextAlpha: true,
-     internalFormat: gl.RGBA,
-     subImage: false,
-     expectedError: gl.NO_ERROR},
-    {contextAlpha: false,
-     internalFormat: gl.RGBA,
-     subImage: false,
-     expectedError: gl.INVALID_OPERATION},
-    {contextAlpha: true,
-     internalFormat: gl.RGBA,
-     subImage: true,
-     expectedError: gl.NO_ERROR},
-    {contextAlpha: false,
-     internalFormat: gl.RGBA,
-     subImage: true,
-     expectedError: gl.INVALID_OPERATION} ];
-
-for (var ii = 0; ii < testCases.length; ++ii)
-    testCopyFromInternalFBO(testCases[ii]);
-
-var successfullyParsed = true;
-</script>
-
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d-bad-args.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d-bad-args.html
deleted file mode 100644
index ba0dad6..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d-bad-args.html
+++ /dev/null
@@ -1,93 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="testbed" width="16" height="16"></canvas>
-<canvas id="c" width="16" height="16"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description('Tests texSubImage2D with bad arguments');
-
-var wtu = WebGLTestUtils;
-var c = document.getElementById("c");
-
-var gl = wtu.create3DContext("testbed");
-var tex = gl.createTexture();
-gl.bindTexture(gl.TEXTURE_2D, tex);
-gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.NO_ERROR, "Setup should succeed"); 
-
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 1, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_VALUE, "y + height > texture height");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_VALUE, "x + width > texture width");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, -1, 0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_VALUE, "negative x");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, -1, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_VALUE, "negative y");
-gl.texSubImage2D(gl.TEXTURE_2D, -1, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_VALUE, "negative level");
-gl.texSubImage2D(gl.FLOAT, 0, 0,0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_ENUM, "bad target");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.NO_ERROR, "good args");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGB, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_OPERATION, "format not same as original");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGBA, gl.UNSIGNED_SHORT_4_4_4_4, c);
-glErrorShouldBe(gl, gl.INVALID_OPERATION, "type not same as original");
-gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGB, gl.RGB, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.NO_ERROR, "make texture RGB");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGB, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.NO_ERROR, "format same as original RGB");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGBA, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_OPERATION, "format not same as original RGB");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGB, gl.UNSIGNED_SHORT_5_6_5, c);
-glErrorShouldBe(gl, gl.INVALID_OPERATION, "type not same as original RGB");
-gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_SHORT_4_4_4_4, c);
-glErrorShouldBe(gl, gl.NO_ERROR, "make texture RGBA 4_4_4_4");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGBA, gl.UNSIGNED_SHORT_4_4_4_4, c);
-glErrorShouldBe(gl, gl.NO_ERROR, "format same as original RGBA 4_4_4_4");
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0, gl.RGB, gl.UNSIGNED_BYTE, c);
-glErrorShouldBe(gl, gl.INVALID_OPERATION, "format not same as original RGBA 4_4_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");
-
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d.html
deleted file mode 100644
index 91cf096..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/tex-sub-image-2d.html
+++ /dev/null
@@ -1,123 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.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">
-precision mediump float;
-
-uniform sampler2D tex;
-varying vec2 texCoord;
-
-void main()
-{
-    float intensity = texture2D(tex, texCoord).a;
-    gl_FragColor = vec4(intensity, intensity, intensity, 1.0);
-}
-</script>
-
-</head>
-<body>
-<canvas id="example" width="256" height="1"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description('Tests texSubImage2D upload path from Uint8Array');
-
-var wtu = WebGLTestUtils;
-var canvas = document.getElementById("example");
-var gl = wtu.create3DContext(canvas);
-gl.disable(gl.DITHER);
-var program = wtu.setupProgram(
-    gl,
-    [wtu.setupSimpleTextureVertexShader(gl), "fshader"],
-    ['vPosition', 'texCoord0']);
-wtu.setupUnitQuad(gl);
-var textureWidth = 256;
-var textureHeight = 1;
-
-var textureLoc = gl.getUniformLocation(program, "tex");
-
-var texture = gl.createTexture();
-gl.bindTexture(gl.TEXTURE_2D, texture);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-// Allocate the texture object
-gl.texImage2D(gl.TEXTURE_2D, 0, gl.ALPHA, textureWidth, textureHeight, 0, gl.ALPHA, gl.UNSIGNED_BYTE, null);
-// Prepare the image data
-var array = new Uint8Array(textureWidth);
-for (var i = 0; i < textureWidth; i++)
-    array[i] = i;
-// Fill the texture object with data -- this is actually the code path being tested
-gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, textureWidth, textureHeight, gl.ALPHA, gl.UNSIGNED_BYTE, array);
-
-// Clear and set up
-gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-gl.bindTexture(gl.TEXTURE_2D, texture);
-gl.useProgram(program);
-gl.uniform1i(textureLoc, 0);
-// Draw the texture to the frame buffer
-gl.drawArrays(gl.TRIANGLES, 0, 6);
-
-// Read back the frame buffer
-var buf = new Uint8Array(textureWidth * textureHeight * 4);
-gl.readPixels(0, 0, textureWidth, textureHeight, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-
-// Verify the frame buffer's contents
-var passed = true;
-for (var i = 0; i < textureWidth; i++) {
-    var val = i;
-    if (buf[4 * i + 0] != val ||
-        buf[4 * i + 1] != val ||
-        buf[4 * i + 2] != val) {
-        testFailed("pixel at (" + i + ", 0) was (" +
-                   buf[4 * i + 0] + ", " +
-                   buf[4 * i + 1] + ", " +
-                   buf[4 * i + 2] + "), should be (" +
-                   val + ", " + val + ", " + val + ")");
-        passed = false;
-        break;
-    }
-}
-
-if (passed)
-    testPassed("");
-
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texparameter-test.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texparameter-test.html
deleted file mode 100644
index 79c4452..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texparameter-test.html
+++ /dev/null
@@ -1,206 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-  <head>
-<meta charset="utf-8">
-    <title>WebGL TexParameter conformance test.</title>
-    <link rel="stylesheet" href="../../resources/js-test-style.css"/>
-    <script src="../../resources/js-test-pre.js"></script>
-    <script src="../resources/webgl-test.js"> </script>
-    <script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="24" height="24"></canvas>
-<canvas id="canvas2d" width="2" height="2"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-uniform mat4 world;
-attribute vec3 vPosition;
-attribute vec2 texCoord0;
-varying vec2 texCoord;
-void main()
-{
-  gl_Position = world * vec4(vPosition, 1);
-  texCoord = texCoord0;
-}
-</script>
-
-<script id="fshader" type="x-shader/x-fragment">
-precision mediump float;
-
-uniform sampler2D tex;
-varying vec2 texCoord;
-void main()
-{
-  gl_FragColor = texture2D(tex, texCoord);
-}
-</script>
-
-<script>
-"use strict";
-function init()
-{
-  description("Tests TexParameter works as expected");
-  debug("");
-
-  var canvas2d = document.getElementById("canvas2d");
-  var ctx2d = canvas2d.getContext("2d");
-
-  var wtu = WebGLTestUtils;
-  var gl = wtu.create3DContext("example");
-  var program = wtu.setupProgram(gl, ["vshader", "fshader"], ["vPosition", "texCoord0"]);
-
-  var vertexObject = gl.createBuffer();
-  gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
-  gl.bufferData(
-      gl.ARRAY_BUFFER,
-      new Float32Array([-1, 1,0, 1,1,0, -1,-1,0,
-                           -1,-1,0, 1,1,0,  1,-1,0]),
-      gl.STATIC_DRAW);
-  gl.enableVertexAttribArray(0);
-  gl.vertexAttribPointer(0, 3, gl.FLOAT, false, 0, 0);
-
-  var vertexObject = gl.createBuffer();
-  gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
-  gl.bufferData(
-      gl.ARRAY_BUFFER,
-      new Float32Array([ -2.5,-2.5, 3.5,-2.5, -2.5,3.5,
-                            -2.5,3.5, 3.5,-2.5, 3.5,3.5]),
-      gl.STATIC_DRAW);
-  gl.enableVertexAttribArray(1);
-  gl.vertexAttribPointer(1, 2, gl.FLOAT, false, 0, 0);
-
-  var colors = [
-      [0,255,128,255],
-      [128,64,255,255],
-      [192,255,64,255],
-      [200,0,255,255]];
-  var texParam = [
-    gl.REPEAT,
-    gl.CLAMP_TO_EDGE,
-    gl.MIRRORED_REPEAT,
-    gl.REPEAT];
-
-  // Make textures setting the texture parameters differently each time..
-  // This verifies both that the render correct AND that texture parameters
-  // are associated with the textures, not with the texture-units.
-  var textures = [];
-  for (var ii = 0; ii < colors.length; ++ii) {
-    var c = colors[ii];
-    ctx2d.fillStyle =
-        "rgba(" + c[0] + "," + c[1] + "," + c[2] + "," + c[3] + ")";
-    ctx2d.fillRect(0, 0, 1, 1);
-    var tex = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, tex);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas2d);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, texParam[ii]);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, texParam[ii]);
-    textures[ii] = tex;
-  }
-
-  var textureLoc = gl.getUniformLocation(program, "tex");
-  var worldLoc = gl.getUniformLocation(program, "world");
-
-  gl.clearColor(1,1,1,1);
-  gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-
-  for (var ii = 0; ii < colors.length; ++ii) {
-    var x = ii % 2;
-    var y = Math.floor(ii / 2);
-    gl.bindTexture(gl.TEXTURE_2D, textures[ii]);
-    gl.uniformMatrix4fv(
-        worldLoc, false,
-        [0.5, 0, 0, 0,
-         0, 0.5, 0, 0,
-         0, 0, 1, 0,
-         -0.5 + x, -0.5 + y, 0, 1]);
-    gl.drawArrays(gl.TRIANGLES, 0, 6);
-  }
-
-  var buf = new Uint8Array(24 * 24 * 4);
-  gl.readPixels(0, 0, 24, 24, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-  var passed = true;
-  for (var ii = 0; ii < colors.length; ++ii) {
-    var x = ii % 2;
-    var y = Math.floor(ii / 2);
-    var c = colors[ii];
-    for (var yy = 0; yy < 12; ++yy) {
-      for (var xx = 0; xx < 12; ++xx) {
-        var ec = [0,0,0,0];
-        switch (texParam[ii]) {
-          case gl.REPEAT:
-            if (xx % 2 == 1 && yy % 2 == 0) {
-              ec = c;
-            }
-            break;
-          case gl.CLAMP_TO_EDGE:
-            if (xx < 6 && yy >= 6) {
-              ec = c;
-            }
-            break;
-          case gl.MIRRORED_REPEAT:
-            if (xx % 4 < 2 && yy % 4 >= 2) {
-              ec = c;
-            }
-            break;
-        }
-        var off = ((y * 12 + yy) * 24 + x * 12 + xx) * 4;
-        if (buf[off + 0] != ec[0] ||
-            buf[off + 1] != ec[1] ||
-            buf[off + 2] != ec[2] ||
-            buf[off + 3] != ec[3]) {
-          var msg = 'at (' + (x * 12 + xx) + ', ' + (y * 12 + yy) +
-              ') expected: ' +
-              ec[0] + ', ' + ec[1] + ', ' + ec[2] + ', ' + ec[3] + ' found: ' +
-              buf[off + 0] + ', ' +
-              buf[off + 1] + ', ' +
-              buf[off + 2] + ', ' +
-              buf[off + 3];
-          testFailed(msg);
-          passed = false;
-        }
-      }
-    }
-  }
-  if (passed) {
-    testPassed("rendered as expected");
-   }
-}
-
-init();
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind-2.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind-2.html
deleted file mode 100644
index 2996221..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind-2.html
+++ /dev/null
@@ -1,192 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-  <head>
-<meta charset="utf-8">
-    <title>WebGL ActiveTexture BindTexture conformance test #2</title>
-    <link rel="stylesheet" href="../../resources/js-test-style.css"/>
-    <script src="../../resources/js-test-pre.js"></script>
-    <script src="../resources/webgl-test.js"> </script>
-    <script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="2" height="2" style="width: 40px; height: 40px;"></canvas>
-<canvas id="canvas2d" width="1" height="1" style="width: 40px; height: 40px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-uniform mat4 world;
-attribute vec3 vPosition;
-attribute vec2 texCoord0;
-varying vec2 texCoord;
-void main()
-{
-  gl_Position = world * vec4(vPosition, 1);
-  texCoord = texCoord0;
-}
-</script>
-<script id="fshader2d" type="x-shader/x-fragment">
-precision mediump float;
-
-uniform sampler2D tex2d;
-varying vec2 texCoord;
-void main()
-{
-  gl_FragColor = texture2D(tex2d, texCoord);
-}
-</script>
-<script id="fshaderCube" type="x-shader/x-fragment">
-precision mediump float;
-
-uniform samplerCube texCube;
-void main()
-{
-  gl_FragColor = textureCube(texCube, vec3(0,1,0));
-}
-</script>
-
-<script>
-"use strict";
-function init()
-{
-  description(
-      "Tests that binding both TEXTURE_2D and TEXTURE_CUBE_MAP to the same" +
-      "active texture unit works as long as they are not used" +
-      "simultaneously in the same shader program.");
-
-  var canvas2d = document.getElementById("canvas2d");
-  var ctx2d = canvas2d.getContext("2d");
-  ctx2d.globalCompositeOperation = "copy";
-
-  var wtu = WebGLTestUtils;
-  var gl = wtu.create3DContext("example");
-  var program = wtu.setupProgram(
-      gl, ["vshader", "fshader2d"], ["vPosition", "texCoord0"]);
-
-  var program2d = program;
-  var programCube = wtu.setupProgram(
-      gl, ["vshader", "fshaderCube"], ["vPosition", "texCoord0"]);
-
-  var vertexObject = gl.createBuffer();
-  gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
-  gl.bufferData(
-      gl.ARRAY_BUFFER,
-      new Float32Array([-1, 1,0, 1,1,0, -1,-1,0,
-                        -1,-1,0, 1,1,0,  1,-1,0]),
-      gl.STATIC_DRAW);
-  gl.enableVertexAttribArray(0);
-  gl.vertexAttribPointer(0, 3, gl.FLOAT, false, 0, 0);
-
-  var vertexObject = gl.createBuffer();
-  gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
-  gl.bufferData(
-      gl.ARRAY_BUFFER,
-      new Float32Array([ 0,0, 1,0, 0,1,
-                         0,1, 1,0, 1,1]),
-      gl.STATIC_DRAW);
-  gl.enableVertexAttribArray(1);
-  gl.vertexAttribPointer(1, 2, gl.FLOAT, false, 0, 0);
-
-  // Make texture unit 1 active.
-  gl.activeTexture(gl.TEXTURE1);
-
-  // Make a 2d texture
-  var tex2d = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex2d);
-  ctx2d.fillStyle = "rgba(0, 0, 255, 255)";
-  ctx2d.fillRect(0, 0, 1, 1);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas2d);
-
-  // make a cube texture
-  var texCube = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_CUBE_MAP, texCube);
-  ctx2d.fillStyle = "rgba(255, 0, 255, 255)";
-  ctx2d.fillRect(0, 0, 1, 1);
-  var targets = [
-    gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-    gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-    gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_Z];
-  for (var ii = 0; ii < targets.length; ++ii) {
-    gl.texImage2D(targets[ii], 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas2d);
-  }
-
-  // Setup program2d and programCube
-  var tex2dLoc = gl.getUniformLocation(program2d, "tex2d");
-  var world2dLoc = gl.getUniformLocation(program2d, "world");
-  var texCubeLoc = gl.getUniformLocation(programCube, "texCube");
-  var worldCubeLoc = gl.getUniformLocation(programCube, "world");
-
-  gl.useProgram(program2d);
-  gl.uniform1i(tex2dLoc, 1);
-  gl.useProgram(programCube);
-  gl.uniform1i(texCubeLoc, 1);
-
-  gl.clearColor(1,0,0,1);
-  gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-
-  var programs = [program2d, programCube];
-  var worldLocs = [world2dLoc, worldCubeLoc];
-  for (var ii = 0; ii < 4; ++ii) {
-    var x = ii % 2;
-    var y = Math.floor(ii / 2);
-    gl.useProgram(programs[x]);
-    gl.uniformMatrix4fv(
-        worldLocs[x], false,
-        [0.5, 0, 0, 0,
-         0, 0.5, 0, 0,
-         0, 0, 1, 0,
-         -0.5 + x, -0.5 + y, 0, 1]);
-    gl.drawArrays(gl.TRIANGLES, 0, 6);
-  }
-
-  var colors = [
-      [0,0,255,255],
-      [255,0,255,255],
-      [0,0,255,255],
-      [255,0,255,255]];
-
-  for (var ii = 0; ii < colors.length; ++ii) {
-    var c = colors[ii];
-    var x = ii % 2;
-    var y = Math.floor(ii / 2);
-    wtu.checkCanvasRect(gl, x, y, 1, 1, c);
-  }
-}
-
-init();
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind.html
deleted file mode 100644
index eb9a792..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-active-bind.html
+++ /dev/null
@@ -1,157 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL ActiveTexture BindTexture conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="2" height="2" style="width: 40px; height: 40px;"></canvas>
-<canvas id="canvas2d" width="1" height="1" style="width: 40px; height: 40px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-uniform mat4 world;
-attribute vec3 vPosition;
-attribute vec2 texCoord0;
-varying vec2 texCoord;
-void main()
-{
-  gl_Position = world * vec4(vPosition, 1);
-  texCoord = texCoord0;
-}
-</script>
-<script>
-"use strict";
-var gl;
-
-function init()
-{
-  description(
-      "Tests that glActiveTexture and glBindTexture work as expected" +
-      "Specifically texture targets are per active texture unit.");
-
-  var canvas2d = document.getElementById("canvas2d");
-  var ctx2d = canvas2d.getContext("2d");
-
-  var wtu = WebGLTestUtils;
-  gl = wtu.create3DContext("example");
-  var program = wtu.setupProgram(
-      gl,
-      ["vshader", wtu.setupSimpleTextureFragmentShader(gl)],
-      ['vPosition', 'texCoord0']);
-  wtu.setupUnitQuad(gl);
-  gl.disable(gl.DEPTH_TEST);
-  gl.disable(gl.BLEND);
-  glErrorShouldBe(gl, gl.NO_ERROR);
-
-  var colors = [
-      [0,192,128,255],
-      [128,64,255,255],
-      [192,255,64,255],
-      [200,0,255,255]];
-
-  // Make 4 textures by using 4 active texture units if available.
-  var texunits = Math.min(colors.length, gl.getParameter(gl.MAX_COMBINED_TEXTURE_IMAGE_UNITS))
-  var textures = [];
-  for (var ii = 0; ii < texunits; ++ii) {
-    var tex = gl.createTexture();
-    gl.activeTexture(gl.TEXTURE0 + ii);
-    gl.bindTexture(gl.TEXTURE_2D, tex);
-    textures[ii] = tex;
-  }
-  glErrorShouldBe(gl, gl.NO_ERROR);
-
-  // now use each texture unit to write into the textures,
-  for (var ii = 0; ii < texunits; ++ii) {
-    var c = colors[ii];
-    ctx2d.fillStyle =
-        "rgba(" + c[0] + "," + c[1] + "," + c[2] + "," + c[3] + ")";
-    ctx2d.fillRect(0, 0, 1, 1);
-    gl.activeTexture(gl.TEXTURE0 + ii);
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas2d);
-  }
-  glErrorShouldBe(gl, gl.NO_ERROR);
-
-  var textureLoc = gl.getUniformLocation(program, "tex");
-  var worldLoc = gl.getUniformLocation(program, "world");
-  glErrorShouldBe(gl, gl.NO_ERROR);
-
-  gl.clearColor(1,0,0,1);
-  gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-
-  for (var ii = 0; ii < texunits; ++ii) {
-    var x = ii % 2;
-    var y = Math.floor(ii / 2);
-    gl.uniform1i(textureLoc, ii);
-    gl.uniformMatrix4fv(
-        worldLoc, false,
-        [0.5, 0, 0, 0,
-         0, 0.5, 0, 0,
-         0, 0, 1, 0,
-         -0.5 + x, -0.5 + y, 0, 1]);
-    gl.drawArrays(gl.TRIANGLES, 0, 6);
-  }
-  glErrorShouldBe(gl, gl.NO_ERROR);
-
-  for (var ii = 0; ii < texunits; ++ii) {
-    var c = colors[ii];
-    var x = ii % 2;
-    var y = Math.floor(ii / 2);
-    var buf = new Uint8Array(4);
-    gl.readPixels(x, y, 1, 1, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-    var msg = 'expected:' +
-        c[0] + ', ' + c[1] + ', ' + c[2] + ', ' + c[3] + ' found: ' +
-        buf[0] + ', ' +
-        buf[1] + ', ' +
-        buf[2] + ', ' +
-        buf[3];
-    if (buf[0] != c[0] ||
-        buf[1] != c[1] ||
-        buf[2] != c[2] ||
-        buf[3] != c[3])
-      testFailed(msg);
-    else
-      testPassed(msg);
-  }
-}
-
-init();
-var successfullyParsed = true;
-</script>
-
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-attachment-formats.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-attachment-formats.html
deleted file mode 100644
index 6a9a28d..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-attachment-formats.html
+++ /dev/null
@@ -1,199 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Texture Attachment Format Conformance Tests</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<div id="description"></div>
-<div id="console"></div>
-<canvas id="canvas" width="2" height="2" style="width: 100px; height:100px; border: 1px solid black;"> </canvas>
-<script>
-"use strict";
-description();
-
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("canvas");
-if (!gl) {
-  testFailed("context does not exist");
-} else {
-  testPassed("context exists");
-
-  debug("");
-  debug("Checking texture formats.");
-
-  var numValidFormats = 0;
-  var clearColor = [0.25, 0.5, 0.75, 0.25];
-
-  var floatToBits = function(value, bits) {
-    var range = (1 << bits) - 1;
-    var result = 0;
-    if (range > 0) {
-      result = Math.floor(Math.floor(value * range) * 255 / range);
-    }
-
-    //debug("v = " + value + ", bits = " + bits + ", range = " + range  + ", result = " + result);
-    return result;
-  }
-
-  var testFormat = function(info) {
-    debug("");
-    debug("testing: " + info.format + ", " + info.type);
-
-    var format = gl[info.format];
-    var type = gl[info.type];
-
-    gl.texImage2D(gl.TEXTURE_2D,
-                  0,                 // level
-                  format,            // internalFormat
-                  16,                // width
-                  16,                // height
-                  0,                 // border
-                  format,            // format
-                  type,              // type
-                  null);             // data
-    var fbStatus = gl.checkFramebufferStatus(gl.FRAMEBUFFER);
-    debug(wtu.glEnumToString(gl, fbStatus));
-    if (fbStatus != gl.FRAMEBUFFER_COMPLETE) {
-      debug("format unsupported");
-      if (info.mustBeFramebufferComplete) {
-        testFailed(info.format + " must be FRAMEBUFFER_COMPLETE");
-      }
-      return;
-    }
-
-    ++numValidFormats;
-
-    var startExpected = [0, 0, 0, info.channels[3] < 0 ? 255 : 0];
-
-    var expected = [];
-    var tolerance = [];
-    for (var ii = 0; ii < 4; ++ii) {
-      var color = 0;
-      var channel = info.channels[ii];
-      if (channel < 0) {
-        color = ii < 3 ? 0 : 255
-      } else {
-        color = floatToBits(clearColor[channel], info.bits[ii]);
-      }
-      expected.push(color);
-      tolerance.push(channel < 0 ? 0 : (1 + (1 << (8 - info.bits[ii]))));
-    }
-
-    wtu.checkCanvas(gl, startExpected, "should be " + startExpected);
-    gl.clear(gl.COLOR_BUFFER_BIT);
-    wtu.checkCanvas(gl, expected, "should be " + expected + " with tolerance " + tolerance, tolerance);
-  }
-
-  var validFormats = [
-    { format: 'RGBA',
-      type:  'UNSIGNED_BYTE',
-      channels: [0, 1, 2, 3],
-      bits: [8, 8, 8, 8],
-      mustBeFramebufferComplete: true
-    },
-    { format: 'ALPHA',
-      type:  'UNSIGNED_BYTE',
-      channels: [-1, -1, -1, 3],
-      bits: [0, 0, 0, 8],
-      mustBeFramebufferComplete: false
-    },
-    { format: 'RGB',
-      type:  'UNSIGNED_BYTE',
-      channels: [0, 1, 2, -1],
-      bits: [8, 8, 8, 0],
-      mustBeFramebufferComplete: false
-    },
-    { format: 'RGB',
-      type:  'UNSIGNED_SHORT_5_6_5',
-      channels: [0, 1, 2, -1],
-      bits: [5, 6, 5, 0],
-      mustBeFramebufferComplete: false
-    },
-    { format: 'RGBA',
-      type:  'UNSIGNED_SHORT_5_5_5_1',
-      channels: [0, 1, 2, 3],
-      bits: [5, 5, 5, 1],
-      mustBeFramebufferComplete: false
-    },
-    { format: 'RGBA',
-      type:  'UNSIGNED_SHORT_4_4_4_4',
-      channels: [0, 1, 2, 3],
-      bits: [4, 4, 4, 4],
-      mustBeFramebufferComplete: false
-    },
-    { format: 'LUMINANCE',
-      type:  'UNSIGNED_BYTE',
-      channels: [0, 0, 0, -1],
-      bits: [8, 8, 8, -1],
-      mustBeFramebufferComplete: false
-    },
-    { format: 'LUMINANCE_ALPHA',
-      type:  'UNSIGNED_BYTE',
-      channels: [0, 0, 0, 3],
-      bits: [8, 8, 8, 8],
-      mustBeFramebufferComplete: false
-    }
-  ];
-
-  gl.clearColor(clearColor[0], clearColor[1], clearColor[2], clearColor[3]);
-  var fbo = gl.createFramebuffer();
-  gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-  gl.framebufferTexture2D(
-      gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, tex, 0);
-
-  for (var ii = 0; ii < validFormats.length; ++ii) {
-    var info = validFormats[ii];
-    testFormat(info);
-  }
-
-  debug("");
-  shouldBeTrue("numValidFormats > 0");
-  glErrorShouldBe(gl, gl.NO_ERROR, "there should be no errors");
-}
-
-debug("");
-var successfullyParsed = true;
-
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-clear.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-clear.html
deleted file mode 100644
index 8c7679f..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-clear.html
+++ /dev/null
@@ -1,65 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL texture clear conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="4" height="4" style="width: 40px; height: 30px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description(document.title);
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("example");
-var program = wtu.setupTexturedQuad(gl);
-
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-var tex = gl.createTexture();
-gl.bindTexture(gl.TEXTURE_2D, tex);
-gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
-gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, new Uint8Array([0,255,0,255]));
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 255, 0, 255], "should be green");
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-complete.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-complete.html
deleted file mode 100644
index 822cf4e..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-complete.html
+++ /dev/null
@@ -1,86 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL "Texture Complete" texture conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="40" height="40" style="width: 40px; height: 40px;"></canvas>
-<canvas id="canvas2d" width="16" height="16" style="width: 40px; height: 40px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-function init()
-{
-  description(
-      "Checks that a texture that is not -texture-complete- does not draw if"+
-      " filtering needs mips");
-
-  var canvas2d = document.getElementById("canvas2d");
-  var ctx2d = canvas2d.getContext("2d");
-  ctx2d.fillStyle = "rgba(0,192,128,1)";
-  ctx2d.fillRect(0, 0, 16, 16);
-
-  var wtu = WebGLTestUtils;
-  var canvas = document.getElementById("example");
-  var gl = wtu.create3DContext(canvas);
-  var program = wtu.setupTexturedQuad(gl);
-
-  gl.disable(gl.DEPTH_TEST);
-  gl.disable(gl.BLEND);
-
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  // 16x16 texture no mips
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas2d);
-
-  var loc = gl.getUniformLocation(program, "tex");
-  gl.uniform1i(loc, 0);
-
-  wtu.clearAndDrawUnitQuad(gl);
-  wtu.checkCanvas(gl, [0,0,0,255],
-      "texture that is not -texture-complete- when " +
-      "TEXTURE_MIN_FILTER not NEAREST or LINEAR should draw with 0,0,0,255");
-}
-
-init();
-var successfullyParsed = true;
-</script>
-
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-formats-test.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-formats-test.html
deleted file mode 100644
index 8247fa5..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-formats-test.html
+++ /dev/null
@@ -1,291 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Texture Format Conformance Tests</title>
-<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/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<div id="description"></div>
-<div id="console"></div>
-<canvas id="canvas2d" width="2" height="2" style="width: 50px; height: 50px; border: 1px solid black;"></canvas>
-<canvas id="canvas" width="2" height="2" style="width: 100px; height:100px; border: 1px solid black;"> </canvas>
-<script>
-"use strict";
-description("This test ensures WebGL implementations allow the OpenGL ES 2.0 texture formats and do not allow DesktopGL texture formats.");
-
-debug("");
-debug("Canvas.getContext");
-
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("canvas");
-if (!gl) {
-  testFailed("context does not exist");
-} else {
-  testPassed("context exists");
-
-  debug("");
-  debug("Checking texture formats.");
-
-  var createTexture = function(internalFormat, format, opt_border) {
-      var border = (opt_border === undefined) ? 0 : opt_border;
-      var tex = gl.createTexture();
-      gl.bindTexture(gl.TEXTURE_2D, tex);
-      gl.texImage2D(gl.TEXTURE_2D,
-                    0,                 // level
-                    internalFormat,    // internalFormat
-                    16,                // width
-                    16,                // height
-                    border,            // border
-                    format,            // format
-                    gl.UNSIGNED_BYTE,  // type
-                    null);             // data
-  }
-
-  var testValidFormat = function(internalFormat, formatName) {
-      createTexture(internalFormat, internalFormat);
-      glErrorShouldBe(gl, gl.NO_ERROR,
-                "was able to create texture of " + formatName);
-  }
-
-  var testInvalidFormat = function(internalFormat, formatName) {
-      createTexture(internalFormat, internalFormat);
-      var err = gl.getError();
-      if (err == gl.NO_ERROR) {
-          testFailed("should NOT be able to create texture of type " + formatName);
-      } else if (err == gl.INVALID_OPERATION) {
-          testFailed("should return gl.INVALID_ENUM for type " + formatName);
-      } else if (err == gl.INVALID_ENUM) {
-          testPassed("not able to create invalid format: " + formatName);
-      }
-  }
-
-  var invalidEnums = [
-    '1',
-    '2',
-    '3',
-    '4',
-    'RGB4',
-    'RGB5',
-    'RGB8',
-    'RGB10',
-    'RGB12',
-    'RGB16',
-    'RGBA2',
-    'RGBA4',
-    'RGB5_A1',
-    'RGBA8',
-    'RGB10_A2',
-    'RGBA12',
-    'RGBA16',
-    'BGR',
-    'BGRA',
-    'ALPHA4_EXT',
-    'ALPHA8_EXT',
-    'ALPHA12_EXT',
-    'ALPHA16_EXT',
-    'COMPRESSED_ALPHA',
-    'COMPRESSED_LUMINANCE',
-    'COMPRESSED_LUMINANCE_ALPHA',
-    'COMPRESSED_INTENSITY',
-    'COMPRESSED_RGB',
-    'COMPRESSED_RGBA',
-    'DEPTH_COMPONENT16',
-    'DEPTH_COMPONENT24',
-    'DEPTH_COMPONENT32',
-    'LUMINANCE4_EXT',
-    'LUMINANCE8_EXT',
-    'LUMINANCE12_EXT',
-    'LUMINANCE16_EXT',
-    'LUMINANCE4_ALPHA4_EXT',
-    'LUMINANCE6_ALPHA2_EXT',
-    'LUMINANCE8_ALPHA8_EXT',
-    'LUMINANCE12_ALPHA4_EXT',
-    'LUMINANCE12_ALPHA12_EXT',
-    'LUMINANCE16_ALPHA16_EXT',
-    'INTENSITY_EXT',
-    'INTENSITY4_EXT',
-    'INTENSITY8_EXT',
-    'INTENSITY12_EXT',
-    'INTENSITY16_EXT',
-    'RGB4_EXT',
-    'RGB5_EXT',
-    'RGB8_EXT',
-    'RGB10_EXT',
-    'RGB12_EXT',
-    'RGB16_EXT',
-    'RGBA2_EXT',
-    'RGBA4_EXT',
-    'RGB5_A1_EXT',
-    'RGBA8_EXT',
-    'RGB10_A2_EXT',
-    'RGBA12_EXT',
-    'RGBA16_EXT',
-    'SLUMINANCE_EXT',
-    'SLUMINANCE8_EXT',
-    'SLUMINANCE_ALPHA_EXT',
-    'SLUMINANCE8_ALPHA8_EXT',
-    'SRGB_EXT',
-    'SRGB8_EXT',
-    'SRGB_ALPHA_EXT',
-    'SRGB8_ALPHA8'
-  ];
-
-  for (var ii = 0; ii < invalidEnums.length; ++ii) {
-    var formatName = invalidEnums[ii]
-    if (desktopGL[formatName] === undefined) {
-      debug("bad format" + formatName)
-    } else {
-      testInvalidFormat(desktopGL[formatName], "GL_" + formatName);
-    }
-  }
-
-  var validEnums = [
-    'ALPHA',
-    'RGB',
-    'RGBA',
-    'LUMINANCE',
-    'LUMINANCE_ALPHA'
-  ];
-
-  for (var ii = 0; ii < validEnums.length; ++ii) {
-    var formatName = validEnums[ii]
-    testValidFormat(gl[formatName], "gl." + formatName);
-  }
-
-  debug("");
-  debug("checking non 0 border parameter to gl.TexImage2D");
-  createTexture(gl['RGBA'], gl['RGBA'], 1);
-  glErrorShouldBe(gl, gl.INVALID_VALUE,
-            "non 0 border to gl.TexImage2D should return INVALID_VALUE");
-
-
-  var checkTypes = function() {
-    var tex = gl.createTexture();
-    gl.bindTexture(gl.TEXTURE_2D, tex);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-
-    var loc = gl.getUniformLocation(program, "tex");
-    gl.uniform1i(loc, 0);
-
-    var checkType = function(r, g, b, a, type, format, buf) {
-      var typeName = wtu.glEnumToString(gl, type);
-      var formatName = wtu.glEnumToString(gl, format);
-      var desc = "format: " + formatName + ", type: " + typeName;
-      debug("");
-      debug("checking gl.texImage2D with " + desc);
-      gl.texImage2D(gl.TEXTURE_2D,
-                    0,                 // level
-                    format,            // internalFormat
-                    2,                 // width
-                    2,                 // height
-                    0,                 // border
-                    format,            // format
-                    type,              // type
-                    buf);              // data
-
-      glErrorShouldBe(gl, gl.NO_ERROR,
-                "gl.texImage2D with " + desc + " should generate NO_ERROR");
-
-      wtu.clearAndDrawUnitQuad(gl, [255, 0, 0, 255]);
-      wtu.checkCanvas(gl, [r,g,b,a],
-                      "texture " + desc + " should draw with " +
-                      r + ", " + g + ", " + b + ", " + a);
-
-   }
-   checkType(
-       0, 255, 0, 255, gl.UNSIGNED_BYTE, gl.RGBA,
-       new Uint8Array(
-         [ 0, 255, 0, 255,
-           0, 255, 0, 255,
-           0, 255, 0, 255,
-           0, 255, 0, 255]));
-   checkType(
-       0, 0, 255, 255, gl.UNSIGNED_SHORT_4_4_4_4, gl.RGBA,
-       new Uint16Array(
-         [ 255, 255,
-           255, 255,
-           255, 255,
-           255, 255]));
-   checkType(
-       0, 255, 0, 255, gl.UNSIGNED_SHORT_5_6_5, gl.RGB,
-       new Uint16Array(
-         [ 2016, 2016,
-           2016, 2016,
-           2016, 2016,
-           2016, 2016]));
-   checkType(
-       0, 0, 255, 255, gl.UNSIGNED_SHORT_5_5_5_1, gl.RGBA,
-       new Uint16Array(
-         [ 63, 63,
-           63, 63,
-           63, 63,
-           63, 63]));
-   checkType(
-       255, 255, 255, 255, gl.UNSIGNED_BYTE, gl.LUMINANCE,
-       new Uint8Array([
-           255,
-           255,
-           255,
-           255]));
-   checkType(
-       0, 0, 0, 128, gl.UNSIGNED_BYTE, gl.ALPHA,
-       new Uint8Array([
-           128,
-           128,
-           128,
-           128]));
-   checkType(
-       128, 128, 128, 192, gl.UNSIGNED_BYTE, gl.LUMINANCE_ALPHA,
-       new Uint8Array([
-           128, 192,
-           128, 192,
-           128, 192,
-           128, 192]));
-  }
-  var program = wtu.setupTexturedQuad(gl);
-  gl.pixelStorei(gl.UNPACK_ALIGNMENT, 1);
-  checkTypes();
-}
-
-debug("");
-var successfullyParsed = true;
-
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-hd-dpi.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-hd-dpi.html
deleted file mode 100644
index 71ae2f8..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-hd-dpi.html
+++ /dev/null
@@ -1,140 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL HD-DPI issues texture conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="4" height="4" style="width: 40px; height: 30px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description();
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("example");
-var program = wtu.setupTexturedQuad(gl);
-
-function fillInMips(gl, size) {
-  // fill in the mips
-  var level = 1;
-  for (;;) {
-    size /= 2;
-    if (size < 1) {
-      break;
-    }
-    var numBytes = size * size * 4;
-    var pixels = new Uint8Array(numBytes);
-    for (var jj = 0; jj < numBytes; jj += 4) {
-      pixels[jj + 0] = 0;
-      pixels[jj + 1] = 255;
-      pixels[jj + 2] = 0;
-      pixels[jj + 3] = 255;
-    }
-    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, size, size, 0, gl.RGBA, gl.UNSIGNED_BYTE, pixels);
-  }
-}
-
-function testCanvas(size) {
-  debug("");
-  debug("testing 2D canvas size " + size + ", " + size);
-
-  var canvas = document.createElement("canvas");
-  canvas.width = size;
-  canvas.height = size;
-  var ctx = canvas.getContext("2d");
-  ctx.fillStyle = "rgb(0,255,0)";
-  ctx.fillRect(0, 0, size, size);
-
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas);
-
-  fillInMips(gl, size);
-
-  // Draw. If this an HD-DPI device and the 2d canvas is double res or larger
-  // the implementation must scale to CSS pixels (ie, canvas.width, canvas.height)(
-  // when doing the copy in texImage2D. If it has not scaled and instead done
-  // a direct copy of the larger texture this test will not have created enough mips
-  // and will therefore not be "texture complete" and will render in black.
-  wtu.clearAndDrawUnitQuad(gl);
-  wtu.checkCanvas(gl, [0, 255, 0, 255], "should be green");
-}
-
-function testWebGL(size) {
-  debug("");
-  debug("testing WebGL canvas size " + size + ", " + size);
-
-  var canvas = document.createElement("canvas");
-  canvas.width = size;
-  canvas.height = size;
-  var gl2 = wtu.create3DContext(canvas);
-  gl2.clearColor(0,1,0,1);
-  gl2.clear(gl.COLOR_BUFFER_BIT);
-
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas);
-
-  fillInMips(gl, size);
-
-  // Draw. If this an HD-DPI device check for 2 possible bugs.
-  //
-  // 1) the WebGL canvas is double res or larger. That's just a bug period and
-  //    is checked for in another test but would also fail here.
-  //
-  // 2) the WebGL canvas is single res but the code the scales a double res
-  //    2d canvas also mistakenly scales a single res WebGL canvas.
-  //
-  // If it has been scaled then we'll have the wrong kind of mips chain here.
-  // Level 0 will be half resolution. Level 1 will be the same resolution
-  // and will therefore not be "texture complete" and will render in black.
-  wtu.clearAndDrawUnitQuad(gl);
-  wtu.checkCanvas(gl, [0, 255, 0, 255], "should be green");
-}
-
-testCanvas(4);
-testCanvas(512);
-testWebGL(4);
-testWebGL(512);
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors");
-
-var successfullyParsed = true;
-
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-mips.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-mips.html
deleted file mode 100644
index e4c2e80..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-mips.html
+++ /dev/null
@@ -1,319 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL texture mips conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="2" height="2" style="width: 40px; height: 40px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-uniform vec4 uMult;
-attribute vec4 vPosition;
-attribute vec2 texCoord0;
-varying vec2 texCoord;
-void main()
-{
-    gl_Position = vPosition * uMult;
-    texCoord = texCoord0;
-}
-</script>
-
-<script id="fshader" type="x-shader/x-fragment">
-precision mediump float;
-uniform sampler2D tex;
-varying vec2 texCoord;
-void main()
-{
-    gl_FragColor = texture2D(tex, texCoord);
-}
-</script>
-<script>
-"use strict";
-var canvas;
-var wtu = WebGLTestUtils;
-function init()
-{
-  description("Checks mip issues");
-
-  canvas = document.getElementById("example");
-  shouldBe("canvas.width", "2");
-  shouldBe("canvas.height", "2");
-
-  var gl = wtu.create3DContext(canvas);
-
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  gl.generateMipmap(gl.TEXTURE_2D);
-  glErrorShouldBe(gl, gl.INVALID_OPERATION, "for generateMipmap with mip 0 is 0x0");
-  gl.texImage2D(
-      gl.TEXTURE_2D, 1, gl.RGBA, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE,
-      new Uint8Array(4));
-  gl.generateMipmap(gl.TEXTURE_2D);
-  glErrorShouldBe(gl, gl.INVALID_OPERATION, "for generateMipmap with mip 0 is 0x0");
-
-  tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_CUBE_MAP, tex);
-  gl.generateMipmap(gl.TEXTURE_CUBE_MAP);
-  glErrorShouldBe(gl, gl.INVALID_OPERATION, "for generateMipmap with mip 0 is 0x0");
-
-  var faces = [
-    gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-    gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-    gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_Z
-  ];
-  for (var ii = 0; ii < faces.length; ++ii) {
-    gl.texImage2D(
-        faces[ii], 0, gl.RGBA, 2, 2, 0, gl.RGBA, gl.UNSIGNED_BYTE,
-        new Uint8Array(4 * 2 * 2));
-    gl.generateMipmap(gl.TEXTURE_CUBE_MAP);
-    glErrorShouldBe(gl, ii == 5 ? gl.NO_ERROR : gl.INVALID_OPERATION, "for generateMipmap with " + (ii + 1) + " faces");
-  }
-
-  wtu.setupUnitQuad(gl, 0, 1);
-  var program = wtu.setupProgram(
-      gl, ['vshader', 'fshader'], ['vPosition', 'texCoord0'], [0, 1]);
-
-  gl.disable(gl.DEPTH_TEST);
-  gl.disable(gl.BLEND);
-
-  var colors = {
-    blue: [0, 0, 255, 255],
-    red: [255, 0, 0, 255],
-    green:  [0, 255, 0, 255],
-    cyan: [128, 255, 255, 255],
-    black: [0, 0, 0, 255],
-    blank: [0, 0, 0, 0]
-  };
-
-  var mips = [
-  ];
-
-  var texLoc = gl.getUniformLocation(program, "tex");
-  gl.uniform1i(texLoc, 0);
-  var multLoc = gl.getUniformLocation(program, "uMult");
-
-  // ----------------------------------------------------
-  var clearTex = createTexture();
-  gl.uniform4f(multLoc, 1, 1, 1, 1);
-  gl.bindTexture(gl.TEXTURE_2D, clearTex);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 16, 16, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
-  debug('gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 16, 16, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);');
-  setMipData(0, 16, 'blank');
-  makeDivMipChain();
-  generateMipmap();
-  check('blank', "texture created with null that has all mips");
-
-  // ----------------------------------------------------
-  var tex = createTexture();
-  gl.uniform4f(multLoc, 1, 1, 1, 1);
-
-  gl.bindTexture(gl.TEXTURE_2D, tex);
-  // 16x16 texture no mips
-  fillLevel(tex, 0, 16, 'cyan');
-
-  check('black',
-        "texture that is missing mips when TEXTURE_MIN_FILTER not NEAREST or LINEAR");
-
-  generateMipmap();
-
-  check('cyan', "texture that has all mips");
-
-  // Fill in the bottom 2 mips with a different color.
-  fillLevel(tex, 4, 1, 'green');
-  fillLevel(tex, 3, 2, 'green');
-
-  // Choose the nearest mip
-  texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_NEAREST);
-
-  check('green', "texture that is only using the smallest 2 mips");
-
-  gl.uniform4f(multLoc, 16, 16, 1, 1);
-
-  check('cyan', "texture that is using only the largest 2 mips");
-
-  // Set the top level
-  fillLevel(tex, 0, 1, 'red');
-  check('red',
-        "texture that is only using the top level even though other levels are defined");
-
-  // Set the top 2 levels using generateMipmap
-  fillLevel(tex, 0, 2, 'blue');
-  generateMipmap();
-
-  check('blue',
-        "texture that is only using the top 2 levels even though other levels are defined");
-
-  // Set the top 2 levels back to sizes that end up using levels 2, 3, and 4 again.
-  fillLevel(tex, 0, 16, 'blue');
-  fillLevel(tex, 1, 8, 'blue');
-  check('blue', "texture that is only using the largest 2 mips");
-  gl.uniform4f(multLoc, 1, 1, 1, 1);
-  check('green', "texture that is only using the smallest 2 mips");
-
-  // ----------------------------------------------------
-  var tex = createTexture();
-  gl.uniform4f(multLoc, 1, 1, 1, 1);
-  fillLevel(tex, 0, 8, 'cyan');
-  generateMipmap();
-  check('cyan', "texture that has 3 mips");
-
-  fillLevel(tex, 0, 16, 'blue');
-  texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-  check('blue', "texture that is only using top mips");
-
-  fillLevel(tex, 0, 8, 'red');
-  texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_NEAREST);
-  check('cyan', "texture that is only using smallest mips");
-
-  gl.uniform4f(multLoc, 16, 16, 1, 1);
-  check('red', "texture that is using only the largest mip");
-
-  // ----------------------------------------------------
-  var tex = createTexture();
-  gl.uniform4f(multLoc, 1, 1, 1, 1);
-  fillLevel(tex, 2, 1, 'green');
-  fillLevel(tex, 1, 2, 'green');
-  fillLevel(tex, 0, 4, 'green');
-  check('green', "texture that was built smallest mip first");
-
-  // ----------------------------------------------------
-  var tex = createTexture();
-  gl.uniform4f(multLoc, 1, 1, 1, 1);
-  fillLevel(tex, 0, 16, 'red');
-  generateMipmap();
-  check('red', "texture with 1 genmipmaps");
-  fillLevel(tex, 0, 16, 'blue');
-  generateMipmap();
-  fillLevel(tex, 0, 16, 'green');
-  generateMipmap();
-  check('green', "texture with 2 genmipmaps");
-
-  // ----------------------------------------------------
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors.");
-
-  function createTexture() {
-    debug("<hr/>gl.createTexture()");
-    mips = [];
-    makeDivMipChain();
-    return gl.createTexture();
-  }
-
-  function texParameteri(target, pname, value) {
-    debug("gl.texParameteri(" +
-          wtu.glEnumToString(gl, target) + ", " +
-          wtu.glEnumToString(gl, pname) + ", " +
-          wtu.glEnumToString(gl, value) + ")")
-    gl.texParameteri(target, pname, value);
-  }
-
-  function generateMipmap() {
-    debug("gl.generateMipmap(gl.TEXTURE_2D)");
-    gl.generateMipmap(gl.TEXTURE_2D);
-    var mip0 = mips[0];
-    var size = mip0.size;
-    var level = 1;
-    for(;;) {
-      size = Math.floor(size / 2);
-      if (!size) {
-        break;
-      }
-      setMipData(level, size, mip0.color);
-      ++level;
-    }
-    makeDivMipChain();
-  }
-
-  function check(color, msg) {
-    wtu.clearAndDrawUnitQuad(gl);
-    wtu.checkCanvas(gl, colors[color], msg + " should draw with " + color);
-  }
-
-  function fillLevel(tex, level, size, color) {
-    setMipData(level, size, color);
-    debug("gl.texImage2D(gl.TEXTURE_2D, " + level + ", gl.RGBA, " + size + ", " + size +
-          ", 0, gl.RGBA, gl.UNSIGNED_BYTE, " + color + ");");
-    wtu.fillTexture(gl, tex, size, size, colors[color], level);
-    makeDivMipChain();
-  }
-
-  function setMipData(level, size, color) {
-    mips[level] = {
-      size: size,
-      color: color
-    };
-  }
-
-  function makeDivMipChain(color) {
-    var html = [
-      '<div style="height: 68px; margin-top: 5px">',
-      '<div style="float:left;">mips: </div>'];
-    for (var ii = 0; ii < 5; ++ii) {
-      var mip = mips[ii];
-      if (mip) {
-        html.push(makeDivSquare(mip.size, mip.color));
-      } else {
-        html.push(makeDivSquare(16, undefined));
-      }
-    }
-    html.push("</div>");
-    debug(html.join(""));
-  }
-
-  function makeDivSquare(size, color) {
-    size *= 4;
-    var c = color ? colors[color] : [255,255,255];
-    var border = color ? 'solid' : 'dashed';
-    return '<div style="float:left; width: ' + size + 'px; height: ' + size +
-           'px; background-color: ' + rgb(c) +
-           '; border: 1px ' + border + ' black; margin-right: 3px;"></div>';
-  }
-
-  function rgb(c) {
-    return 'rgb(' + c[0] + ',' + c[1] + ',' + c[2] +')';
-  }
-}
-
-init();
-var successfullyParsed = true;
-</script>
-
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot-video.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot-video.html
deleted file mode 100644
index 01fb483..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot-video.html
+++ /dev/null
@@ -1,177 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-<script>
-"use strict";
-var wtu = WebGLTestUtils;
-var gl = null;
-var textureLoc = null;
-var successfullyParsed = false;
-var video;
-
-initTestingHarnessWaitUntilDone();
-
-function init()
-{
-    description('Verify npot video');
-
-    var canvas = document.getElementById("example");
-    gl = wtu.create3DContext(canvas);
-    var program = wtu.setupTexturedQuad(gl);
-
-    gl.clearColor(0,0,0,1);
-    gl.clearDepth(1);
-
-    textureLoc = gl.getUniformLocation(program, "tex");
-
-    video = document.getElementById("vid");
-    wtu.startPlayingAndWaitForVideo(video, runTest);
-}
-
-// These two declarations need to be global for "shouldBe" to see them
-var buf = null;
-var idx = 0;
-var pixel = [0, 0, 0];
-var correctColor = null;
-var texture;
-
-function runOneIteration(videoElement, useTexSubImage2D, flipY, topColor, bottomColor, badMinFilter, badClamp, genMips)
-{
-    debug('Testing ' + (useTexSubImage2D ? 'texSubImage2D' : 'texImage2D') +
-          ' with flipY=' + flipY);
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    // Disable any writes to the alpha channel
-    gl.colorMask(1, 1, 1, 0);
-    if (!texture) {
-        texture = gl.createTexture();
-    }
-    // Bind the texture to texture unit 0
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-    // Set up pixel store parameters
-    gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, flipY);
-    // Upload the videoElement into the texture
-    debug("size: " + videoElement.videoWidth + "x" + videoElement.videoHeight);
-    if (useTexSubImage2D) {
-        // Initialize the texture to black first
-        debug("use texSubImage2D");
-        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA,
-                      videoElement.videoWidth, videoElement.videoHeight, 0,
-                      gl.RGBA, gl.UNSIGNED_BYTE, null);
-        gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, videoElement);
-    } else {
-        debug("use texImage2D");
-        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, videoElement);
-    }
-
-    // Set up texture parameters
-    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-    if (badMinFilter) {
-        debug("bad min filter");
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_NEAREST);
-    } else {
-        debug("good min filter");
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-    }
-    if (badClamp) {
-        debug("bad clamp");
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.REPEAT);
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.REPEAT);
-    } else {
-        debug("good clamp");
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-    }
-    if (genMips) {
-        debug("generate mips");
-        gl.generateMipmap(gl.TEXTURE_2D);
-        glErrorShouldBe(gl, gl.INVALID_OPERATION, "should be INVALID_OPERATION");
-    }
-
-    gl.bindTexture(gl.TEXTURE_2D, null);
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-
-//    var c = document.createElement("canvas");
-//    c.width = 16;
-//    c.height = 16;
-//    c.style.border = "1px solid black";
-//    var ctx = c.getContext("2d");
-//    ctx.drawImage(videoElement, 0, 0, 16, 16);
-//    document.body.appendChild(c);
-
-    // Point the uniform sampler to texture unit 0
-    gl.uniform1i(textureLoc, 0);
-    // Draw the triangles
-    wtu.clearAndDrawUnitQuad(gl, [0, 0, 0, 255]);
-    // Check a few pixels near the top and bottom and make sure they have
-    // the right color.
-    var tolerance = 5;
-    debug("Checking lower left corner");
-    wtu.checkCanvasRect(gl, 4, 4, 2, 2, bottomColor,
-                        "shouldBe " + bottomColor, tolerance);
-    debug("Checking upper left corner");
-    wtu.checkCanvasRect(gl, 4, gl.canvas.height - 8, 2, 2, topColor,
-                        "shouldBe " + topColor, tolerance);
-    debug("");
-}
-
-function runTest(videoElement)
-{
-    var red = [255, 0, 0];
-    var green = [0, 255, 0];
-    var black = [0, 0, 0];
-    runOneIteration(videoElement, false, true, black, black, true, true, true);
-    runOneIteration(videoElement, false, true, black, black, true, false, false);
-    runOneIteration(videoElement, false, true, black, black, false, true, false);
-    runOneIteration(videoElement, false, true, black, black, true, true, false);
-    runOneIteration(videoElement, false, true, green, red, false, false, false);
-    runOneIteration(videoElement, false, false, red, green, false, false, false);
-    runOneIteration(videoElement, true, true, green, red, false, false, false);
-    runOneIteration(videoElement, true, false, red, green, false, false, false);
-
-    glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
-    finishTest();
-}
-</script>
-</head>
-<body onload="init()">
-<canvas id="example" width="64" height="48"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<video id="vid" style="display:none;">
-  <source src="../resources/npot-video.mp4"  type='video/mp4; codecs="avc1.42E01E"' />
-  <source src="../resources/npot-video.webmvp8.webm" type='video/webm; codecs="vp8"' />
-  <source src="../resources/npot-video.theora.ogv"  type='video/ogg; codecs="theora"' />
-</video>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot.html
deleted file mode 100644
index 6dd8af2..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-npot.html
+++ /dev/null
@@ -1,248 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Non-Power of 2 texture conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"> </script>
-</head>
-<body>
-<canvas id="example" width="4" height="4" style="width: 40px; height: 30px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-attribute vec4 vPosition;
-attribute vec2 texCoord0;
-varying vec2 texCoord;
-void main()
-{
-    gl_Position = vPosition;
-    texCoord = texCoord0;
-}
-</script>
-
-<script id="fshader" type="x-shader/x-fragment">
-precision mediump float;
-uniform samplerCube tex;
-varying vec2 texCoord;
-void main()
-{
-    gl_FragColor = textureCube(tex, normalize(vec3(texCoord, 1)));
-}
-</script>
-<script>
-"use strict";
-description(document.title);
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("example");
-var program = wtu.setupTexturedQuad(gl);
-
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-var tex = gl.createTexture();
-
-// Check that an NPOT texture not on level 0 generates INVALID_VALUE
-wtu.fillTexture(gl, tex, 5, 3, [0, 192, 128, 255], 1);
-glErrorShouldBe(gl, gl.INVALID_VALUE,
-    "gl.texImage2D with NPOT texture with level > 0 should return INVALID_VALUE");
-
-// Check that an NPOT texture on level 0 succeeds
-wtu.fillTexture(gl, tex, 5, 3, [0, 192, 128, 255]);
-glErrorShouldBe(gl, gl.NO_ERROR,
-    "gl.texImage2D with NPOT texture at level 0 should succeed");
-
-// Check that generateMipmap fails on NPOT
-gl.generateMipmap(gl.TEXTURE_2D);
-glErrorShouldBe(gl, gl.INVALID_OPERATION,
-    "gl.generateMipmap with NPOT texture should return INVALID_OPERATION");
-
-var loc = gl.getUniformLocation(program, "tex");
-gl.uniform1i(loc, 0);
-
-// Check that nothing is drawn if filtering is not correct for NPOT
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.REPEAT);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.REPEAT);
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 0, 0, 255],
-    "NPOT texture with TEXTURE_WRAP set to REPEAT should draw with 0,0,0,255");
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST_MIPMAP_LINEAR);
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 0, 0, 255],
-    "NPOT texture with TEXTURE_MIN_FILTER not NEAREST or LINEAR should draw with 0,0,0,255");
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 192, 128, 255],
-    "NPOT texture with TEXTURE_MIN_FILTER set to LINEAR should draw.");
-
-gl.copyTexImage2D(gl.TEXTURE_2D, 1, gl.RGBA, 0, 0, 5, 3, 0);
-glErrorShouldBe(gl, gl.INVALID_VALUE,
-    "copyTexImage2D with NPOT texture with level > 0 should return INVALID_VALUE.");
-
-// Check that generateMipmap for an POT texture succeeds
-wtu.fillTexture(gl, tex, 4, 4, [0, 192, 128, 255]);
-gl.generateMipmap(gl.TEXTURE_2D);
-glErrorShouldBe(gl, gl.NO_ERROR,
-    "gl.texImage2D and gl.generateMipmap with POT texture at level 0 should succeed");
-
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_LINEAR);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.REPEAT);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.REPEAT);
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 192, 128, 255],
-    "POT texture with TEXTURE_MIN_FILTER set to LINEAR_MIPMAP_LINEAR should draw.");
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-debug("");
-debug("check using cubemap");
-var program = wtu.setupProgram(
-    gl, ['vshader', 'fshader'], ['vPosition', 'texCoord0'], [0, 1]);
-var tex = gl.createTexture();
-
-// Check that an NPOT texture not on level 0 generates INVALID_VALUE
-fillCubeTexture(gl, tex, 5, 3, [0, 192, 128, 255], 1);
-glErrorShouldBe(gl, gl.INVALID_VALUE,
-    "gl.texImage2D with NPOT texture with level > 0 should return INVALID_VALUE");
-
-// Check that an NPOT texture on level 0 succeeds
-fillCubeTexture(gl, tex, 5, 5, [0, 192, 128, 255]);
-glErrorShouldBe(gl, gl.NO_ERROR,
-    "gl.texImage2D with NPOT texture at level 0 should succeed");
-
-// Check that generateMipmap fails on NPOT
-gl.generateMipmap(gl.TEXTURE_CUBE_MAP);
-glErrorShouldBe(gl, gl.INVALID_OPERATION,
-    "gl.generateMipmap with NPOT texture should return INVALID_OPERATION");
-
-var loc = gl.getUniformLocation(program, "tex");
-gl.uniform1i(loc, 0);
-
-// Check that nothing is drawn if filtering is not correct for NPOT
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_WRAP_S, gl.REPEAT);
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_WRAP_T, gl.REPEAT);
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 0, 0, 255],
-    "NPOT cubemap with TEXTURE_WRAP set to REPEAT should draw with 0,0,0,255");
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER, gl.NEAREST_MIPMAP_LINEAR);
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 0, 0, 255],
-    "NPOT cubemap with TEXTURE_MIN_FILTER not NEAREST or LINEAR should draw with 0,0,0,255");
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 192, 128, 255],
-    "NPOT cubemap with TEXTURE_MIN_FILTER set to LINEAR should draw.");
-
-// Check that an POT texture on level 0 succeeds
-fillCubeTexture(gl, tex, 4, 4, [0, 192, 128, 255]);
-glErrorShouldBe(gl, gl.NO_ERROR,
-    "gl.texImage2D with POT texture at level 0 should succeed");
-
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_LINEAR);
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_WRAP_S, gl.REPEAT);
-gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_WRAP_T, gl.REPEAT);
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 0, 0, 255],
-    "POT cubemap with TEXTURE_MIN_FILTER set to LINEAR_MIPMAP_LINEAR but no mips draw with 0,0,0,255");
-
-// Check that generateMipmap succeeds on POT
-gl.generateMipmap(gl.TEXTURE_CUBE_MAP);
-glErrorShouldBe(gl, gl.NO_ERROR,
-    "gl.generateMipmap with POT texture should return succeed");
-
-wtu.clearAndDrawUnitQuad(gl);
-wtu.checkCanvas(
-    gl, [0, 192, 128, 255],
-    "POT cubemap with TEXTURE_MIN_FILTER set to LINEAR_MIPMAP_LINEAR should draw.");
-
-var successfullyParsed = true;
-
-function fillCubeTexture(gl, tex, width, height, color, opt_level) {
-  opt_level = opt_level || 0;
-  var canvas = document.createElement('canvas');
-  canvas.width = width;
-  canvas.height = height;
-  var ctx2d = canvas.getContext('2d');
-  ctx2d.fillStyle = "rgba(" + color[0] + "," + color[1] + "," + color[2] + "," + color[3] + ")";
-  ctx2d.fillRect(0, 0, width, height);
-  gl.bindTexture(gl.TEXTURE_CUBE_MAP, tex);
-  var targets = [
-    gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-    gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-    gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_Z];
-  for (var tt = 0; tt < targets.length; ++tt) {
-    gl.texImage2D(
-        targets[tt], opt_level, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, canvas);
-  }
-};
-
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-cube-maps.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-cube-maps.html
deleted file mode 100644
index 7f454c4..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-cube-maps.html
+++ /dev/null
@@ -1,355 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL texture size cube map conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="256" height="256" style="width: 40px; height: 40px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-attribute vec4 vPosition;
-uniform mat4 rotation;
-varying vec3 texCoord;
-void main()
-{
-    gl_Position = vPosition;
-    vec4 direction = vec4(vPosition.x * 0.5, vPosition.y * 0.5, 1, 1);
-    texCoord = normalize((rotation * direction).xyz);
-}
-</script>
-
-<script id="fshader" type="x-shader/x-fragment">
-precision mediump float;
-uniform samplerCube tex;
-varying vec3 texCoord;
-void main()
-{
-    gl_FragColor = textureCube(tex, normalize(texCoord));
-}
-</script>
-<script>
-"use strict";
-var canvas;
-description("Checks issues with size of cube map textures");
-debug("");
-
-var wtu = WebGLTestUtils;
-var canvas = document.getElementById("example");
-
-var gl = wtu.create3DContext(canvas);
-wtu.setupUnitQuad(gl, 0, 1);
-var program = wtu.setupProgram(
-    gl,
-    ['vshader', 'fshader'],
-    ['vPosition', 'texCoord0'], [0, 1]);
-var rotLoc = gl.getUniformLocation(program, "rotation");
-
-gl.disable(gl.DEPTH_TEST);
-gl.disable(gl.BLEND);
-
-var maxSize = gl.getParameter(gl.MAX_CUBE_MAP_TEXTURE_SIZE);
-debug("max cube map size: " + maxSize);
-maxSize = Math.min(512, maxSize);
-
-// a cube map of 512x512 takes 6meg. I'm assuming it's not
-// unreasonable to expect to be able to allocate a 6meg texture
-
-var colors = [
-  {name: 'red',     color: [255,   0,   0, 255]},
-  {name: 'green',   color: [  0, 255,   0, 255]},
-  {name: 'blue',    color: [  0,   0, 255, 255]},
-  {name: 'yellow',  color: [255, 255,   0, 255]},
-  {name: 'cyan',    color: [  0, 255, 255, 255]},
-  {name: 'magenta', color: [255,   0, 255, 255]}
-];
-
-var targets = [
-  gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-  gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-  gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-  gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-  gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-  gl.TEXTURE_CUBE_MAP_NEGATIVE_Z];
-
-var rotations = [
-  {axis: [0, 1, 0], angle:  Math.PI / 2},
-  {axis: [0, 1, 0], angle: -Math.PI / 2},
-  {axis: [1, 0, 0], angle: -Math.PI / 2},
-  {axis: [1, 0, 0], angle:  Math.PI / 2},
-  {axis: [0, 1, 0], angle:  0},
-  {axis: [0, 1, 0], angle:  Math.PI},
-];
-
-var halfRotations = [
-  {colors: [3, 4], rotations: [{axis: [1, 0, 0], angle:  Math.PI / 4}]},
-  {colors: [4, 2], rotations: [{axis: [1, 0, 0], angle: -Math.PI / 4}]},
-  {colors: [5, 3], rotations: [{axis: [1, 0, 0], angle:  Math.PI / 4 * 3}]},
-  {colors: [2, 5], rotations: [{axis: [1, 0, 0], angle: -Math.PI / 4 * 3}]},
-  {colors: [3, 0], rotations: [{axis: [0, 1, 0], angle:  Math.PI / 2},
-                               {axis: [1, 0, 0], angle:  Math.PI / 4}]},
-  {colors: [0, 2], rotations: [{axis: [0, 1, 0], angle:  Math.PI / 2},
-                               {axis: [1, 0, 0], angle: -Math.PI / 4}]},
-];
-
-var count = 0;
-var sizeCount = 0;
-
-test();
-
-function test() {
-  var size = Math.pow(2, sizeCount);
-  if (size > maxSize || !testSize(size)) {
-    finishTest();
-  } else {
-    ++sizeCount;
-    setTimeout(test, 0);
-  }
-}
-
-function testSize(size) {
-  debug("");
-  debug("testing size: " + size);
-  var canvasSize = Math.max(size / 4, 2);
-  canvas.width = canvasSize;
-  canvas.height = canvasSize;
-  gl.viewport(0, 0, canvasSize, canvasSize);
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_CUBE_MAP, tex);
-
-  // Seems like I should be using LINEAR here with some other math
-  // to make sure I get more mip coverage but that's easier said
-  // than done.
-
-  gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-  gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-
-  for (var jj = 0; jj < 2; ++jj) {
-    for (var tt = 0; tt < targets.length; ++tt) {
-      var color = colors[(tt + count) % colors.length];
-      fillLevel(targets[tt], 0, size, color.color);
-    }
-    if (jj == 1) {
-      debug("use mipmap");
-      gl.texParameteri(
-          gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER,
-          gl.NEAREST_MIPMAP_NEAREST);
-      gl.generateMipmap(gl.TEXTURE_CUBE_MAP);
-    }
-
-    var err = gl.getError();
-    if (err == gl.OUT_OF_MEMORY) {
-      debug("out of memory");
-      return false;
-    }
-    if (err != gl.NO_ERROR) {
-      testFailed("unexpected gl error: " + wtu.glEnumToString(gl, err));
-    }
-
-
-    for (var rr = 0; rr < rotations.length; ++rr) {
-      var rot = rotations[rr];
-      var color = colors[(rr + count) % colors.length];
-      var rotMat = axisRotation(rot.axis, rot.angle);
-      gl.uniformMatrix4fv(rotLoc, false, rotMat);
-      wtu.clearAndDrawUnitQuad(gl);
-      wtu.checkCanvas(
-          gl, color.color,
-          wtu.glEnumToString(gl, targets[rr]) + " should be " + color.name);
-    }
-
-    for (var rr = 0; rr < halfRotations.length; ++rr) {
-      var h = halfRotations[rr];
-      var rots = h.rotations;
-      var rotMat = axisRotation(rots[0].axis, rots[0].angle);
-      for (var ii = 1; ii < rots.length; ++ii) {
-        var tmpMat = axisRotation(rots[ii].axis, rots[ii].angle);
-        var rotMat = mulMatrix(tmpMat, rotMat);
-      }
-      gl.uniformMatrix4fv(rotLoc, false, rotMat);
-      wtu.clearAndDrawUnitQuad(gl);
-
-      for (var ii = 0; ii < 2; ++ii) {
-        checkRect(
-            0,
-            canvasSize / 2 * ii,
-            canvasSize,
-            canvasSize / 2,
-            colors[(h.colors[ii] + count) % colors.length]);
-      }
-    }
-    ++count;
-  }
-
-  gl.deleteTexture(tex);
-  return true;
-}
-
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors.");
-
-function checkRect(x, y, width, height, color) {
-  wtu.checkCanvasRect(
-       gl,
-       x,
-       y,
-       width,
-       height,
-       color.color,
-       "" + x + ", " + y + ", " + width + ", " + height +
-       " should be " + color.name);
-}
-
-function fillLevel(target, level, size, color) {
-  var numPixels = size * size;
-  var pixels = new Uint8Array(numPixels * 4);
-  var pixelRow = new Uint8Array(size * 4);
-  for (var jj = 0; jj < size; ++jj) {
-    var off = jj * 4;
-    pixelRow[off + 0] = color[0];
-    pixelRow[off + 1] = color[1];
-    pixelRow[off + 2] = color[2];
-    pixelRow[off + 3] = color[3];
-  }
-  for (var jj = 0; jj < size; ++jj) {
-    var off = jj * size * 4;
-    pixels.set(pixelRow, off);
-  }
-  gl.texImage2D(
-      target, level, gl.RGBA, size, size, 0, gl.RGBA, gl.UNSIGNED_BYTE,
-      pixels);
-}
-
-function printMat(mat) {
-  debug("" + mat[0] + ", " + mat[1] + ", " + mat[2] + ", " + mat[3] + ", ");
-  debug("" + mat[4] + ", " + mat[5] + ", " + mat[6] + ", " + mat[7] + ", ");
-  debug("" + mat[8] + ", " + mat[9] + ", " + mat[10] + ", " + mat[11] + ", ");
-  debug("" + mat[12] + ", " + mat[13] + ", " + mat[14] + ", " + mat[15] + ", ");
-}
-
-function axisRotation(axis, angle) {
-  var dst = new Float32Array(16);
-  var x = axis[0];
-  var y = axis[1];
-  var z = axis[2];
-  var n = Math.sqrt(x * x + y * y + z * z);
-  x /= n;
-  y /= n;
-  z /= n;
-  var xx = x * x;
-  var yy = y * y;
-  var zz = z * z;
-  var c = Math.cos(angle);
-  var s = Math.sin(angle);
-  var oneMinusCosine = 1 - c;
-
-  dst[ 0] = xx + (1 - xx) * c;
-  dst[ 1] = x * y * oneMinusCosine + z * s;
-  dst[ 2] = x * z * oneMinusCosine - y * s;
-  dst[ 3] = 0;
-  dst[ 4] = x * y * oneMinusCosine - z * s;
-  dst[ 5] = yy + (1 - yy) * c;
-  dst[ 6] = y * z * oneMinusCosine + x * s;
-  dst[ 7] = 0;
-  dst[ 8] = x * z * oneMinusCosine + y * s;
-  dst[ 9] = y * z * oneMinusCosine - x * s;
-  dst[10] = zz + (1 - zz) * c;
-  dst[11] = 0;
-  dst[12] = 0;
-  dst[13] = 0;
-  dst[14] = 0;
-  dst[15] = 1;
-
-  return dst;
-};
-
-function mulMatrix(a, b) {
-  var dst = new Float32Array(16);
-  var a00 = a[0];
-  var a01 = a[1];
-  var a02 = a[2];
-  var a03 = a[3];
-  var a10 = a[ 4 + 0];
-  var a11 = a[ 4 + 1];
-  var a12 = a[ 4 + 2];
-  var a13 = a[ 4 + 3];
-  var a20 = a[ 8 + 0];
-  var a21 = a[ 8 + 1];
-  var a22 = a[ 8 + 2];
-  var a23 = a[ 8 + 3];
-  var a30 = a[12 + 0];
-  var a31 = a[12 + 1];
-  var a32 = a[12 + 2];
-  var a33 = a[12 + 3];
-  var b00 = b[0];
-  var b01 = b[1];
-  var b02 = b[2];
-  var b03 = b[3];
-  var b10 = b[ 4 + 0];
-  var b11 = b[ 4 + 1];
-  var b12 = b[ 4 + 2];
-  var b13 = b[ 4 + 3];
-  var b20 = b[ 8 + 0];
-  var b21 = b[ 8 + 1];
-  var b22 = b[ 8 + 2];
-  var b23 = b[ 8 + 3];
-  var b30 = b[12 + 0];
-  var b31 = b[12 + 1];
-  var b32 = b[12 + 2];
-  var b33 = b[12 + 3];
-  dst[ 0] = a00 * b00 + a01 * b10 + a02 * b20 + a03 * b30;
-  dst[ 1] = a00 * b01 + a01 * b11 + a02 * b21 + a03 * b31;
-  dst[ 2] = a00 * b02 + a01 * b12 + a02 * b22 + a03 * b32;
-  dst[ 3] = a00 * b03 + a01 * b13 + a02 * b23 + a03 * b33;
-  dst[ 4] = a10 * b00 + a11 * b10 + a12 * b20 + a13 * b30;
-  dst[ 5] = a10 * b01 + a11 * b11 + a12 * b21 + a13 * b31;
-  dst[ 6] = a10 * b02 + a11 * b12 + a12 * b22 + a13 * b32;
-  dst[ 7] = a10 * b03 + a11 * b13 + a12 * b23 + a13 * b33;
-  dst[ 8] = a20 * b00 + a21 * b10 + a22 * b20 + a23 * b30;
-  dst[ 9] = a20 * b01 + a21 * b11 + a22 * b21 + a23 * b31;
-  dst[10] = a20 * b02 + a21 * b12 + a22 * b22 + a23 * b32;
-  dst[11] = a20 * b03 + a21 * b13 + a22 * b23 + a23 * b33;
-  dst[12] = a30 * b00 + a31 * b10 + a32 * b20 + a33 * b30;
-  dst[13] = a30 * b01 + a31 * b11 + a32 * b21 + a33 * b31;
-  dst[14] = a30 * b02 + a31 * b12 + a32 * b22 + a33 * b32;
-  dst[15] = a30 * b03 + a31 * b13 + a32 * b23 + a33 * b33;
-  return dst;
-};
-
-var successfullyParsed = true;
-</script>
-</body>
-</html>
-
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-limit.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-limit.html
deleted file mode 100644
index 43da9a6..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size-limit.html
+++ /dev/null
@@ -1,159 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL texture size limit conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="32" height="32" style="width: 40px; height: 40px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description("Checks that various sizes limits of textures ")
-var canvas;
-
-function numLevelsFromSize(size) {
-  var levels = 0;
-  while ((size >> levels) > 0) {
-    ++levels;
-  }
-  return levels;
-}
-
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("example");
-var tests = [
-  { format: gl.ALPHA,           type: gl.UNSIGNED_BYTE,          size: 1, dataType: Uint8Array  },
-  { format: gl.LUMINANCE,       type: gl.UNSIGNED_BYTE,          size: 1, dataType: Uint8Array  },
-  { format: gl.LUMINANCE_ALPHA, type: gl.UNSIGNED_BYTE,          size: 2, dataType: Uint8Array  },
-  { format: gl.RGB,             type: gl.UNSIGNED_BYTE,          size: 3, dataType: Uint8Array  },
-  { format: gl.RGB,             type: gl.UNSIGNED_SHORT_5_6_5,   size: 1, dataType: Uint16Array },
-  { format: gl.RGBA,            type: gl.UNSIGNED_BYTE,          size: 4, dataType: Uint8Array  },
-  { format: gl.RGBA,            type: gl.UNSIGNED_SHORT_4_4_4_4, size: 1, dataType: Uint16Array },
-  { format: gl.RGBA,            type: gl.UNSIGNED_SHORT_5_5_5_1, size: 1, dataType: Uint16Array }
-];
-
-// Note: We expressly only use 2 textures because first a texture will be defined
-// as using all mips of 1 format, then for a moment it will have mixed formats which
-// may uncover bugs.
-var targets = [
-  { target: gl.TEXTURE_2D,
-    maxSize: gl.getParameter(gl.MAX_TEXTURE_SIZE),
-    maxLevel: 1000,
-    tex: gl.createTexture(),
-    targets: [gl.TEXTURE_2D]
-  },
-  { target: gl.TEXTURE_CUBE_MAP,
-    maxSize: gl.getParameter(gl.MAX_CUBE_MAP_TEXTURE_SIZE),
-    maxLevel: 5,
-    tex: gl.createTexture(),
-    targets: [
-      gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-      gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-      gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-      gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-      gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-      gl.TEXTURE_CUBE_MAP_NEGATIVE_Z
-    ]
-  }
-];
-
-gl.pixelStorei(gl.UNPACK_ALIGNMENT, 1);
-
-var trg = 0;
-var tt = 0;
-runNextTest();
-
-function runNextTest() {
-  var t = targets[trg];
-
-  if (tt == 0) {
-    var tex = t.tex;
-    gl.bindTexture(t.target, tex);
-
-    debug("");
-    debug("max size for " + wtu.glEnumToString(gl, t.target) + ": " + t.maxSize);
-    var numLevels = numLevelsFromSize(t.maxSize);
-    debug("num levels " + numLevels);
-  }
-
-  var test = tests[tt];
-  testFormatType(t, test);
-  ++tt;
-  if (tt == tests.length) {
-    tt = 0;
-    ++trg;
-    if (trg == targets.length) {
-      finishTest();
-      return;
-    }
-  }
-  wtu.waitForComposite(gl, runNextTest)
-}
-
-function testFormatType(t, test) {
-  debug("");
-  debug("testing: " + wtu.glEnumToString(gl, test.format) + ", " + wtu.glEnumToString(gl, test.type));
-  for (var j = 0; j < t.targets.length; ++j) {
-    var target = t.targets[j];
-    debug("");
-    debug(wtu.glEnumToString(gl, target));
-    var numLevels = numLevelsFromSize(t.maxSize);
-    var numTestLevels = Math.min(numLevels, t.maxLevel);
-    for (var l = 0; l < numTestLevels; ++l) {
-      // Do bottom levels first;
-      var size = 1 << l;
-      var level = numLevels - l - 1;
-      var otherDimension = t.target == gl.TEXTURE_2D ? 1 : size;
-      var badSize = size * 2;
-      var badOtherDimension = t.target == gl.TEXTURE_2D ? 1 : badSize;
-      var pixels = new test.dataType(badSize * badOtherDimension * test.size);
-      gl.texImage2D(target, level, test.format, size, otherDimension, 0, test.format, test.type, pixels);
-      glErrorShouldBe(gl, gl.NO_ERROR, "there should be no error for level: " + level + " " + size + "x" + otherDimension);
-      gl.texImage2D(target, level, test.format, otherDimension, size, 0, test.format, test.type, pixels);
-      glErrorShouldBe(gl, gl.NO_ERROR, "there should be no error for level: " + level + " " + otherDimension + "x" + size);
-      gl.texImage2D(target, level, test.format, badSize, badOtherDimension, 0, test.format, test.type, pixels);
-      glErrorShouldBe(gl, gl.INVALID_VALUE, "should generate INVALID_VALUE for level: " + level + " " + badSize + "x" + badOtherDimension);
-      gl.texImage2D(target, level, test.format, badOtherDimension, badSize, 0, test.format, test.type, pixels);
-      glErrorShouldBe(gl, gl.INVALID_VALUE, "should generate INVALID_VALUE for level: " + level + " " + badOtherDimension + "x" + badSize);
-    }
-  }
-}
-
-var successfullyParsed = true;
-</script>
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size.html
deleted file mode 100644
index 0e67ed7..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-size.html
+++ /dev/null
@@ -1,238 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL texture size conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="32" height="32" style="width: 40px; height: 40px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-attribute vec4 vPosition;
-attribute vec3 texCoord0;
-varying vec3 texCoord;
-void main()
-{
-    gl_Position = vPosition;
-    texCoord = texCoord0;
-}
-</script>
-
-<script id="fshader" type="x-shader/x-fragment">
-precision mediump float;
-uniform samplerCube tex;
-varying vec3 texCoord;
-void main()
-{
-    gl_FragColor = textureCube(tex, normalize(texCoord));
-}
-</script>
-<script>
-"use strict";
-description("Checks that various sizes of textures render")
-var canvas;
-
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext("example");
-var program2D = wtu.setupTexturedQuad(gl);
-var programCubeMap = wtu.setupProgram(
-    gl, ['vshader', 'fshader'], ['vPosition', 'texCoord0'], [0, 1]);
-gl.disable(gl.DEPTH_TEST);
-gl.disable(gl.BLEND);
-var tex = gl.createTexture();
-var max2DSize = gl.getParameter(gl.MAX_TEXTURE_SIZE);
-var maxCubeMapSize = gl.getParameter(gl.MAX_CUBE_MAP_TEXTURE_SIZE);
-debug("MAX_TEXTURE_SIZE:" + max2DSize);
-debug("MAX_CUBE_MAP_TEXTURE_SIZE:" + maxCubeMapSize);
-// Assuming 2048x2048xRGBA (22meg with mips) will run on all WebGL platforms
-var max2DSquareSize = Math.min(max2DSize, 2048);
-// I'd prefer this to be 2048 but that's 16meg x 6 faces or 128meg (with mips)
-// 1024 is 33.5 meg (with mips)
-var maxCubeMapSize = Math.min(maxCubeMapSize, 1024);
-
-var colors = [
-  { name: "green", rgba: [0, 0, 255, 255] },
-  { name: "red", rgba: [255, 0, 0, 255] },
-  { name: "blue", rgba: [0, 255, 0, 255] },
-  { name: "yellow", rgba: [255, 255, 0, 255] },
-  { name: "magenta", rgba: [255, 0, 255, 255] },
-  { name: "cyan", rgba: [0, 255, 255, 255] }
-];
-
-var count = 0;
-var power = 0;
-runTest();
-
-function runTest() {
-  function doTest() {
-    var size = Math.pow(2, power);
-    if (size > max2DSize) {
-      return false;
-    }
-    gl.useProgram(program2D);
-    if (!checkTexture(size, 1, false)) return false;
-    if (!checkTexture(1, size, false)) return false;
-    if (size <= max2DSquareSize) {
-      if (!checkTexture(size, size, false)) {
-        return false;
-      }
-    }
-    if (size <= maxCubeMapSize) {
-      gl.useProgram(programCubeMap);
-      if (!checkTexture(size, size, true)) {
-        return false;
-      }
-    }
-    return true;
-  }
-
-  if (doTest()) {
-    ++power;
-    setTimeout(runTest, 0);
-  } else {
-    finishTest();
-  }
-}
-
-function checkTexture(width, height, cubeMap) {
-  debug("");
-  count = (count + 1) % colors.length;
-  var color = colors[count];
-  var tex = gl.createTexture();
-  var target = cubeMap ? gl.TEXTURE_CUBE_MAP : gl.TEXTURE_2D;
-  var type = cubeMap ? "cube map" : "2D texture";
-  debug("check " + width + ", " + height + " " + type);
-  gl.bindTexture(target, tex);
-  gl.texParameteri(target, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-  gl.texParameteri(target, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-  gl.texParameteri(target, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-  fillLevel(0, width, height, color.rgba, cubeMap);
-  var err = gl.getError();
-  if (err == gl.OUT_OF_MEMORY) {
-    debug("out of memory");
-    return false;
-  }
-  if (err != gl.NO_ERROR) {
-    testFailed("unexpected gl error: " + wtu.glEnumToString(gl, err));
-  }
-  wtu.clearAndDrawUnitQuad(gl);
-  wtu.checkCanvas(gl, color.rgba,
-      type + " of size " + width + "x" + height + " with no mips should draw with " + color.name);
-  count = (count + 1) % colors.length;
-  color = colors[count];
-  fillLevel(0, width, height, color.rgba, cubeMap);
-  gl.generateMipmap(target);
-  var err = gl.getError();
-  if (err == gl.OUT_OF_MEMORY) {
-    debug("out of memory");
-    return false;
-  }
-  if (err != gl.NO_ERROR) {
-    testFailed("unexpected gl error: " + wtu.glEnumToString(gl, err));
-  }
-  gl.texParameteri(target, gl.TEXTURE_MIN_FILTER, gl.LINEAR_MIPMAP_NEAREST);
-  wtu.clearAndDrawUnitQuad(gl);
-  wtu.checkCanvas(gl, color.rgba,
-      type + " of size " + width + "x" + height + " with mips should draw with " + color.name);
-
-  count = (count + 1) % colors.length;
-  color = colors[count];
-  fillLevel(0, width, height, color.rgba, cubeMap, true);
-  gl.generateMipmap(target);
-
-  wtu.clearAndDrawUnitQuad(gl);
-  wtu.checkCanvas(gl, color.rgba,
-      type + " of size " + width + "x" + height + " with mips should draw with " + color.name);
-
-  gl.deleteTexture(tex);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors.");
-  return true;
-}
-
-function fillLevel(level, width, height, color, opt_cubemap, opt_subTex) {
-  var numPixels = width * height;
-  var pixels = null;
-  var largeDim = Math.max(width, height);
-  var smallDim = Math.min(width, height);
-
-  var pixelRow = new Uint8Array(largeDim * 4);
-  for (var jj = 0; jj < largeDim; ++jj) {
-    var off = jj * 4;
-    pixelRow[off + 0] = color[0];
-    pixelRow[off + 1] = color[1];
-    pixelRow[off + 2] = color[2];
-    pixelRow[off + 3] = color[3];
-  }
-
-  if (largeDim == numPixels) {
-    pixels = pixelRow;
-  } else {
-    var pixels = new Uint8Array(numPixels * 4);
-    for (var jj = 0; jj < smallDim; ++jj) {
-      var off = jj * largeDim * 4;
-      pixels.set(pixelRow, off);
-    }
-  }
- 
-  var targets = opt_cubemap ? [
-    gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-    gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-    gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-    gl.TEXTURE_CUBE_MAP_NEGATIVE_Z] :
-    [gl.TEXTURE_2D];
-
-  for (var ii = 0; ii < targets.length; ++ii) {
-    // debug(wtu.glEnumToString(gl, targets[ii]));
-    var index = (ii + power) % targets.length;
-    var target = targets[index];
-    if (opt_subTex) {
-      gl.texSubImage2D(
-          target, level, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE,
-          pixels);
-    } else {
-      gl.texImage2D(
-          target, level, gl.RGBA, width, height, 0, gl.RGBA, gl.UNSIGNED_BYTE,
-          pixels);
-    }
-  }
-}
-
-var successfullyParsed = true;
-</script>
-</body>
-</html>
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-sub-image-cube-maps.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-sub-image-cube-maps.html
deleted file mode 100644
index 584e03a..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-sub-image-cube-maps.html
+++ /dev/null
@@ -1,337 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL texture texSubImage2Ds cube map conformance test.</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"> </script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="256" height="256" style="width: 40px; height: 40px;"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script id="vshader" type="x-shader/x-vertex">
-attribute vec4 vPosition;
-uniform mat4 rotation;
-varying vec3 texCoord;
-void main()
-{
-    gl_Position = vPosition;
-    vec4 direction = vec4(vPosition.x * 0.5, vPosition.y * 0.5, 1, 1);
-    texCoord = normalize((rotation * direction).xyz);
-}
-</script>
-
-<script id="fshader" type="x-shader/x-fragment">
-precision mediump float;
-uniform samplerCube tex;
-varying vec3 texCoord;
-void main()
-{
-    gl_FragColor = textureCube(tex, normalize(texCoord));
-}
-</script>
-<script>
-"use strict";
-var canvas;
-description("Checks issues with size of cube map textures");
-debug("");
-
-var wtu = WebGLTestUtils;
-var canvas = document.getElementById("example");
-
-var gl = wtu.create3DContext(canvas);
-wtu.setupUnitQuad(gl, 0, 1);
-var program = wtu.setupProgram(
-    gl,
-    ['vshader', 'fshader'],
-    ['vPosition', 'texCoord0'], [0, 1]);
-var rotLoc = gl.getUniformLocation(program, "rotation");
-
-var size = 16;
-
-var colors = [
-  {name: 'red',     color: [255,   0,   0, 255]},
-  {name: 'green',   color: [  0, 255,   0, 255]},
-  {name: 'blue',    color: [  0,   0, 255, 255]},
-  {name: 'yellow',  color: [255, 255,   0, 255]},
-  {name: 'cyan',    color: [  0, 255, 255, 255]},
-  {name: 'magenta', color: [255,   0, 255, 255]}
-];
-
-var targets = [
-  gl.TEXTURE_CUBE_MAP_POSITIVE_X,
-  gl.TEXTURE_CUBE_MAP_NEGATIVE_X,
-  gl.TEXTURE_CUBE_MAP_POSITIVE_Y,
-  gl.TEXTURE_CUBE_MAP_NEGATIVE_Y,
-  gl.TEXTURE_CUBE_MAP_POSITIVE_Z,
-  gl.TEXTURE_CUBE_MAP_NEGATIVE_Z];
-
-var rotations = [
-  {axis: [0, 1, 0], angle:  Math.PI / 2},
-  {axis: [0, 1, 0], angle: -Math.PI / 2},
-  {axis: [1, 0, 0], angle: -Math.PI / 2},
-  {axis: [1, 0, 0], angle:  Math.PI / 2},
-  {axis: [0, 1, 0], angle:  0},
-  {axis: [0, 1, 0], angle:  Math.PI},
-];
-
-var halfRotations = [
-  {colors: [3, 4], rotations: [{axis: [1, 0, 0], angle:  Math.PI / 4}]},
-  {colors: [4, 2], rotations: [{axis: [1, 0, 0], angle: -Math.PI / 4}]},
-  {colors: [5, 3], rotations: [{axis: [1, 0, 0], angle:  Math.PI / 4 * 3}]},
-  {colors: [2, 5], rotations: [{axis: [1, 0, 0], angle: -Math.PI / 4 * 3}]},
-  {colors: [3, 0], rotations: [{axis: [0, 1, 0], angle:  Math.PI / 2},
-                               {axis: [1, 0, 0], angle:  Math.PI / 4}]},
-  {colors: [0, 2], rotations: [{axis: [0, 1, 0], angle:  Math.PI / 2},
-                               {axis: [1, 0, 0], angle: -Math.PI / 4}]},
-];
-
-var count = 0;
-testSize(size);
-
-function testSize(size) {
-  debug("");
-  debug("testing size: " + size);
-  var canvasSize = Math.max(size / 4, 2);
-  canvas.width = canvasSize;
-  canvas.height = canvasSize;
-  gl.viewport(0, 0, canvasSize, canvasSize);
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_CUBE_MAP, tex);
-
-  // Seems like I should be using LINEAR here with some other math
-  // to make sure I get more mip coverage but that's easier said
-  // than done.
-
-  gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-  gl.texParameteri(gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-
-  for (var jj = 0; jj < 2; ++jj) {
-    for (var tt = 0; tt < targets.length; ++tt) {
-      var color = colors[(tt + count) % colors.length];
-      fillLevel(targets[tt], 0, size, color.color);
-    }
-    if (jj == 1) {
-      debug("use mipmap");
-      gl.texParameteri(
-          gl.TEXTURE_CUBE_MAP, gl.TEXTURE_MIN_FILTER,
-          gl.NEAREST_MIPMAP_NEAREST);
-      gl.generateMipmap(gl.TEXTURE_CUBE_MAP);
-    }
-
-    var err = gl.getError();
-    if (err == gl.OUT_OF_MEMORY) {
-      debug("out of memory");
-      return false;
-    }
-    if (err != gl.NO_ERROR) {
-      testFailed("unexpected gl error: " + wtu.glEnumToString(gl, err));
-    }
-
-
-    for (var rr = 0; rr < rotations.length; ++rr) {
-      var rot = rotations[rr];
-      var color = colors[(rr + count) % colors.length];
-      var rotMat = axisRotation(rot.axis, rot.angle);
-      gl.uniformMatrix4fv(rotLoc, false, rotMat);
-      wtu.clearAndDrawUnitQuad(gl);
-      wtu.checkCanvas(
-          gl, color.color,
-          wtu.glEnumToString(gl, targets[rr]) + " should be " + color.name);
-    }
-
-    for (var rr = 0; rr < halfRotations.length; ++rr) {
-      var h = halfRotations[rr];
-      var rots = h.rotations;
-      var rotMat = axisRotation(rots[0].axis, rots[0].angle);
-      for (var ii = 1; ii < rots.length; ++ii) {
-        var tmpMat = axisRotation(rots[ii].axis, rots[ii].angle);
-        var rotMat = mulMatrix(tmpMat, rotMat);
-      }
-      gl.uniformMatrix4fv(rotLoc, false, rotMat);
-      wtu.clearAndDrawUnitQuad(gl);
-
-      for (var ii = 0; ii < 2; ++ii) {
-        checkRect(
-            0,
-            canvasSize / 2 * ii,
-            canvasSize,
-            canvasSize / 2,
-            colors[(h.colors[ii] + count) % colors.length]);
-      }
-    }
-    ++count;
-  }
-
-  gl.deleteTexture(tex);
-  return true;
-}
-
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors.");
-
-function checkRect(x, y, width, height, color) {
-  wtu.checkCanvasRect(
-       gl,
-       x,
-       y,
-       width,
-       height,
-       color.color,
-       "" + x + ", " + y + ", " + width + ", " + height +
-       " should be " + color.name);
-}
-
-function fillLevel(target, level, size, color) {
-  var numPixels = size * size;
-  var halfPixelRow = new Uint8Array(size * 2);
-  for (var jj = 0; jj < size; ++jj) {
-    var off = jj * 4;
-    halfPixelRow[off + 0] = color[0];
-    halfPixelRow[off + 1] = color[1];
-    halfPixelRow[off + 2] = color[2];
-    halfPixelRow[off + 3] = color[3];
-  }
-  gl.texImage2D(
-      target, level, gl.RGBA, size, size, 0, gl.RGBA, gl.UNSIGNED_BYTE,
-      null);
-  for (var jj = 0; jj < size; ++jj) {
-      gl.texSubImage2D(
-          target, level, 0, jj, size / 2, 1, gl.RGBA, gl.UNSIGNED_BYTE, halfPixelRow);
-      gl.texSubImage2D(
-          target, level, size / 2, jj, size / 2, 1, gl.RGBA, gl.UNSIGNED_BYTE, halfPixelRow);
-  }
-}
-
-function printMat(mat) {
-  debug("" + mat[0] + ", " + mat[1] + ", " + mat[2] + ", " + mat[3] + ", ");
-  debug("" + mat[4] + ", " + mat[5] + ", " + mat[6] + ", " + mat[7] + ", ");
-  debug("" + mat[8] + ", " + mat[9] + ", " + mat[10] + ", " + mat[11] + ", ");
-  debug("" + mat[12] + ", " + mat[13] + ", " + mat[14] + ", " + mat[15] + ", ");
-}
-
-function axisRotation(axis, angle) {
-  var dst = new Float32Array(16);
-  var x = axis[0];
-  var y = axis[1];
-  var z = axis[2];
-  var n = Math.sqrt(x * x + y * y + z * z);
-  x /= n;
-  y /= n;
-  z /= n;
-  var xx = x * x;
-  var yy = y * y;
-  var zz = z * z;
-  var c = Math.cos(angle);
-  var s = Math.sin(angle);
-  var oneMinusCosine = 1 - c;
-
-  dst[ 0] = xx + (1 - xx) * c;
-  dst[ 1] = x * y * oneMinusCosine + z * s;
-  dst[ 2] = x * z * oneMinusCosine - y * s;
-  dst[ 3] = 0;
-  dst[ 4] = x * y * oneMinusCosine - z * s;
-  dst[ 5] = yy + (1 - yy) * c;
-  dst[ 6] = y * z * oneMinusCosine + x * s;
-  dst[ 7] = 0;
-  dst[ 8] = x * z * oneMinusCosine + y * s;
-  dst[ 9] = y * z * oneMinusCosine - x * s;
-  dst[10] = zz + (1 - zz) * c;
-  dst[11] = 0;
-  dst[12] = 0;
-  dst[13] = 0;
-  dst[14] = 0;
-  dst[15] = 1;
-
-  return dst;
-};
-
-function mulMatrix(a, b) {
-  var dst = new Float32Array(16);
-  var a00 = a[0];
-  var a01 = a[1];
-  var a02 = a[2];
-  var a03 = a[3];
-  var a10 = a[ 4 + 0];
-  var a11 = a[ 4 + 1];
-  var a12 = a[ 4 + 2];
-  var a13 = a[ 4 + 3];
-  var a20 = a[ 8 + 0];
-  var a21 = a[ 8 + 1];
-  var a22 = a[ 8 + 2];
-  var a23 = a[ 8 + 3];
-  var a30 = a[12 + 0];
-  var a31 = a[12 + 1];
-  var a32 = a[12 + 2];
-  var a33 = a[12 + 3];
-  var b00 = b[0];
-  var b01 = b[1];
-  var b02 = b[2];
-  var b03 = b[3];
-  var b10 = b[ 4 + 0];
-  var b11 = b[ 4 + 1];
-  var b12 = b[ 4 + 2];
-  var b13 = b[ 4 + 3];
-  var b20 = b[ 8 + 0];
-  var b21 = b[ 8 + 1];
-  var b22 = b[ 8 + 2];
-  var b23 = b[ 8 + 3];
-  var b30 = b[12 + 0];
-  var b31 = b[12 + 1];
-  var b32 = b[12 + 2];
-  var b33 = b[12 + 3];
-  dst[ 0] = a00 * b00 + a01 * b10 + a02 * b20 + a03 * b30;
-  dst[ 1] = a00 * b01 + a01 * b11 + a02 * b21 + a03 * b31;
-  dst[ 2] = a00 * b02 + a01 * b12 + a02 * b22 + a03 * b32;
-  dst[ 3] = a00 * b03 + a01 * b13 + a02 * b23 + a03 * b33;
-  dst[ 4] = a10 * b00 + a11 * b10 + a12 * b20 + a13 * b30;
-  dst[ 5] = a10 * b01 + a11 * b11 + a12 * b21 + a13 * b31;
-  dst[ 6] = a10 * b02 + a11 * b12 + a12 * b22 + a13 * b32;
-  dst[ 7] = a10 * b03 + a11 * b13 + a12 * b23 + a13 * b33;
-  dst[ 8] = a20 * b00 + a21 * b10 + a22 * b20 + a23 * b30;
-  dst[ 9] = a20 * b01 + a21 * b11 + a22 * b21 + a23 * b31;
-  dst[10] = a20 * b02 + a21 * b12 + a22 * b22 + a23 * b32;
-  dst[11] = a20 * b03 + a21 * b13 + a22 * b23 + a23 * b33;
-  dst[12] = a30 * b00 + a31 * b10 + a32 * b20 + a33 * b30;
-  dst[13] = a30 * b01 + a31 * b11 + a32 * b21 + a33 * b31;
-  dst[14] = a30 * b02 + a31 * b12 + a32 * b22 + a33 * b32;
-  dst[15] = a30 * b03 + a31 * b13 + a32 * b23 + a33 * b33;
-  return dst;
-};
-
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
-
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-transparent-pixels-initialized.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-transparent-pixels-initialized.html
deleted file mode 100644
index 4232157..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-transparent-pixels-initialized.html
+++ /dev/null
@@ -1,109 +0,0 @@
-<!--
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
--->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-<script>
-"use strict";
-var wtu = WebGLTestUtils;
-var gl = null;
-var texture;
-var textureLoc = null;
-var successfullyParsed = false;
-
-function init()
-{
-    initTestingHarnessWaitUntilDone();
-
-    description('Tests there is no garbage in transparent regions of images uploaded as textures');
-
-    wtu = WebGLTestUtils;
-    gl = wtu.create3DContext("example");
-    var program = wtu.setupTexturedQuad(gl);
-    gl.clearColor(0.5,0.5,0.5,1);
-    gl.clearDepth(1);
-
-    textureLoc = gl.getUniformLocation(program, "tex");
-
-    // The input texture has 8 characters; take the leftmost one
-    var coeff = 1.0 / 8.0;
-    var texCoords = new Float32Array([
-        coeff, 1.0,
-        0.0, 1.0,
-        0.0, 0.0,
-        coeff, 1.0,
-        0.0, 0.0,
-        coeff, 0.0]);
-
-    var vbo = gl.createBuffer();
-    gl.bindBuffer(gl.ARRAY_BUFFER, vbo);
-    gl.bufferData(gl.ARRAY_BUFFER, texCoords, gl.STATIC_DRAW);
-    gl.enableVertexAttribArray(1);
-    gl.vertexAttribPointer(1, 2, gl.FLOAT, false, 0, 0);
-
-    texture = wtu.loadTexture(gl, "../resources/bug-32888-texture.png", runTest);
-}
-
-// These two declarations need to be global for "shouldBe" to see them
-var buf = null;
-var idx = 0;
-
-function runTest()
-{
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    gl.enable(gl.BLEND);
-    gl.blendFunc(gl.SRC_ALPHA, gl.ONE_MINUS_SRC_ALPHA);
-    // Bind the texture to texture unit 0
-    gl.bindTexture(gl.TEXTURE_2D, texture);
-    // Point the uniform sampler to texture unit 0
-    gl.uniform1i(textureLoc, 0);
-    // Draw the triangles
-    wtu.clearAndDrawUnitQuad(gl, [0, 0, 0, 255]);
-
-    // Spot check a couple of 2x2 regions in the upper and lower left
-    // corners; they should be the rgb values in the texture.
-    var color = [0, 0, 0];
-    debug("Checking lower left corner");
-    wtu.checkCanvasRect(gl, 1, gl.canvas.height - 3, 2, 2, color,
-                        "shouldBe " + color);
-    debug("Checking upper left corner");
-    wtu.checkCanvasRect(gl, 1, 1, 2, 2, color,
-                        "shouldBe " + color);
-
-    finishTest();
-}
-</script>
-</head>
-<body onload="init()">
-<canvas id="example" width="32" height="32"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-upload-cube-maps.html b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-upload-cube-maps.html
deleted file mode 100644
index bdb654c..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/textures/texture-upload-cube-maps.html
+++ /dev/null
@@ -1,74 +0,0 @@
-<!--
-
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
--->
-
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<script src="../../resources/js-test-pre.js"></script>
-<script src="../resources/webgl-test.js"></script>
-<script src="../resources/webgl-test-utils.js"></script>
-</head>
-<body>
-<canvas id="example" width="2" height="2"></canvas>
-<div id="description"></div>
-<div id="console"></div>
-<script>
-"use strict";
-description('Tests texImage2D and texSubImage2D upload path for TEXTURE_CUBE_MAP');
-
-var wtu = WebGLTestUtils;
-var canvas = document.getElementById("example");
-var gl = wtu.create3DContext(canvas);
-glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from setup.");
-
-function testOneTarget(target, width, height) {
-  var tex = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_CUBE_MAP, tex);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from bindTexture(TEXTURE_CUBE_MAP).");
-
-  gl.texImage2D(target, 0, gl.RGB, width, height, 0, gl.RGB, gl.UNSIGNED_BYTE, null);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from texImage2D.");
-
-  var buf = new Uint8Array(width * height * 3);
-  gl.texSubImage2D(target, 0, 0, 0, width, height, gl.RGB, gl.UNSIGNED_BYTE, buf);
-  glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors from texSubImage2D.");
-}
-
-testOneTarget(gl.TEXTURE_CUBE_MAP_POSITIVE_X, 16, 16);
-testOneTarget(gl.TEXTURE_CUBE_MAP_POSITIVE_Y, 16, 16);
-testOneTarget(gl.TEXTURE_CUBE_MAP_POSITIVE_Z, 16, 16);
-testOneTarget(gl.TEXTURE_CUBE_MAP_NEGATIVE_X, 16, 16);
-testOneTarget(gl.TEXTURE_CUBE_MAP_NEGATIVE_Y, 16, 16);
-testOneTarget(gl.TEXTURE_CUBE_MAP_NEGATIVE_Z, 16, 16);
-
-var successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/desktop-gl-constants.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/desktop-gl-constants.js
deleted file mode 100644
index 6bea0ac..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/desktop-gl-constants.js
+++ /dev/null
@@ -1,2645 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
-// Defines a bunch of DesktopGL constants so we can make sure WebGL
-// implementations disallow them.
-
-var desktopGL = {
-  'MIN': 0x8007,
-  'MAX': 0x8008,
-  'QUADS': 0x0007,
-  'QUAD_STRIP': 0x0008,
-  'POLYGON': 0x0009,
-  '1': 0x0001,
-  '2': 0x0002,
-  '3': 0x0003,
-  '4': 0x0004,
-  'STATIC_READ': 0x88E5,
-  'CLIP_PLANE0': 0x3000,
-  'PERSPECTIVE_CORRECTION_HINT': 0x0C50,
-  'ACCUM_BUFFER_BIT': 0x0200,
-  'RGB4': 0x804F,
-  'RGB5': 0x8050,
-  'RGB8': 0x8051,
-  'RGB10': 0x8052,
-  'RGB12': 0x8053,
-  'RGB16': 0x8054,
-  'RGBA2': 0x8055,
-  'RGBA4': 0x8056,
-  'RGB5_A1': 0x8057,
-  'RGBA8': 0x8058,
-  'RGB10_A2': 0x8059,
-  'RGBA12': 0x805A,
-  'RGBA16': 0x805B,
-  'SMOOTH_POINT_SIZE_RANGE': 0x0B12,
-  'SMOOTH_POINT_SIZE_GRANULARITY': 0x0B13,
-  'SMOOTH_LINE_WIDTH_RANGE': 0x0B22,
-  'SMOOTH_LINE_WIDTH_GRANULARITY': 0x0B23,
-  'UNSIGNED_BYTE_3_3_2': 0x8032,
-  'UNSIGNED_SHORT_4_4_4_4': 0x8033,
-  'UNSIGNED_SHORT_5_5_5_1': 0x8034,
-  'UNSIGNED_INT_8_8_8_8': 0x8035,
-  'UNSIGNED_INT_10_10_10_2': 0x8036,
-  'RESCALE_NORMAL': 0x803A,
-  'TEXTURE_BINDING_3D': 0x806A,
-  'PACK_SKIP_IMAGES': 0x806B,
-  'PACK_IMAGE_HEIGHT': 0x806C,
-  'UNPACK_SKIP_IMAGES': 0x806D,
-  'UNPACK_IMAGE_HEIGHT': 0x806E,
-  'TEXTURE_3D': 0x806F,
-  'PROXY_TEXTURE_3D': 0x8070,
-  'TEXTURE_DEPTH': 0x8071,
-  'TEXTURE_WRAP_R': 0x8072,
-  'MAX_3D_TEXTURE_SIZE': 0x8073,
-  'BGR': 0x80E0,
-  'BGRA': 0x80E1,
-  'MAX_ELEMENTS_VERTICES': 0x80E8,
-  'MAX_ELEMENTS_INDICES': 0x80E9,
-  'CLAMP_TO_EDGE': 0x812F,
-  'TEXTURE_MIN_LOD': 0x813A,
-  'TEXTURE_MAX_LOD': 0x813B,
-  'TEXTURE_BASE_LEVEL': 0x813C,
-  'TEXTURE_MAX_LEVEL': 0x813D,
-  'LIGHT_MODEL_COLOR_CONTROL': 0x81F8,
-  'SINGLE_COLOR': 0x81F9,
-  'SEPARATE_SPECULAR_COLOR': 0x81FA,
-  'UNSIGNED_BYTE_2_3_3_REV': 0x8362,
-  'UNSIGNED_SHORT_5_6_5': 0x8363,
-  'UNSIGNED_SHORT_5_6_5_REV': 0x8364,
-  'UNSIGNED_SHORT_4_4_4_4_REV': 0x8365,
-  'UNSIGNED_SHORT_1_5_5_5_REV': 0x8366,
-  'UNSIGNED_INT_8_8_8_8_REV': 0x8367,
-  'UNSIGNED_INT_2_10_10_10_REV': 0x8368,
-  'ALIASED_POINT_SIZE_RANGE': 0x846D,
-  'ALIASED_LINE_WIDTH_RANGE': 0x846E,
-  'MULTISAMPLE': 0x809D,
-  'SAMPLE_ALPHA_TO_COVERAGE': 0x809E,
-  'SAMPLE_ALPHA_TO_ONE': 0x809F,
-  'SAMPLE_COVERAGE': 0x80A0,
-  'SAMPLE_BUFFERS': 0x80A8,
-  'SAMPLES': 0x80A9,
-  'SAMPLE_COVERAGE_VALUE': 0x80AA,
-  'SAMPLE_COVERAGE_INVERT': 0x80AB,
-  'CLAMP_TO_BORDER': 0x812D,
-  'TEXTURE0': 0x84C0,
-  'TEXTURE1': 0x84C1,
-  'TEXTURE2': 0x84C2,
-  'TEXTURE3': 0x84C3,
-  'TEXTURE4': 0x84C4,
-  'TEXTURE5': 0x84C5,
-  'TEXTURE6': 0x84C6,
-  'TEXTURE7': 0x84C7,
-  'TEXTURE8': 0x84C8,
-  'TEXTURE9': 0x84C9,
-  'TEXTURE10': 0x84CA,
-  'TEXTURE11': 0x84CB,
-  'TEXTURE12': 0x84CC,
-  'TEXTURE13': 0x84CD,
-  'TEXTURE14': 0x84CE,
-  'TEXTURE15': 0x84CF,
-  'TEXTURE16': 0x84D0,
-  'TEXTURE17': 0x84D1,
-  'TEXTURE18': 0x84D2,
-  'TEXTURE19': 0x84D3,
-  'TEXTURE20': 0x84D4,
-  'TEXTURE21': 0x84D5,
-  'TEXTURE22': 0x84D6,
-  'TEXTURE23': 0x84D7,
-  'TEXTURE24': 0x84D8,
-  'TEXTURE25': 0x84D9,
-  'TEXTURE26': 0x84DA,
-  'TEXTURE27': 0x84DB,
-  'TEXTURE28': 0x84DC,
-  'TEXTURE29': 0x84DD,
-  'TEXTURE30': 0x84DE,
-  'TEXTURE31': 0x84DF,
-  'ACTIVE_TEXTURE': 0x84E0,
-  'CLIENT_ACTIVE_TEXTURE': 0x84E1,
-  'MAX_TEXTURE_UNITS': 0x84E2,
-  'TRANSPOSE_MODELVIEW_MATRIX': 0x84E3,
-  'TRANSPOSE_PROJECTION_MATRIX': 0x84E4,
-  'TRANSPOSE_TEXTURE_MATRIX': 0x84E5,
-  'TRANSPOSE_COLOR_MATRIX': 0x84E6,
-  'SUBTRACT': 0x84E7,
-  'COMPRESSED_ALPHA': 0x84E9,
-  'COMPRESSED_LUMINANCE': 0x84EA,
-  'COMPRESSED_LUMINANCE_ALPHA': 0x84EB,
-  'COMPRESSED_INTENSITY': 0x84EC,
-  'COMPRESSED_RGB': 0x84ED,
-  'COMPRESSED_RGBA': 0x84EE,
-  'TEXTURE_COMPRESSION_HINT': 0x84EF,
-  'NORMAL_MAP': 0x8511,
-  'REFLECTION_MAP': 0x8512,
-  'TEXTURE_CUBE_MAP': 0x8513,
-  'TEXTURE_BINDING_CUBE_MAP': 0x8514,
-  'TEXTURE_CUBE_MAP_POSITIVE_X': 0x8515,
-  'TEXTURE_CUBE_MAP_NEGATIVE_X': 0x8516,
-  'TEXTURE_CUBE_MAP_POSITIVE_Y': 0x8517,
-  'TEXTURE_CUBE_MAP_NEGATIVE_Y': 0x8518,
-  'TEXTURE_CUBE_MAP_POSITIVE_Z': 0x8519,
-  'TEXTURE_CUBE_MAP_NEGATIVE_Z': 0x851A,
-  'PROXY_TEXTURE_CUBE_MAP': 0x851B,
-  'MAX_CUBE_MAP_TEXTURE_SIZE': 0x851C,
-  'COMBINE': 0x8570,
-  'COMBINE_RGB': 0x8571,
-  'COMBINE_ALPHA': 0x8572,
-  'RGB_SCALE': 0x8573,
-  'ADD_SIGNED': 0x8574,
-  'INTERPOLATE': 0x8575,
-  'CONSTANT': 0x8576,
-  'PRIMARY_COLOR': 0x8577,
-  'PREVIOUS': 0x8578,
-  'SOURCE0_RGB': 0x8580,
-  'SOURCE1_RGB': 0x8581,
-  'SOURCE2_RGB': 0x8582,
-  'SOURCE0_ALPHA': 0x8588,
-  'SOURCE1_ALPHA': 0x8589,
-  'SOURCE2_ALPHA': 0x858A,
-  'OPERAND0_RGB': 0x8590,
-  'OPERAND1_RGB': 0x8591,
-  'OPERAND2_RGB': 0x8592,
-  'OPERAND0_ALPHA': 0x8598,
-  'OPERAND1_ALPHA': 0x8599,
-  'OPERAND2_ALPHA': 0x859A,
-  'TEXTURE_COMPRESSED_IMAGE_SIZE': 0x86A0,
-  'TEXTURE_COMPRESSED': 0x86A1,
-  'NUM_COMPRESSED_TEXTURE_FORMATS': 0x86A2,
-  'COMPRESSED_TEXTURE_FORMATS': 0x86A3,
-  'DOT3_RGB': 0x86AE,
-  'DOT3_RGBA': 0x86AF,
-  'MULTISAMPLE_BIT': 0x20000000,
-  'BLEND_DST_RGB': 0x80C8,
-  'BLEND_SRC_RGB': 0x80C9,
-  'BLEND_DST_ALPHA': 0x80CA,
-  'BLEND_SRC_ALPHA': 0x80CB,
-  'POINT_SIZE_MIN': 0x8126,
-  'POINT_SIZE_MAX': 0x8127,
-  'POINT_FADE_THRESHOLD_SIZE': 0x8128,
-  'POINT_DISTANCE_ATTENUATION': 0x8129,
-  'GENERATE_MIPMAP': 0x8191,
-  'GENERATE_MIPMAP_HINT': 0x8192,
-  'DEPTH_COMPONENT16': 0x81A5,
-  'DEPTH_COMPONENT24': 0x81A6,
-  'DEPTH_COMPONENT32': 0x81A7,
-  'MIRRORED_REPEAT': 0x8370,
-  'FOG_COORDINATE_SOURCE': 0x8450,
-  'FOG_COORDINATE': 0x8451,
-  'FRAGMENT_DEPTH': 0x8452,
-  'CURRENT_FOG_COORDINATE': 0x8453,
-  'FOG_COORDINATE_ARRAY_TYPE': 0x8454,
-  'FOG_COORDINATE_ARRAY_STRIDE': 0x8455,
-  'FOG_COORDINATE_ARRAY_POINTER': 0x8456,
-  'FOG_COORDINATE_ARRAY': 0x8457,
-  'COLOR_SUM': 0x8458,
-  'CURRENT_SECONDARY_COLOR': 0x8459,
-  'SECONDARY_COLOR_ARRAY_SIZE': 0x845A,
-  'SECONDARY_COLOR_ARRAY_TYPE': 0x845B,
-  'SECONDARY_COLOR_ARRAY_STRIDE': 0x845C,
-  'SECONDARY_COLOR_ARRAY_POINTER': 0x845D,
-  'SECONDARY_COLOR_ARRAY': 0x845E,
-  'MAX_TEXTURE_LOD_BIAS': 0x84FD,
-  'TEXTURE_FILTER_CONTROL': 0x8500,
-  'TEXTURE_LOD_BIAS': 0x8501,
-  'INCR_WRAP': 0x8507,
-  'DECR_WRAP': 0x8508,
-  'TEXTURE_DEPTH_SIZE': 0x884A,
-  'DEPTH_TEXTURE_MODE': 0x884B,
-  'TEXTURE_COMPARE_MODE': 0x884C,
-  'TEXTURE_COMPARE_FUNC': 0x884D,
-  'COMPARE_R_TO_TEXTURE': 0x884E,
-  'BUFFER_SIZE': 0x8764,
-  'BUFFER_USAGE': 0x8765,
-  'QUERY_COUNTER_BITS': 0x8864,
-  'CURRENT_QUERY': 0x8865,
-  'QUERY_RESULT': 0x8866,
-  'QUERY_RESULT_AVAILABLE': 0x8867,
-  'ARRAY_BUFFER': 0x8892,
-  'ELEMENT_ARRAY_BUFFER': 0x8893,
-  'ARRAY_BUFFER_BINDING': 0x8894,
-  'ELEMENT_ARRAY_BUFFER_BINDING': 0x8895,
-  'VERTEX_ARRAY_BUFFER_BINDING': 0x8896,
-  'NORMAL_ARRAY_BUFFER_BINDING': 0x8897,
-  'COLOR_ARRAY_BUFFER_BINDING': 0x8898,
-  'INDEX_ARRAY_BUFFER_BINDING': 0x8899,
-  'TEXTURE_COORD_ARRAY_BUFFER_BINDING': 0x889A,
-  'EDGE_FLAG_ARRAY_BUFFER_BINDING': 0x889B,
-  'SECONDARY_COLOR_ARRAY_BUFFER_BINDING': 0x889C,
-  'FOG_COORDINATE_ARRAY_BUFFER_BINDING': 0x889D,
-  'WEIGHT_ARRAY_BUFFER_BINDING': 0x889E,
-  'VERTEX_ATTRIB_ARRAY_BUFFER_BINDING': 0x889F,
-  'READ_ONLY': 0x88B8,
-  'WRITE_ONLY': 0x88B9,
-  'READ_WRITE': 0x88BA,
-  'BUFFER_ACCESS': 0x88BB,
-  'BUFFER_MAPPED': 0x88BC,
-  'BUFFER_MAP_POINTER': 0x88BD,
-  'STREAM_DRAW': 0x88E0,
-  'STREAM_READ': 0x88E1,
-  'STREAM_COPY': 0x88E2,
-  'STATIC_DRAW': 0x88E4,
-  'STATIC_READ': 0x88E5,
-  'STATIC_COPY': 0x88E6,
-  'DYNAMIC_DRAW': 0x88E8,
-  'DYNAMIC_READ': 0x88E9,
-  'DYNAMIC_COPY': 0x88EA,
-  'SAMPLES_PASSED': 0x8914,
-  'VERTEX_ATTRIB_ARRAY_ENABLED': 0x8622,
-  'VERTEX_ATTRIB_ARRAY_SIZE': 0x8623,
-  'VERTEX_ATTRIB_ARRAY_STRIDE': 0x8624,
-  'VERTEX_ATTRIB_ARRAY_TYPE': 0x8625,
-  'CURRENT_VERTEX_ATTRIB': 0x8626,
-  'VERTEX_PROGRAM_POINT_SIZE': 0x8642,
-  'VERTEX_PROGRAM_TWO_SIDE': 0x8643,
-  'VERTEX_ATTRIB_ARRAY_POINTER': 0x8645,
-  'STENCIL_BACK_FUNC': 0x8800,
-  'STENCIL_BACK_FAIL': 0x8801,
-  'STENCIL_BACK_PASS_DEPTH_FAIL': 0x8802,
-  'STENCIL_BACK_PASS_DEPTH_PASS': 0x8803,
-  'MAX_DRAW_BUFFERS': 0x8824,
-  'DRAW_BUFFER0': 0x8825,
-  'DRAW_BUFFER1': 0x8826,
-  'DRAW_BUFFER2': 0x8827,
-  'DRAW_BUFFER3': 0x8828,
-  'DRAW_BUFFER4': 0x8829,
-  'DRAW_BUFFER5': 0x882A,
-  'DRAW_BUFFER6': 0x882B,
-  'DRAW_BUFFER7': 0x882C,
-  'DRAW_BUFFER8': 0x882D,
-  'DRAW_BUFFER9': 0x882E,
-  'DRAW_BUFFER10': 0x882F,
-  'DRAW_BUFFER11': 0x8830,
-  'DRAW_BUFFER12': 0x8831,
-  'DRAW_BUFFER13': 0x8832,
-  'DRAW_BUFFER14': 0x8833,
-  'DRAW_BUFFER15': 0x8834,
-  'BLEND_EQUATION_ALPHA': 0x883D,
-  'POINT_SPRITE': 0x8861,
-  'COORD_REPLACE': 0x8862,
-  'MAX_VERTEX_ATTRIBS': 0x8869,
-  'VERTEX_ATTRIB_ARRAY_NORMALIZED': 0x886A,
-  'MAX_TEXTURE_COORDS': 0x8871,
-  'MAX_TEXTURE_IMAGE_UNITS': 0x8872,
-  'FRAGMENT_SHADER': 0x8B30,
-  'VERTEX_SHADER': 0x8B31,
-  'MAX_FRAGMENT_UNIFORM_COMPONENTS': 0x8B49,
-  'MAX_VERTEX_UNIFORM_COMPONENTS': 0x8B4A,
-  'MAX_VARYING_FLOATS': 0x8B4B,
-  'MAX_VERTEX_TEXTURE_IMAGE_UNITS': 0x8B4C,
-  'MAX_COMBINED_TEXTURE_IMAGE_UNITS': 0x8B4D,
-  'SHADER_TYPE': 0x8B4F,
-  'FLOAT_VEC2': 0x8B50,
-  'FLOAT_VEC3': 0x8B51,
-  'FLOAT_VEC4': 0x8B52,
-  'INT_VEC2': 0x8B53,
-  'INT_VEC3': 0x8B54,
-  'INT_VEC4': 0x8B55,
-  'BOOL': 0x8B56,
-  'BOOL_VEC2': 0x8B57,
-  'BOOL_VEC3': 0x8B58,
-  'BOOL_VEC4': 0x8B59,
-  'FLOAT_MAT2': 0x8B5A,
-  'FLOAT_MAT3': 0x8B5B,
-  'FLOAT_MAT4': 0x8B5C,
-  'SAMPLER_1D': 0x8B5D,
-  'SAMPLER_2D': 0x8B5E,
-  'SAMPLER_3D': 0x8B5F,
-  'SAMPLER_CUBE': 0x8B60,
-  'SAMPLER_1D_SHADOW': 0x8B61,
-  'SAMPLER_2D_SHADOW': 0x8B62,
-  'DELETE_STATUS': 0x8B80,
-  'COMPILE_STATUS': 0x8B81,
-  'LINK_STATUS': 0x8B82,
-  'VALIDATE_STATUS': 0x8B83,
-  'INFO_LOG_LENGTH': 0x8B84,
-  'ATTACHED_SHADERS': 0x8B85,
-  'ACTIVE_UNIFORMS': 0x8B86,
-  'ACTIVE_UNIFORM_MAX_LENGTH': 0x8B87,
-  'SHADER_SOURCE_LENGTH': 0x8B88,
-  'ACTIVE_ATTRIBUTES': 0x8B89,
-  'ACTIVE_ATTRIBUTE_MAX_LENGTH': 0x8B8A,
-  'FRAGMENT_SHADER_DERIVATIVE_HINT': 0x8B8B,
-  'SHADING_LANGUAGE_VERSION': 0x8B8C,
-  'CURRENT_PROGRAM': 0x8B8D,
-  'POINT_SPRITE_COORD_ORIGIN': 0x8CA0,
-  'LOWER_LEFT': 0x8CA1,
-  'UPPER_LEFT': 0x8CA2,
-  'STENCIL_BACK_REF': 0x8CA3,
-  'STENCIL_BACK_VALUE_MASK': 0x8CA4,
-  'STENCIL_BACK_WRITEMASK': 0x8CA5,
-  'CURRENT_RASTER_SECONDARY_COLOR': 0x845F,
-  'PIXEL_PACK_BUFFER': 0x88EB,
-  'PIXEL_UNPACK_BUFFER': 0x88EC,
-  'PIXEL_PACK_BUFFER_BINDING': 0x88ED,
-  'PIXEL_UNPACK_BUFFER_BINDING': 0x88EF,
-  'FLOAT_MAT2x3': 0x8B65,
-  'FLOAT_MAT2x4': 0x8B66,
-  'FLOAT_MAT3x2': 0x8B67,
-  'FLOAT_MAT3x4': 0x8B68,
-  'FLOAT_MAT4x2': 0x8B69,
-  'FLOAT_MAT4x3': 0x8B6A,
-  'SRGB': 0x8C40,
-  'SRGB8': 0x8C41,
-  'SRGB_ALPHA': 0x8C42,
-  'SRGB8_ALPHA8': 0x8C43,
-  'SLUMINANCE_ALPHA': 0x8C44,
-  'SLUMINANCE8_ALPHA8': 0x8C45,
-  'SLUMINANCE': 0x8C46,
-  'SLUMINANCE8': 0x8C47,
-  'COMPRESSED_SRGB': 0x8C48,
-  'COMPRESSED_SRGB_ALPHA': 0x8C49,
-  'COMPRESSED_SLUMINANCE': 0x8C4A,
-  'COMPRESSED_SLUMINANCE_ALPHA': 0x8C4B,
-  'CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT': 0x0001,
-  'MAJOR_VERSION': 0x821B,
-  'MINOR_VERSION': 0x821C,
-  'NUM_EXTENSIONS': 0x821D,
-  'CONTEXT_FLAGS': 0x821E,
-  'DEPTH_BUFFER': 0x8223,
-  'STENCIL_BUFFER': 0x8224,
-  'COMPRESSED_RED': 0x8225,
-  'COMPRESSED_RG': 0x8226,
-  'RGBA32F': 0x8814,
-  'RGB32F': 0x8815,
-  'RGBA16F': 0x881A,
-  'RGB16F': 0x881B,
-  'VERTEX_ATTRIB_ARRAY_INTEGER': 0x88FD,
-  'MAX_ARRAY_TEXTURE_LAYERS': 0x88FF,
-  'MIN_PROGRAM_TEXEL_OFFSET': 0x8904,
-  'MAX_PROGRAM_TEXEL_OFFSET': 0x8905,
-  'CLAMP_VERTEX_COLOR': 0x891A,
-  'CLAMP_FRAGMENT_COLOR': 0x891B,
-  'CLAMP_READ_COLOR': 0x891C,
-  'FIXED_ONLY': 0x891D,
-  'TEXTURE_RED_TYPE': 0x8C10,
-  'TEXTURE_GREEN_TYPE': 0x8C11,
-  'TEXTURE_BLUE_TYPE': 0x8C12,
-  'TEXTURE_ALPHA_TYPE': 0x8C13,
-  'TEXTURE_LUMINANCE_TYPE': 0x8C14,
-  'TEXTURE_INTENSITY_TYPE': 0x8C15,
-  'TEXTURE_DEPTH_TYPE': 0x8C16,
-  'UNSIGNED_NORMALIZED': 0x8C17,
-  'TEXTURE_1D_ARRAY': 0x8C18,
-  'PROXY_TEXTURE_1D_ARRAY': 0x8C19,
-  'TEXTURE_2D_ARRAY': 0x8C1A,
-  'PROXY_TEXTURE_2D_ARRAY': 0x8C1B,
-  'TEXTURE_BINDING_1D_ARRAY': 0x8C1C,
-  'TEXTURE_BINDING_2D_ARRAY': 0x8C1D,
-  'R11F_G11F_B10F': 0x8C3A,
-  'UNSIGNED_INT_10F_11F_11F_REV': 0x8C3B,
-  'RGB9_E5': 0x8C3D,
-  'UNSIGNED_INT_5_9_9_9_REV': 0x8C3E,
-  'TEXTURE_SHARED_SIZE': 0x8C3F,
-  'TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH': 0x8C76,
-  'TRANSFORM_FEEDBACK_BUFFER_MODE': 0x8C7F,
-  'MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS': 0x8C80,
-  'TRANSFORM_FEEDBACK_VARYINGS': 0x8C83,
-  'TRANSFORM_FEEDBACK_BUFFER_START': 0x8C84,
-  'TRANSFORM_FEEDBACK_BUFFER_SIZE': 0x8C85,
-  'PRIMITIVES_GENERATED': 0x8C87,
-  'TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN': 0x8C88,
-  'RASTERIZER_DISCARD': 0x8C89,
-  'MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS': 0x8C8A,
-  'MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS': 0x8C8B,
-  'INTERLEAVED_ATTRIBS': 0x8C8C,
-  'SEPARATE_ATTRIBS': 0x8C8D,
-  'TRANSFORM_FEEDBACK_BUFFER': 0x8C8E,
-  'TRANSFORM_FEEDBACK_BUFFER_BINDING': 0x8C8F,
-  'RGBA32UI': 0x8D70,
-  'RGB32UI': 0x8D71,
-  'RGBA16UI': 0x8D76,
-  'RGB16UI': 0x8D77,
-  'RGBA8UI': 0x8D7C,
-  'RGB8UI': 0x8D7D,
-  'RGBA32I': 0x8D82,
-  'RGB32I': 0x8D83,
-  'RGBA16I': 0x8D88,
-  'RGB16I': 0x8D89,
-  'RGBA8I': 0x8D8E,
-  'RGB8I': 0x8D8F,
-  'RED_INTEGER': 0x8D94,
-  'GREEN_INTEGER': 0x8D95,
-  'BLUE_INTEGER': 0x8D96,
-  'ALPHA_INTEGER': 0x8D97,
-  'RGB_INTEGER': 0x8D98,
-  'RGBA_INTEGER': 0x8D99,
-  'BGR_INTEGER': 0x8D9A,
-  'BGRA_INTEGER': 0x8D9B,
-  'SAMPLER_1D_ARRAY': 0x8DC0,
-  'SAMPLER_2D_ARRAY': 0x8DC1,
-  'SAMPLER_1D_ARRAY_SHADOW': 0x8DC3,
-  'SAMPLER_2D_ARRAY_SHADOW': 0x8DC4,
-  'SAMPLER_CUBE_SHADOW': 0x8DC5,
-  'UNSIGNED_INT_VEC2': 0x8DC6,
-  'UNSIGNED_INT_VEC3': 0x8DC7,
-  'UNSIGNED_INT_VEC4': 0x8DC8,
-  'INT_SAMPLER_1D': 0x8DC9,
-  'INT_SAMPLER_2D': 0x8DCA,
-  'INT_SAMPLER_3D': 0x8DCB,
-  'INT_SAMPLER_CUBE': 0x8DCC,
-  'INT_SAMPLER_1D_ARRAY': 0x8DCE,
-  'INT_SAMPLER_2D_ARRAY': 0x8DCF,
-  'UNSIGNED_INT_SAMPLER_1D': 0x8DD1,
-  'UNSIGNED_INT_SAMPLER_2D': 0x8DD2,
-  'UNSIGNED_INT_SAMPLER_3D': 0x8DD3,
-  'UNSIGNED_INT_SAMPLER_CUBE': 0x8DD4,
-  'UNSIGNED_INT_SAMPLER_1D_ARRAY': 0x8DD6,
-  'UNSIGNED_INT_SAMPLER_2D_ARRAY': 0x8DD7,
-  'QUERY_WAIT': 0x8E13,
-  'QUERY_NO_WAIT': 0x8E14,
-  'QUERY_BY_REGION_WAIT': 0x8E15,
-  'QUERY_BY_REGION_NO_WAIT': 0x8E16,
-  'MULTISAMPLE_3DFX': 0x86B2,
-  'SAMPLE_BUFFERS_3DFX': 0x86B3,
-  'SAMPLES_3DFX': 0x86B4,
-  'MULTISAMPLE_BIT_3DFX': 0x20000000,
-  'COMPRESSED_RGB_FXT1_3DFX': 0x86B0,
-  'COMPRESSED_RGBA_FXT1_3DFX': 0x86B1,
-  'UNPACK_CLIENT_STORAGE_APPLE': 0x85B2,
-  'ELEMENT_ARRAY_APPLE': 0x8768,
-  'ELEMENT_ARRAY_TYPE_APPLE': 0x8769,
-  'ELEMENT_ARRAY_POINTER_APPLE': 0x876A,
-  'HALF_APPLE': 0x140B,
-  'RGBA_FLOAT32_APPLE': 0x8814,
-  'RGB_FLOAT32_APPLE': 0x8815,
-  'ALPHA_FLOAT32_APPLE': 0x8816,
-  'INTENSITY_FLOAT32_APPLE': 0x8817,
-  'LUMINANCE_FLOAT32_APPLE': 0x8818,
-  'LUMINANCE_ALPHA_FLOAT32_APPLE': 0x8819,
-  'RGBA_FLOAT16_APPLE': 0x881A,
-  'RGB_FLOAT16_APPLE': 0x881B,
-  'ALPHA_FLOAT16_APPLE': 0x881C,
-  'INTENSITY_FLOAT16_APPLE': 0x881D,
-  'LUMINANCE_FLOAT16_APPLE': 0x881E,
-  'LUMINANCE_ALPHA_FLOAT16_APPLE': 0x881F,
-  'COLOR_FLOAT_APPLE': 0x8A0F,
-  'BUFFER_SERIALIZED_MODIFY_APPLE': 0x8A12,
-  'BUFFER_FLUSHING_UNMAP_APPLE': 0x8A13,
-  'MIN_PBUFFER_VIEWPORT_DIMS_APPLE': 0x8A10,
-  'LIGHT_MODEL_SPECULAR_VECTOR_APPLE': 0x85B0,
-  'TEXTURE_RANGE_LENGTH_APPLE': 0x85B7,
-  'TEXTURE_RANGE_POINTER_APPLE': 0x85B8,
-  'TEXTURE_STORAGE_HINT_APPLE': 0x85BC,
-  'STORAGE_PRIVATE_APPLE': 0x85BD,
-  'STORAGE_CACHED_APPLE': 0x85BE,
-  'STORAGE_SHARED_APPLE': 0x85BF,
-  'TRANSFORM_HINT_APPLE': 0x85B1,
-  'VERTEX_ARRAY_BINDING_APPLE': 0x85B5,
-  'VERTEX_ARRAY_RANGE_APPLE': 0x851D,
-  'VERTEX_ARRAY_RANGE_LENGTH_APPLE': 0x851E,
-  'VERTEX_ARRAY_STORAGE_HINT_APPLE': 0x851F,
-  'MAX_VERTEX_ARRAY_RANGE_ELEMENT_APPLE': 0x8520,
-  'VERTEX_ARRAY_RANGE_POINTER_APPLE': 0x8521,
-  'STORAGE_CACHED_APPLE': 0x85BE,
-  'STORAGE_SHARED_APPLE': 0x85BF,
-  'YCBCR_422_APPLE': 0x85B9,
-  'UNSIGNED_SHORT_8_8_APPLE': 0x85BA,
-  'UNSIGNED_SHORT_8_8_REV_APPLE': 0x85BB,
-  'RGBA_FLOAT_MODE_ARB': 0x8820,
-  'CLAMP_VERTEX_COLOR_ARB': 0x891A,
-  'CLAMP_FRAGMENT_COLOR_ARB': 0x891B,
-  'CLAMP_READ_COLOR_ARB': 0x891C,
-  'FIXED_ONLY_ARB': 0x891D,
-  'DEPTH_COMPONENT32F': 0x8CAC,
-  'DEPTH32F_STENCIL8': 0x8CAD,
-  'FLOAT_32_UNSIGNED_INT_24_8_REV': 0x8DAD,
-  'DEPTH_COMPONENT16_ARB': 0x81A5,
-  'DEPTH_COMPONENT24_ARB': 0x81A6,
-  'DEPTH_COMPONENT32_ARB': 0x81A7,
-  'TEXTURE_DEPTH_SIZE_ARB': 0x884A,
-  'DEPTH_TEXTURE_MODE_ARB': 0x884B,
-  'MAX_DRAW_BUFFERS_ARB': 0x8824,
-  'DRAW_BUFFER0_ARB': 0x8825,
-  'DRAW_BUFFER1_ARB': 0x8826,
-  'DRAW_BUFFER2_ARB': 0x8827,
-  'DRAW_BUFFER3_ARB': 0x8828,
-  'DRAW_BUFFER4_ARB': 0x8829,
-  'DRAW_BUFFER5_ARB': 0x882A,
-  'DRAW_BUFFER6_ARB': 0x882B,
-  'DRAW_BUFFER7_ARB': 0x882C,
-  'DRAW_BUFFER8_ARB': 0x882D,
-  'DRAW_BUFFER9_ARB': 0x882E,
-  'DRAW_BUFFER10_ARB': 0x882F,
-  'DRAW_BUFFER11_ARB': 0x8830,
-  'DRAW_BUFFER12_ARB': 0x8831,
-  'DRAW_BUFFER13_ARB': 0x8832,
-  'DRAW_BUFFER14_ARB': 0x8833,
-  'DRAW_BUFFER15_ARB': 0x8834,
-  'FRAGMENT_PROGRAM_ARB': 0x8804,
-  'PROGRAM_ALU_INSTRUCTIONS_ARB': 0x8805,
-  'PROGRAM_TEX_INSTRUCTIONS_ARB': 0x8806,
-  'PROGRAM_TEX_INDIRECTIONS_ARB': 0x8807,
-  'PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB': 0x8808,
-  'PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB': 0x8809,
-  'PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB': 0x880A,
-  'MAX_PROGRAM_ALU_INSTRUCTIONS_ARB': 0x880B,
-  'MAX_PROGRAM_TEX_INSTRUCTIONS_ARB': 0x880C,
-  'MAX_PROGRAM_TEX_INDIRECTIONS_ARB': 0x880D,
-  'MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB': 0x880E,
-  'MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB': 0x880F,
-  'MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB': 0x8810,
-  'MAX_TEXTURE_COORDS_ARB': 0x8871,
-  'MAX_TEXTURE_IMAGE_UNITS_ARB': 0x8872,
-  'FRAGMENT_SHADER_ARB': 0x8B30,
-  'MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB': 0x8B49,
-  'FRAGMENT_SHADER_DERIVATIVE_HINT_ARB': 0x8B8B,
-  'INVALID_FRAMEBUFFER_OPERATION': 0x0506,
-  'FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING': 0x8210,
-  'FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE': 0x8211,
-  'FRAMEBUFFER_ATTACHMENT_RED_SIZE': 0x8212,
-  'FRAMEBUFFER_ATTACHMENT_GREEN_SIZE': 0x8213,
-  'FRAMEBUFFER_ATTACHMENT_BLUE_SIZE': 0x8214,
-  'FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE': 0x8215,
-  'FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE': 0x8216,
-  'FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE': 0x8217,
-  'FRAMEBUFFER_DEFAULT': 0x8218,
-  'FRAMEBUFFER_UNDEFINED': 0x8219,
-  'DEPTH_STENCIL_ATTACHMENT': 0x821A,
-  'INDEX': 0x8222,
-  'MAX_RENDERBUFFER_SIZE': 0x84E8,
-  'DEPTH_STENCIL': 0x84F9,
-  'UNSIGNED_INT_24_8': 0x84FA,
-  'DEPTH24_STENCIL8': 0x88F0,
-  'TEXTURE_STENCIL_SIZE': 0x88F1,
-  'UNSIGNED_NORMALIZED': 0x8C17,
-  'SRGB': 0x8C40,
-  'DRAW_FRAMEBUFFER_BINDING': 0x8CA6,
-  'FRAMEBUFFER_BINDING': 0x8CA6,
-  'RENDERBUFFER_BINDING': 0x8CA7,
-  'READ_FRAMEBUFFER': 0x8CA8,
-  'DRAW_FRAMEBUFFER': 0x8CA9,
-  'READ_FRAMEBUFFER_BINDING': 0x8CAA,
-  'RENDERBUFFER_SAMPLES': 0x8CAB,
-  'FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE': 0x8CD0,
-  'FRAMEBUFFER_ATTACHMENT_OBJECT_NAME': 0x8CD1,
-  'FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL': 0x8CD2,
-  'FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE': 0x8CD3,
-  'FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER': 0x8CD4,
-  'FRAMEBUFFER_COMPLETE': 0x8CD5,
-  'FRAMEBUFFER_INCOMPLETE_ATTACHMENT': 0x8CD6,
-  'FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT': 0x8CD7,
-  'FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER': 0x8CDB,
-  'FRAMEBUFFER_INCOMPLETE_READ_BUFFER': 0x8CDC,
-  'FRAMEBUFFER_UNSUPPORTED': 0x8CDD,
-  'MAX_COLOR_ATTACHMENTS': 0x8CDF,
-  'COLOR_ATTACHMENT0': 0x8CE0,
-  'COLOR_ATTACHMENT1': 0x8CE1,
-  'COLOR_ATTACHMENT2': 0x8CE2,
-  'COLOR_ATTACHMENT3': 0x8CE3,
-  'COLOR_ATTACHMENT4': 0x8CE4,
-  'COLOR_ATTACHMENT5': 0x8CE5,
-  'COLOR_ATTACHMENT6': 0x8CE6,
-  'COLOR_ATTACHMENT7': 0x8CE7,
-  'COLOR_ATTACHMENT8': 0x8CE8,
-  'COLOR_ATTACHMENT9': 0x8CE9,
-  'COLOR_ATTACHMENT10': 0x8CEA,
-  'COLOR_ATTACHMENT11': 0x8CEB,
-  'COLOR_ATTACHMENT12': 0x8CEC,
-  'COLOR_ATTACHMENT13': 0x8CED,
-  'COLOR_ATTACHMENT14': 0x8CEE,
-  'COLOR_ATTACHMENT15': 0x8CEF,
-  'DEPTH_ATTACHMENT': 0x8D00,
-  'STENCIL_ATTACHMENT': 0x8D20,
-  'FRAMEBUFFER': 0x8D40,
-  'RENDERBUFFER': 0x8D41,
-  'RENDERBUFFER_WIDTH': 0x8D42,
-  'RENDERBUFFER_HEIGHT': 0x8D43,
-  'RENDERBUFFER_INTERNAL_FORMAT': 0x8D44,
-  'STENCIL_INDEX1': 0x8D46,
-  'STENCIL_INDEX4': 0x8D47,
-  'STENCIL_INDEX8': 0x8D48,
-  'STENCIL_INDEX16': 0x8D49,
-  'RENDERBUFFER_RED_SIZE': 0x8D50,
-  'RENDERBUFFER_GREEN_SIZE': 0x8D51,
-  'RENDERBUFFER_BLUE_SIZE': 0x8D52,
-  'RENDERBUFFER_ALPHA_SIZE': 0x8D53,
-  'RENDERBUFFER_DEPTH_SIZE': 0x8D54,
-  'RENDERBUFFER_STENCIL_SIZE': 0x8D55,
-  'FRAMEBUFFER_INCOMPLETE_MULTISAMPLE': 0x8D56,
-  'MAX_SAMPLES': 0x8D57,
-  'FRAMEBUFFER_SRGB': 0x8DB9,
-  'LINES_ADJACENCY_ARB': 0xA,
-  'LINE_STRIP_ADJACENCY_ARB': 0xB,
-  'TRIANGLES_ADJACENCY_ARB': 0xC,
-  'TRIANGLE_STRIP_ADJACENCY_ARB': 0xD,
-  'PROGRAM_POINT_SIZE_ARB': 0x8642,
-  'MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB': 0x8C29,
-  'FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER': 0x8CD4,
-  'FRAMEBUFFER_ATTACHMENT_LAYERED_ARB': 0x8DA7,
-  'FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_ARB': 0x8DA8,
-  'FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_ARB': 0x8DA9,
-  'GEOMETRY_SHADER_ARB': 0x8DD9,
-  'GEOMETRY_VERTICES_OUT_ARB': 0x8DDA,
-  'GEOMETRY_INPUT_TYPE_ARB': 0x8DDB,
-  'GEOMETRY_OUTPUT_TYPE_ARB': 0x8DDC,
-  'MAX_GEOMETRY_VARYING_COMPONENTS_ARB': 0x8DDD,
-  'MAX_VERTEX_VARYING_COMPONENTS_ARB': 0x8DDE,
-  'MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB': 0x8DDF,
-  'MAX_GEOMETRY_OUTPUT_VERTICES_ARB': 0x8DE0,
-  'MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB': 0x8DE1,
-  'HALF_FLOAT_ARB': 0x140B,
-  'HALF_FLOAT': 0x140B,
-  'CONSTANT_COLOR': 0x8001,
-  'ONE_MINUS_CONSTANT_COLOR': 0x8002,
-  'CONSTANT_ALPHA': 0x8003,
-  'ONE_MINUS_CONSTANT_ALPHA': 0x8004,
-  'BLEND_COLOR': 0x8005,
-  'FUNC_ADD': 0x8006,
-  'MIN': 0x8007,
-  'MAX': 0x8008,
-  'BLEND_EQUATION': 0x8009,
-  'FUNC_SUBTRACT': 0x800A,
-  'FUNC_REVERSE_SUBTRACT': 0x800B,
-  'CONVOLUTION_1D': 0x8010,
-  'CONVOLUTION_2D': 0x8011,
-  'SEPARABLE_2D': 0x8012,
-  'CONVOLUTION_BORDER_MODE': 0x8013,
-  'CONVOLUTION_FILTER_SCALE': 0x8014,
-  'CONVOLUTION_FILTER_BIAS': 0x8015,
-  'REDUCE': 0x8016,
-  'CONVOLUTION_FORMAT': 0x8017,
-  'CONVOLUTION_WIDTH': 0x8018,
-  'CONVOLUTION_HEIGHT': 0x8019,
-  'MAX_CONVOLUTION_WIDTH': 0x801A,
-  'MAX_CONVOLUTION_HEIGHT': 0x801B,
-  'POST_CONVOLUTION_RED_SCALE': 0x801C,
-  'POST_CONVOLUTION_GREEN_SCALE': 0x801D,
-  'POST_CONVOLUTION_BLUE_SCALE': 0x801E,
-  'POST_CONVOLUTION_ALPHA_SCALE': 0x801F,
-  'POST_CONVOLUTION_RED_BIAS': 0x8020,
-  'POST_CONVOLUTION_GREEN_BIAS': 0x8021,
-  'POST_CONVOLUTION_BLUE_BIAS': 0x8022,
-  'POST_CONVOLUTION_ALPHA_BIAS': 0x8023,
-  'HISTOGRAM': 0x8024,
-  'PROXY_HISTOGRAM': 0x8025,
-  'HISTOGRAM_WIDTH': 0x8026,
-  'HISTOGRAM_FORMAT': 0x8027,
-  'HISTOGRAM_RED_SIZE': 0x8028,
-  'HISTOGRAM_GREEN_SIZE': 0x8029,
-  'HISTOGRAM_BLUE_SIZE': 0x802A,
-  'HISTOGRAM_ALPHA_SIZE': 0x802B,
-  'HISTOGRAM_LUMINANCE_SIZE': 0x802C,
-  'HISTOGRAM_SINK': 0x802D,
-  'MINMAX': 0x802E,
-  'MINMAX_FORMAT': 0x802F,
-  'MINMAX_SINK': 0x8030,
-  'TABLE_TOO_LARGE': 0x8031,
-  'COLOR_MATRIX': 0x80B1,
-  'COLOR_MATRIX_STACK_DEPTH': 0x80B2,
-  'MAX_COLOR_MATRIX_STACK_DEPTH': 0x80B3,
-  'POST_COLOR_MATRIX_RED_SCALE': 0x80B4,
-  'POST_COLOR_MATRIX_GREEN_SCALE': 0x80B5,
-  'POST_COLOR_MATRIX_BLUE_SCALE': 0x80B6,
-  'POST_COLOR_MATRIX_ALPHA_SCALE': 0x80B7,
-  'POST_COLOR_MATRIX_RED_BIAS': 0x80B8,
-  'POST_COLOR_MATRIX_GREEN_BIAS': 0x80B9,
-  'POST_COLOR_MATRIX_BLUE_BIAS': 0x80BA,
-  'POST_COLOR_MATRIX_ALPHA_BIAS': 0x80BB,
-  'COLOR_TABLE': 0x80D0,
-  'POST_CONVOLUTION_COLOR_TABLE': 0x80D1,
-  'POST_COLOR_MATRIX_COLOR_TABLE': 0x80D2,
-  'PROXY_COLOR_TABLE': 0x80D3,
-  'PROXY_POST_CONVOLUTION_COLOR_TABLE': 0x80D4,
-  'PROXY_POST_COLOR_MATRIX_COLOR_TABLE': 0x80D5,
-  'COLOR_TABLE_SCALE': 0x80D6,
-  'COLOR_TABLE_BIAS': 0x80D7,
-  'COLOR_TABLE_FORMAT': 0x80D8,
-  'COLOR_TABLE_WIDTH': 0x80D9,
-  'COLOR_TABLE_RED_SIZE': 0x80DA,
-  'COLOR_TABLE_GREEN_SIZE': 0x80DB,
-  'COLOR_TABLE_BLUE_SIZE': 0x80DC,
-  'COLOR_TABLE_ALPHA_SIZE': 0x80DD,
-  'COLOR_TABLE_LUMINANCE_SIZE': 0x80DE,
-  'COLOR_TABLE_INTENSITY_SIZE': 0x80DF,
-  'IGNORE_BORDER': 0x8150,
-  'CONSTANT_BORDER': 0x8151,
-  'WRAP_BORDER': 0x8152,
-  'REPLICATE_BORDER': 0x8153,
-  'CONVOLUTION_BORDER_COLOR': 0x8154,
-  'VERTEX_ATTRIB_ARRAY_DIVISOR_ARB': 0x88FE,
-  'MAP_READ_BIT': 0x0001,
-  'MAP_WRITE_BIT': 0x0002,
-  'MAP_INVALIDATE_RANGE_BIT': 0x0004,
-  'MAP_INVALIDATE_BUFFER_BIT': 0x0008,
-  'MAP_FLUSH_EXPLICIT_BIT': 0x0010,
-  'MAP_UNSYNCHRONIZED_BIT': 0x0020,
-  'MATRIX_PALETTE_ARB': 0x8840,
-  'MAX_MATRIX_PALETTE_STACK_DEPTH_ARB': 0x8841,
-  'MAX_PALETTE_MATRICES_ARB': 0x8842,
-  'CURRENT_PALETTE_MATRIX_ARB': 0x8843,
-  'MATRIX_INDEX_ARRAY_ARB': 0x8844,
-  'CURRENT_MATRIX_INDEX_ARB': 0x8845,
-  'MATRIX_INDEX_ARRAY_SIZE_ARB': 0x8846,
-  'MATRIX_INDEX_ARRAY_TYPE_ARB': 0x8847,
-  'MATRIX_INDEX_ARRAY_STRIDE_ARB': 0x8848,
-  'MATRIX_INDEX_ARRAY_POINTER_ARB': 0x8849,
-  'MULTISAMPLE_ARB': 0x809D,
-  'SAMPLE_ALPHA_TO_COVERAGE_ARB': 0x809E,
-  'SAMPLE_ALPHA_TO_ONE_ARB': 0x809F,
-  'SAMPLE_COVERAGE_ARB': 0x80A0,
-  'SAMPLE_BUFFERS_ARB': 0x80A8,
-  'SAMPLES_ARB': 0x80A9,
-  'SAMPLE_COVERAGE_VALUE_ARB': 0x80AA,
-  'SAMPLE_COVERAGE_INVERT_ARB': 0x80AB,
-  'MULTISAMPLE_BIT_ARB': 0x20000000,
-  'TEXTURE0_ARB': 0x84C0,
-  'TEXTURE1_ARB': 0x84C1,
-  'TEXTURE2_ARB': 0x84C2,
-  'TEXTURE3_ARB': 0x84C3,
-  'TEXTURE4_ARB': 0x84C4,
-  'TEXTURE5_ARB': 0x84C5,
-  'TEXTURE6_ARB': 0x84C6,
-  'TEXTURE7_ARB': 0x84C7,
-  'TEXTURE8_ARB': 0x84C8,
-  'TEXTURE9_ARB': 0x84C9,
-  'TEXTURE10_ARB': 0x84CA,
-  'TEXTURE11_ARB': 0x84CB,
-  'TEXTURE12_ARB': 0x84CC,
-  'TEXTURE13_ARB': 0x84CD,
-  'TEXTURE14_ARB': 0x84CE,
-  'TEXTURE15_ARB': 0x84CF,
-  'TEXTURE16_ARB': 0x84D0,
-  'TEXTURE17_ARB': 0x84D1,
-  'TEXTURE18_ARB': 0x84D2,
-  'TEXTURE19_ARB': 0x84D3,
-  'TEXTURE20_ARB': 0x84D4,
-  'TEXTURE21_ARB': 0x84D5,
-  'TEXTURE22_ARB': 0x84D6,
-  'TEXTURE23_ARB': 0x84D7,
-  'TEXTURE24_ARB': 0x84D8,
-  'TEXTURE25_ARB': 0x84D9,
-  'TEXTURE26_ARB': 0x84DA,
-  'TEXTURE27_ARB': 0x84DB,
-  'TEXTURE28_ARB': 0x84DC,
-  'TEXTURE29_ARB': 0x84DD,
-  'TEXTURE30_ARB': 0x84DE,
-  'TEXTURE31_ARB': 0x84DF,
-  'ACTIVE_TEXTURE_ARB': 0x84E0,
-  'CLIENT_ACTIVE_TEXTURE_ARB': 0x84E1,
-  'MAX_TEXTURE_UNITS_ARB': 0x84E2,
-  'QUERY_COUNTER_BITS_ARB': 0x8864,
-  'CURRENT_QUERY_ARB': 0x8865,
-  'QUERY_RESULT_ARB': 0x8866,
-  'QUERY_RESULT_AVAILABLE_ARB': 0x8867,
-  'SAMPLES_PASSED_ARB': 0x8914,
-  'PIXEL_PACK_BUFFER_ARB': 0x88EB,
-  'PIXEL_UNPACK_BUFFER_ARB': 0x88EC,
-  'PIXEL_PACK_BUFFER_BINDING_ARB': 0x88ED,
-  'PIXEL_UNPACK_BUFFER_BINDING_ARB': 0x88EF,
-  'POINT_SIZE_MIN_ARB': 0x8126,
-  'POINT_SIZE_MAX_ARB': 0x8127,
-  'POINT_FADE_THRESHOLD_SIZE_ARB': 0x8128,
-  'POINT_DISTANCE_ATTENUATION_ARB': 0x8129,
-  'POINT_SPRITE_ARB': 0x8861,
-  'COORD_REPLACE_ARB': 0x8862,
-  'PROGRAM_OBJECT_ARB': 0x8B40,
-  'SHADER_OBJECT_ARB': 0x8B48,
-  'OBJECT_TYPE_ARB': 0x8B4E,
-  'OBJECT_SUBTYPE_ARB': 0x8B4F,
-  'FLOAT_VEC2_ARB': 0x8B50,
-  'FLOAT_VEC3_ARB': 0x8B51,
-  'FLOAT_VEC4_ARB': 0x8B52,
-  'INT_VEC2_ARB': 0x8B53,
-  'INT_VEC3_ARB': 0x8B54,
-  'INT_VEC4_ARB': 0x8B55,
-  'BOOL_ARB': 0x8B56,
-  'BOOL_VEC2_ARB': 0x8B57,
-  'BOOL_VEC3_ARB': 0x8B58,
-  'BOOL_VEC4_ARB': 0x8B59,
-  'FLOAT_MAT2_ARB': 0x8B5A,
-  'FLOAT_MAT3_ARB': 0x8B5B,
-  'FLOAT_MAT4_ARB': 0x8B5C,
-  'SAMPLER_1D_ARB': 0x8B5D,
-  'SAMPLER_2D_ARB': 0x8B5E,
-  'SAMPLER_3D_ARB': 0x8B5F,
-  'SAMPLER_CUBE_ARB': 0x8B60,
-  'SAMPLER_1D_SHADOW_ARB': 0x8B61,
-  'SAMPLER_2D_SHADOW_ARB': 0x8B62,
-  'SAMPLER_2D_RECT_ARB': 0x8B63,
-  'SAMPLER_2D_RECT_SHADOW_ARB': 0x8B64,
-  'OBJECT_DELETE_STATUS_ARB': 0x8B80,
-  'OBJECT_COMPILE_STATUS_ARB': 0x8B81,
-  'OBJECT_LINK_STATUS_ARB': 0x8B82,
-  'OBJECT_VALIDATE_STATUS_ARB': 0x8B83,
-  'OBJECT_INFO_LOG_LENGTH_ARB': 0x8B84,
-  'OBJECT_ATTACHED_OBJECTS_ARB': 0x8B85,
-  'OBJECT_ACTIVE_UNIFORMS_ARB': 0x8B86,
-  'OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB': 0x8B87,
-  'OBJECT_SHADER_SOURCE_LENGTH_ARB': 0x8B88,
-  'SHADING_LANGUAGE_VERSION_ARB': 0x8B8C,
-  'TEXTURE_COMPARE_MODE_ARB': 0x884C,
-  'TEXTURE_COMPARE_FUNC_ARB': 0x884D,
-  'COMPARE_R_TO_TEXTURE_ARB': 0x884E,
-  'TEXTURE_COMPARE_FAIL_VALUE_ARB': 0x80BF,
-  'CLAMP_TO_BORDER_ARB': 0x812D,
-  'TEXTURE_BUFFER_ARB': 0x8C2A,
-  'MAX_TEXTURE_BUFFER_SIZE_ARB': 0x8C2B,
-  'TEXTURE_BINDING_BUFFER_ARB': 0x8C2C,
-  'TEXTURE_BUFFER_DATA_STORE_BINDING_ARB': 0x8C2D,
-  'TEXTURE_BUFFER_FORMAT_ARB': 0x8C2E,
-  'COMPRESSED_ALPHA_ARB': 0x84E9,
-  'COMPRESSED_LUMINANCE_ARB': 0x84EA,
-  'COMPRESSED_LUMINANCE_ALPHA_ARB': 0x84EB,
-  'COMPRESSED_INTENSITY_ARB': 0x84EC,
-  'COMPRESSED_RGB_ARB': 0x84ED,
-  'COMPRESSED_RGBA_ARB': 0x84EE,
-  'TEXTURE_COMPRESSION_HINT_ARB': 0x84EF,
-  'TEXTURE_COMPRESSED_IMAGE_SIZE_ARB': 0x86A0,
-  'TEXTURE_COMPRESSED_ARB': 0x86A1,
-  'NUM_COMPRESSED_TEXTURE_FORMATS_ARB': 0x86A2,
-  'COMPRESSED_TEXTURE_FORMATS_ARB': 0x86A3,
-  'COMPRESSED_RED_RGTC1': 0x8DBB,
-  'COMPRESSED_SIGNED_RED_RGTC1': 0x8DBC,
-  'COMPRESSED_RG_RGTC2': 0x8DBD,
-  'COMPRESSED_SIGNED_RG_RGTC2': 0x8DBE,
-  'NORMAL_MAP_ARB': 0x8511,
-  'REFLECTION_MAP_ARB': 0x8512,
-  'TEXTURE_CUBE_MAP_ARB': 0x8513,
-  'TEXTURE_BINDING_CUBE_MAP_ARB': 0x8514,
-  'TEXTURE_CUBE_MAP_POSITIVE_X_ARB': 0x8515,
-  'TEXTURE_CUBE_MAP_NEGATIVE_X_ARB': 0x8516,
-  'TEXTURE_CUBE_MAP_POSITIVE_Y_ARB': 0x8517,
-  'TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB': 0x8518,
-  'TEXTURE_CUBE_MAP_POSITIVE_Z_ARB': 0x8519,
-  'TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB': 0x851A,
-  'PROXY_TEXTURE_CUBE_MAP_ARB': 0x851B,
-  'MAX_CUBE_MAP_TEXTURE_SIZE_ARB': 0x851C,
-  'SUBTRACT_ARB': 0x84E7,
-  'COMBINE_ARB': 0x8570,
-  'COMBINE_RGB_ARB': 0x8571,
-  'COMBINE_ALPHA_ARB': 0x8572,
-  'RGB_SCALE_ARB': 0x8573,
-  'ADD_SIGNED_ARB': 0x8574,
-  'INTERPOLATE_ARB': 0x8575,
-  'CONSTANT_ARB': 0x8576,
-  'PRIMARY_COLOR_ARB': 0x8577,
-  'PREVIOUS_ARB': 0x8578,
-  'SOURCE0_RGB_ARB': 0x8580,
-  'SOURCE1_RGB_ARB': 0x8581,
-  'SOURCE2_RGB_ARB': 0x8582,
-  'SOURCE0_ALPHA_ARB': 0x8588,
-  'SOURCE1_ALPHA_ARB': 0x8589,
-  'SOURCE2_ALPHA_ARB': 0x858A,
-  'OPERAND0_RGB_ARB': 0x8590,
-  'OPERAND1_RGB_ARB': 0x8591,
-  'OPERAND2_RGB_ARB': 0x8592,
-  'OPERAND0_ALPHA_ARB': 0x8598,
-  'OPERAND1_ALPHA_ARB': 0x8599,
-  'OPERAND2_ALPHA_ARB': 0x859A,
-  'DOT3_RGB_ARB': 0x86AE,
-  'DOT3_RGBA_ARB': 0x86AF,
-  'RGBA32F_ARB': 0x8814,
-  'RGB32F_ARB': 0x8815,
-  'ALPHA32F_ARB': 0x8816,
-  'INTENSITY32F_ARB': 0x8817,
-  'LUMINANCE32F_ARB': 0x8818,
-  'LUMINANCE_ALPHA32F_ARB': 0x8819,
-  'RGBA16F_ARB': 0x881A,
-  'RGB16F_ARB': 0x881B,
-  'ALPHA16F_ARB': 0x881C,
-  'INTENSITY16F_ARB': 0x881D,
-  'LUMINANCE16F_ARB': 0x881E,
-  'LUMINANCE_ALPHA16F_ARB': 0x881F,
-  'TEXTURE_RED_TYPE_ARB': 0x8C10,
-  'TEXTURE_GREEN_TYPE_ARB': 0x8C11,
-  'TEXTURE_BLUE_TYPE_ARB': 0x8C12,
-  'TEXTURE_ALPHA_TYPE_ARB': 0x8C13,
-  'TEXTURE_LUMINANCE_TYPE_ARB': 0x8C14,
-  'TEXTURE_INTENSITY_TYPE_ARB': 0x8C15,
-  'TEXTURE_DEPTH_TYPE_ARB': 0x8C16,
-  'UNSIGNED_NORMALIZED_ARB': 0x8C17,
-  'MIRRORED_REPEAT_ARB': 0x8370,
-  'TEXTURE_RECTANGLE_ARB': 0x84F5,
-  'TEXTURE_BINDING_RECTANGLE_ARB': 0x84F6,
-  'PROXY_TEXTURE_RECTANGLE_ARB': 0x84F7,
-  'MAX_RECTANGLE_TEXTURE_SIZE_ARB': 0x84F8,
-  'SAMPLER_2D_RECT_ARB': 0x8B63,
-  'SAMPLER_2D_RECT_SHADOW_ARB': 0x8B64,
-  'RED': 0x1903,
-  'RG': 0x8227,
-  'RG_INTEGER': 0x8228,
-  'R8': 0x8229,
-  'R16': 0x822A,
-  'RG8': 0x822B,
-  'RG16': 0x822C,
-  'R16F': 0x822D,
-  'R32F': 0x822E,
-  'RG16F': 0x822F,
-  'RG32F': 0x8230,
-  'R8I': 0x8231,
-  'R8UI': 0x8232,
-  'R16I': 0x8233,
-  'R16UI': 0x8234,
-  'R32I': 0x8235,
-  'R32UI': 0x8236,
-  'RG8I': 0x8237,
-  'RG8UI': 0x8238,
-  'RG16I': 0x8239,
-  'RG16UI': 0x823A,
-  'RG32I': 0x823B,
-  'RG32UI': 0x823C,
-  'TRANSPOSE_MODELVIEW_MATRIX_ARB': 0x84E3,
-  'TRANSPOSE_PROJECTION_MATRIX_ARB': 0x84E4,
-  'TRANSPOSE_TEXTURE_MATRIX_ARB': 0x84E5,
-  'TRANSPOSE_COLOR_MATRIX_ARB': 0x84E6,
-  'VERTEX_ARRAY_BINDING': 0x85B5,
-  'MODELVIEW0_ARB': 0x1700,
-  'MODELVIEW1_ARB': 0x850A,
-  'MAX_VERTEX_UNITS_ARB': 0x86A4,
-  'ACTIVE_VERTEX_UNITS_ARB': 0x86A5,
-  'WEIGHT_SUM_UNITY_ARB': 0x86A6,
-  'VERTEX_BLEND_ARB': 0x86A7,
-  'CURRENT_WEIGHT_ARB': 0x86A8,
-  'WEIGHT_ARRAY_TYPE_ARB': 0x86A9,
-  'WEIGHT_ARRAY_STRIDE_ARB': 0x86AA,
-  'WEIGHT_ARRAY_SIZE_ARB': 0x86AB,
-  'WEIGHT_ARRAY_POINTER_ARB': 0x86AC,
-  'WEIGHT_ARRAY_ARB': 0x86AD,
-  'MODELVIEW2_ARB': 0x8722,
-  'MODELVIEW3_ARB': 0x8723,
-  'MODELVIEW4_ARB': 0x8724,
-  'MODELVIEW5_ARB': 0x8725,
-  'MODELVIEW6_ARB': 0x8726,
-  'MODELVIEW7_ARB': 0x8727,
-  'MODELVIEW8_ARB': 0x8728,
-  'MODELVIEW9_ARB': 0x8729,
-  'MODELVIEW10_ARB': 0x872A,
-  'MODELVIEW11_ARB': 0x872B,
-  'MODELVIEW12_ARB': 0x872C,
-  'MODELVIEW13_ARB': 0x872D,
-  'MODELVIEW14_ARB': 0x872E,
-  'MODELVIEW15_ARB': 0x872F,
-  'MODELVIEW16_ARB': 0x8730,
-  'MODELVIEW17_ARB': 0x8731,
-  'MODELVIEW18_ARB': 0x8732,
-  'MODELVIEW19_ARB': 0x8733,
-  'MODELVIEW20_ARB': 0x8734,
-  'MODELVIEW21_ARB': 0x8735,
-  'MODELVIEW22_ARB': 0x8736,
-  'MODELVIEW23_ARB': 0x8737,
-  'MODELVIEW24_ARB': 0x8738,
-  'MODELVIEW25_ARB': 0x8739,
-  'MODELVIEW26_ARB': 0x873A,
-  'MODELVIEW27_ARB': 0x873B,
-  'MODELVIEW28_ARB': 0x873C,
-  'MODELVIEW29_ARB': 0x873D,
-  'MODELVIEW30_ARB': 0x873E,
-  'MODELVIEW31_ARB': 0x873F,
-  'BUFFER_SIZE_ARB': 0x8764,
-  'BUFFER_USAGE_ARB': 0x8765,
-  'ARRAY_BUFFER_ARB': 0x8892,
-  'ELEMENT_ARRAY_BUFFER_ARB': 0x8893,
-  'ARRAY_BUFFER_BINDING_ARB': 0x8894,
-  'ELEMENT_ARRAY_BUFFER_BINDING_ARB': 0x8895,
-  'VERTEX_ARRAY_BUFFER_BINDING_ARB': 0x8896,
-  'NORMAL_ARRAY_BUFFER_BINDING_ARB': 0x8897,
-  'COLOR_ARRAY_BUFFER_BINDING_ARB': 0x8898,
-  'INDEX_ARRAY_BUFFER_BINDING_ARB': 0x8899,
-  'TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB': 0x889A,
-  'EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB': 0x889B,
-  'SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB': 0x889C,
-  'FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB': 0x889D,
-  'WEIGHT_ARRAY_BUFFER_BINDING_ARB': 0x889E,
-  'VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB': 0x889F,
-  'READ_ONLY_ARB': 0x88B8,
-  'WRITE_ONLY_ARB': 0x88B9,
-  'READ_WRITE_ARB': 0x88BA,
-  'BUFFER_ACCESS_ARB': 0x88BB,
-  'BUFFER_MAPPED_ARB': 0x88BC,
-  'BUFFER_MAP_POINTER_ARB': 0x88BD,
-  'STREAM_DRAW_ARB': 0x88E0,
-  'STREAM_READ_ARB': 0x88E1,
-  'STREAM_COPY_ARB': 0x88E2,
-  'STATIC_DRAW_ARB': 0x88E4,
-  'STATIC_READ_ARB': 0x88E5,
-  'STATIC_COPY_ARB': 0x88E6,
-  'DYNAMIC_DRAW_ARB': 0x88E8,
-  'DYNAMIC_READ_ARB': 0x88E9,
-  'DYNAMIC_COPY_ARB': 0x88EA,
-  'COLOR_SUM_ARB': 0x8458,
-  'VERTEX_PROGRAM_ARB': 0x8620,
-  'VERTEX_ATTRIB_ARRAY_ENABLED_ARB': 0x8622,
-  'VERTEX_ATTRIB_ARRAY_SIZE_ARB': 0x8623,
-  'VERTEX_ATTRIB_ARRAY_STRIDE_ARB': 0x8624,
-  'VERTEX_ATTRIB_ARRAY_TYPE_ARB': 0x8625,
-  'CURRENT_VERTEX_ATTRIB_ARB': 0x8626,
-  'PROGRAM_LENGTH_ARB': 0x8627,
-  'PROGRAM_STRING_ARB': 0x8628,
-  'MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB': 0x862E,
-  'MAX_PROGRAM_MATRICES_ARB': 0x862F,
-  'CURRENT_MATRIX_STACK_DEPTH_ARB': 0x8640,
-  'CURRENT_MATRIX_ARB': 0x8641,
-  'VERTEX_PROGRAM_POINT_SIZE_ARB': 0x8642,
-  'VERTEX_PROGRAM_TWO_SIDE_ARB': 0x8643,
-  'VERTEX_ATTRIB_ARRAY_POINTER_ARB': 0x8645,
-  'PROGRAM_ERROR_POSITION_ARB': 0x864B,
-  'PROGRAM_BINDING_ARB': 0x8677,
-  'MAX_VERTEX_ATTRIBS_ARB': 0x8869,
-  'VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB': 0x886A,
-  'PROGRAM_ERROR_STRING_ARB': 0x8874,
-  'PROGRAM_FORMAT_ASCII_ARB': 0x8875,
-  'PROGRAM_FORMAT_ARB': 0x8876,
-  'PROGRAM_INSTRUCTIONS_ARB': 0x88A0,
-  'MAX_PROGRAM_INSTRUCTIONS_ARB': 0x88A1,
-  'PROGRAM_NATIVE_INSTRUCTIONS_ARB': 0x88A2,
-  'MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB': 0x88A3,
-  'PROGRAM_TEMPORARIES_ARB': 0x88A4,
-  'MAX_PROGRAM_TEMPORARIES_ARB': 0x88A5,
-  'PROGRAM_NATIVE_TEMPORARIES_ARB': 0x88A6,
-  'MAX_PROGRAM_NATIVE_TEMPORARIES_ARB': 0x88A7,
-  'PROGRAM_PARAMETERS_ARB': 0x88A8,
-  'MAX_PROGRAM_PARAMETERS_ARB': 0x88A9,
-  'PROGRAM_NATIVE_PARAMETERS_ARB': 0x88AA,
-  'MAX_PROGRAM_NATIVE_PARAMETERS_ARB': 0x88AB,
-  'PROGRAM_ATTRIBS_ARB': 0x88AC,
-  'MAX_PROGRAM_ATTRIBS_ARB': 0x88AD,
-  'PROGRAM_NATIVE_ATTRIBS_ARB': 0x88AE,
-  'MAX_PROGRAM_NATIVE_ATTRIBS_ARB': 0x88AF,
-  'PROGRAM_ADDRESS_REGISTERS_ARB': 0x88B0,
-  'MAX_PROGRAM_ADDRESS_REGISTERS_ARB': 0x88B1,
-  'PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB': 0x88B2,
-  'MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB': 0x88B3,
-  'MAX_PROGRAM_LOCAL_PARAMETERS_ARB': 0x88B4,
-  'MAX_PROGRAM_ENV_PARAMETERS_ARB': 0x88B5,
-  'PROGRAM_UNDER_NATIVE_LIMITS_ARB': 0x88B6,
-  'TRANSPOSE_CURRENT_MATRIX_ARB': 0x88B7,
-  'MATRIX0_ARB': 0x88C0,
-  'MATRIX1_ARB': 0x88C1,
-  'MATRIX2_ARB': 0x88C2,
-  'MATRIX3_ARB': 0x88C3,
-  'MATRIX4_ARB': 0x88C4,
-  'MATRIX5_ARB': 0x88C5,
-  'MATRIX6_ARB': 0x88C6,
-  'MATRIX7_ARB': 0x88C7,
-  'MATRIX8_ARB': 0x88C8,
-  'MATRIX9_ARB': 0x88C9,
-  'MATRIX10_ARB': 0x88CA,
-  'MATRIX11_ARB': 0x88CB,
-  'MATRIX12_ARB': 0x88CC,
-  'MATRIX13_ARB': 0x88CD,
-  'MATRIX14_ARB': 0x88CE,
-  'MATRIX15_ARB': 0x88CF,
-  'MATRIX16_ARB': 0x88D0,
-  'MATRIX17_ARB': 0x88D1,
-  'MATRIX18_ARB': 0x88D2,
-  'MATRIX19_ARB': 0x88D3,
-  'MATRIX20_ARB': 0x88D4,
-  'MATRIX21_ARB': 0x88D5,
-  'MATRIX22_ARB': 0x88D6,
-  'MATRIX23_ARB': 0x88D7,
-  'MATRIX24_ARB': 0x88D8,
-  'MATRIX25_ARB': 0x88D9,
-  'MATRIX26_ARB': 0x88DA,
-  'MATRIX27_ARB': 0x88DB,
-  'MATRIX28_ARB': 0x88DC,
-  'MATRIX29_ARB': 0x88DD,
-  'MATRIX30_ARB': 0x88DE,
-  'MATRIX31_ARB': 0x88DF,
-  'VERTEX_SHADER_ARB': 0x8B31,
-  'MAX_VERTEX_UNIFORM_COMPONENTS_ARB': 0x8B4A,
-  'MAX_VARYING_FLOATS_ARB': 0x8B4B,
-  'MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB': 0x8B4C,
-  'MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB': 0x8B4D,
-  'OBJECT_ACTIVE_ATTRIBUTES_ARB': 0x8B89,
-  'OBJECT_ACTIVE_ATTRIBUTE_MAX_LENGTH_ARB': 0x8B8A,
-  'TEXTURE_POINT_MODE_ATIX': 0x60B0,
-  'TEXTURE_POINT_ONE_COORD_ATIX': 0x60B1,
-  'TEXTURE_POINT_SPRITE_ATIX': 0x60B2,
-  'POINT_SPRITE_CULL_MODE_ATIX': 0x60B3,
-  'POINT_SPRITE_CULL_CENTER_ATIX': 0x60B4,
-  'POINT_SPRITE_CULL_CLIP_ATIX': 0x60B5,
-  'MODULATE_ADD_ATIX': 0x8744,
-  'MODULATE_SIGNED_ADD_ATIX': 0x8745,
-  'MODULATE_SUBTRACT_ATIX': 0x8746,
-  'SECONDARY_COLOR_ATIX': 0x8747,
-  'TEXTURE_OUTPUT_RGB_ATIX': 0x8748,
-  'TEXTURE_OUTPUT_ALPHA_ATIX': 0x8749,
-  'OUTPUT_POINT_SIZE_ATIX': 0x610E,
-  'MAX_DRAW_BUFFERS_ATI': 0x8824,
-  'DRAW_BUFFER0_ATI': 0x8825,
-  'DRAW_BUFFER1_ATI': 0x8826,
-  'DRAW_BUFFER2_ATI': 0x8827,
-  'DRAW_BUFFER3_ATI': 0x8828,
-  'DRAW_BUFFER4_ATI': 0x8829,
-  'DRAW_BUFFER5_ATI': 0x882A,
-  'DRAW_BUFFER6_ATI': 0x882B,
-  'DRAW_BUFFER7_ATI': 0x882C,
-  'DRAW_BUFFER8_ATI': 0x882D,
-  'DRAW_BUFFER9_ATI': 0x882E,
-  'DRAW_BUFFER10_ATI': 0x882F,
-  'DRAW_BUFFER11_ATI': 0x8830,
-  'DRAW_BUFFER12_ATI': 0x8831,
-  'DRAW_BUFFER13_ATI': 0x8832,
-  'DRAW_BUFFER14_ATI': 0x8833,
-  'DRAW_BUFFER15_ATI': 0x8834,
-  'ELEMENT_ARRAY_ATI': 0x8768,
-  'ELEMENT_ARRAY_TYPE_ATI': 0x8769,
-  'ELEMENT_ARRAY_POINTER_ATI': 0x876A,
-  'BUMP_ROT_MATRIX_ATI': 0x8775,
-  'BUMP_ROT_MATRIX_SIZE_ATI': 0x8776,
-  'BUMP_NUM_TEX_UNITS_ATI': 0x8777,
-  'BUMP_TEX_UNITS_ATI': 0x8778,
-  'DUDV_ATI': 0x8779,
-  'DU8DV8_ATI': 0x877A,
-  'BUMP_ENVMAP_ATI': 0x877B,
-  'BUMP_TARGET_ATI': 0x877C,
-  'RED_BIT_ATI': 0x00000001,
-  '2X_BIT_ATI': 0x00000001,
-  '4X_BIT_ATI': 0x00000002,
-  'GREEN_BIT_ATI': 0x00000002,
-  'COMP_BIT_ATI': 0x00000002,
-  'BLUE_BIT_ATI': 0x00000004,
-  '8X_BIT_ATI': 0x00000004,
-  'NEGATE_BIT_ATI': 0x00000004,
-  'BIAS_BIT_ATI': 0x00000008,
-  'HALF_BIT_ATI': 0x00000008,
-  'QUARTER_BIT_ATI': 0x00000010,
-  'EIGHTH_BIT_ATI': 0x00000020,
-  'SATURATE_BIT_ATI': 0x00000040,
-  'FRAGMENT_SHADER_ATI': 0x8920,
-  'REG_0_ATI': 0x8921,
-  'REG_1_ATI': 0x8922,
-  'REG_2_ATI': 0x8923,
-  'REG_3_ATI': 0x8924,
-  'REG_4_ATI': 0x8925,
-  'REG_5_ATI': 0x8926,
-  'CON_0_ATI': 0x8941,
-  'CON_1_ATI': 0x8942,
-  'CON_2_ATI': 0x8943,
-  'CON_3_ATI': 0x8944,
-  'CON_4_ATI': 0x8945,
-  'CON_5_ATI': 0x8946,
-  'CON_6_ATI': 0x8947,
-  'CON_7_ATI': 0x8948,
-  'MOV_ATI': 0x8961,
-  'ADD_ATI': 0x8963,
-  'MUL_ATI': 0x8964,
-  'SUB_ATI': 0x8965,
-  'DOT3_ATI': 0x8966,
-  'DOT4_ATI': 0x8967,
-  'MAD_ATI': 0x8968,
-  'LERP_ATI': 0x8969,
-  'CND_ATI': 0x896A,
-  'CND0_ATI': 0x896B,
-  'DOT2_ADD_ATI': 0x896C,
-  'SECONDARY_INTERPOLATOR_ATI': 0x896D,
-  'NUM_FRAGMENT_REGISTERS_ATI': 0x896E,
-  'NUM_FRAGMENT_CONSTANTS_ATI': 0x896F,
-  'NUM_PASSES_ATI': 0x8970,
-  'NUM_INSTRUCTIONS_PER_PASS_ATI': 0x8971,
-  'NUM_INSTRUCTIONS_TOTAL_ATI': 0x8972,
-  'NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI': 0x8973,
-  'NUM_LOOPBACK_COMPONENTS_ATI': 0x8974,
-  'COLOR_ALPHA_PAIRING_ATI': 0x8975,
-  'SWIZZLE_STR_ATI': 0x8976,
-  'SWIZZLE_STQ_ATI': 0x8977,
-  'SWIZZLE_STR_DR_ATI': 0x8978,
-  'SWIZZLE_STQ_DQ_ATI': 0x8979,
-  'SWIZZLE_STRQ_ATI': 0x897A,
-  'SWIZZLE_STRQ_DQ_ATI': 0x897B,
-  'PN_TRIANGLES_ATI': 0x87F0,
-  'MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI': 0x87F1,
-  'PN_TRIANGLES_POINT_MODE_ATI': 0x87F2,
-  'PN_TRIANGLES_NORMAL_MODE_ATI': 0x87F3,
-  'PN_TRIANGLES_TESSELATION_LEVEL_ATI': 0x87F4,
-  'PN_TRIANGLES_POINT_MODE_LINEAR_ATI': 0x87F5,
-  'PN_TRIANGLES_POINT_MODE_CUBIC_ATI': 0x87F6,
-  'PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI': 0x87F7,
-  'PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI': 0x87F8,
-  'STENCIL_BACK_FUNC_ATI': 0x8800,
-  'STENCIL_BACK_FAIL_ATI': 0x8801,
-  'STENCIL_BACK_PASS_DEPTH_FAIL_ATI': 0x8802,
-  'STENCIL_BACK_PASS_DEPTH_PASS_ATI': 0x8803,
-  'TEXT_FRAGMENT_SHADER_ATI': 0x8200,
-  'COMPRESSED_LUMINANCE_ALPHA_3DC_ATI': 0x8837,
-  'MODULATE_ADD_ATI': 0x8744,
-  'MODULATE_SIGNED_ADD_ATI': 0x8745,
-  'MODULATE_SUBTRACT_ATI': 0x8746,
-  'RGBA_FLOAT32_ATI': 0x8814,
-  'RGB_FLOAT32_ATI': 0x8815,
-  'ALPHA_FLOAT32_ATI': 0x8816,
-  'INTENSITY_FLOAT32_ATI': 0x8817,
-  'LUMINANCE_FLOAT32_ATI': 0x8818,
-  'LUMINANCE_ALPHA_FLOAT32_ATI': 0x8819,
-  'RGBA_FLOAT16_ATI': 0x881A,
-  'RGB_FLOAT16_ATI': 0x881B,
-  'ALPHA_FLOAT16_ATI': 0x881C,
-  'INTENSITY_FLOAT16_ATI': 0x881D,
-  'LUMINANCE_FLOAT16_ATI': 0x881E,
-  'LUMINANCE_ALPHA_FLOAT16_ATI': 0x881F,
-  'MIRROR_CLAMP_ATI': 0x8742,
-  'MIRROR_CLAMP_TO_EDGE_ATI': 0x8743,
-  'STATIC_ATI': 0x8760,
-  'DYNAMIC_ATI': 0x8761,
-  'PRESERVE_ATI': 0x8762,
-  'DISCARD_ATI': 0x8763,
-  'OBJECT_BUFFER_SIZE_ATI': 0x8764,
-  'OBJECT_BUFFER_USAGE_ATI': 0x8765,
-  'ARRAY_OBJECT_BUFFER_ATI': 0x8766,
-  'ARRAY_OBJECT_OFFSET_ATI': 0x8767,
-  'MAX_VERTEX_STREAMS_ATI': 0x876B,
-  'VERTEX_SOURCE_ATI': 0x876C,
-  'VERTEX_STREAM0_ATI': 0x876D,
-  'VERTEX_STREAM1_ATI': 0x876E,
-  'VERTEX_STREAM2_ATI': 0x876F,
-  'VERTEX_STREAM3_ATI': 0x8770,
-  'VERTEX_STREAM4_ATI': 0x8771,
-  'VERTEX_STREAM5_ATI': 0x8772,
-  'VERTEX_STREAM6_ATI': 0x8773,
-  'VERTEX_STREAM7_ATI': 0x8774,
-  '422_EXT': 0x80CC,
-  '422_REV_EXT': 0x80CD,
-  '422_AVERAGE_EXT': 0x80CE,
-  '422_REV_AVERAGE_EXT': 0x80CF,
-  'CG_VERTEX_SHADER_EXT': 0x890E,
-  'CG_FRAGMENT_SHADER_EXT': 0x890F,
-  'ABGR_EXT': 0x8000,
-  'BGR_EXT': 0x80E0,
-  'BGRA_EXT': 0x80E1,
-  'MAX_VERTEX_BINDABLE_UNIFORMS_EXT': 0x8DE2,
-  'MAX_FRAGMENT_BINDABLE_UNIFORMS_EXT': 0x8DE3,
-  'MAX_GEOMETRY_BINDABLE_UNIFORMS_EXT': 0x8DE4,
-  'MAX_BINDABLE_UNIFORM_SIZE_EXT': 0x8DED,
-  'UNIFORM_BUFFER_EXT': 0x8DEE,
-  'UNIFORM_BUFFER_BINDING_EXT': 0x8DEF,
-  'CONSTANT_COLOR_EXT': 0x8001,
-  'ONE_MINUS_CONSTANT_COLOR_EXT': 0x8002,
-  'CONSTANT_ALPHA_EXT': 0x8003,
-  'ONE_MINUS_CONSTANT_ALPHA_EXT': 0x8004,
-  'BLEND_COLOR_EXT': 0x8005,
-  'BLEND_EQUATION_RGB_EXT': 0x8009,
-  'BLEND_EQUATION_ALPHA_EXT': 0x883D,
-  'BLEND_DST_RGB_EXT': 0x80C8,
-  'BLEND_SRC_RGB_EXT': 0x80C9,
-  'BLEND_DST_ALPHA_EXT': 0x80CA,
-  'BLEND_SRC_ALPHA_EXT': 0x80CB,
-  'FUNC_ADD_EXT': 0x8006,
-  'MIN_EXT': 0x8007,
-  'MAX_EXT': 0x8008,
-  'BLEND_EQUATION_EXT': 0x8009,
-  'FUNC_SUBTRACT_EXT': 0x800A,
-  'FUNC_REVERSE_SUBTRACT_EXT': 0x800B,
-  'CLIP_VOLUME_CLIPPING_HINT_EXT': 0x80F0,
-  'CMYK_EXT': 0x800C,
-  'CMYKA_EXT': 0x800D,
-  'PACK_CMYK_HINT_EXT': 0x800E,
-  'UNPACK_CMYK_HINT_EXT': 0x800F,
-  'ARRAY_ELEMENT_LOCK_FIRST_EXT': 0x81A8,
-  'ARRAY_ELEMENT_LOCK_COUNT_EXT': 0x81A9,
-  'CONVOLUTION_1D_EXT': 0x8010,
-  'CONVOLUTION_2D_EXT': 0x8011,
-  'SEPARABLE_2D_EXT': 0x8012,
-  'CONVOLUTION_BORDER_MODE_EXT': 0x8013,
-  'CONVOLUTION_FILTER_SCALE_EXT': 0x8014,
-  'CONVOLUTION_FILTER_BIAS_EXT': 0x8015,
-  'REDUCE_EXT': 0x8016,
-  'CONVOLUTION_FORMAT_EXT': 0x8017,
-  'CONVOLUTION_WIDTH_EXT': 0x8018,
-  'CONVOLUTION_HEIGHT_EXT': 0x8019,
-  'MAX_CONVOLUTION_WIDTH_EXT': 0x801A,
-  'MAX_CONVOLUTION_HEIGHT_EXT': 0x801B,
-  'POST_CONVOLUTION_RED_SCALE_EXT': 0x801C,
-  'POST_CONVOLUTION_GREEN_SCALE_EXT': 0x801D,
-  'POST_CONVOLUTION_BLUE_SCALE_EXT': 0x801E,
-  'POST_CONVOLUTION_ALPHA_SCALE_EXT': 0x801F,
-  'POST_CONVOLUTION_RED_BIAS_EXT': 0x8020,
-  'POST_CONVOLUTION_GREEN_BIAS_EXT': 0x8021,
-  'POST_CONVOLUTION_BLUE_BIAS_EXT': 0x8022,
-  'POST_CONVOLUTION_ALPHA_BIAS_EXT': 0x8023,
-  'TANGENT_ARRAY_EXT': 0x8439,
-  'BINORMAL_ARRAY_EXT': 0x843A,
-  'CURRENT_TANGENT_EXT': 0x843B,
-  'CURRENT_BINORMAL_EXT': 0x843C,
-  'TANGENT_ARRAY_TYPE_EXT': 0x843E,
-  'TANGENT_ARRAY_STRIDE_EXT': 0x843F,
-  'BINORMAL_ARRAY_TYPE_EXT': 0x8440,
-  'BINORMAL_ARRAY_STRIDE_EXT': 0x8441,
-  'TANGENT_ARRAY_POINTER_EXT': 0x8442,
-  'BINORMAL_ARRAY_POINTER_EXT': 0x8443,
-  'MAP1_TANGENT_EXT': 0x8444,
-  'MAP2_TANGENT_EXT': 0x8445,
-  'MAP1_BINORMAL_EXT': 0x8446,
-  'MAP2_BINORMAL_EXT': 0x8447,
-  'DEPTH_BOUNDS_TEST_EXT': 0x8890,
-  'DEPTH_BOUNDS_EXT': 0x8891,
-  'PROGRAM_MATRIX_EXT': 0x8E2D,
-  'TRANSPOSE_PROGRAM_MATRIX_EXT': 0x8E2E,
-  'PROGRAM_MATRIX_STACK_DEPTH_EXT': 0x8E2F,
-  'MAX_ELEMENTS_VERTICES': 0x80E8,
-  'MAX_ELEMENTS_INDICES': 0x80E9,
-  'FOG_COORDINATE_SOURCE_EXT': 0x8450,
-  'FOG_COORDINATE_EXT': 0x8451,
-  'FRAGMENT_DEPTH_EXT': 0x8452,
-  'CURRENT_FOG_COORDINATE_EXT': 0x8453,
-  'FOG_COORDINATE_ARRAY_TYPE_EXT': 0x8454,
-  'FOG_COORDINATE_ARRAY_STRIDE_EXT': 0x8455,
-  'FOG_COORDINATE_ARRAY_POINTER_EXT': 0x8456,
-  'FOG_COORDINATE_ARRAY_EXT': 0x8457,
-  'FRAGMENT_LIGHTING_EXT': 0x8400,
-  'FRAGMENT_COLOR_MATERIAL_EXT': 0x8401,
-  'FRAGMENT_COLOR_MATERIAL_FACE_EXT': 0x8402,
-  'FRAGMENT_COLOR_MATERIAL_PARAMETER_EXT': 0x8403,
-  'MAX_FRAGMENT_LIGHTS_EXT': 0x8404,
-  'MAX_ACTIVE_LIGHTS_EXT': 0x8405,
-  'CURRENT_RASTER_NORMAL_EXT': 0x8406,
-  'LIGHT_ENV_MODE_EXT': 0x8407,
-  'FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_EXT': 0x8408,
-  'FRAGMENT_LIGHT_MODEL_TWO_SIDE_EXT': 0x8409,
-  'FRAGMENT_LIGHT_MODEL_AMBIENT_EXT': 0x840A,
-  'FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_EXT': 0x840B,
-  'FRAGMENT_LIGHT0_EXT': 0x840C,
-  'FRAGMENT_LIGHT7_EXT': 0x8413,
-  'DRAW_FRAMEBUFFER_BINDING_EXT': 0x8CA6,
-  'READ_FRAMEBUFFER_EXT': 0x8CA8,
-  'DRAW_FRAMEBUFFER_EXT': 0x8CA9,
-  'READ_FRAMEBUFFER_BINDING_EXT': 0x8CAA,
-  'RENDERBUFFER_SAMPLES_EXT': 0x8CAB,
-  'FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT': 0x8D56,
-  'MAX_SAMPLES_EXT': 0x8D57,
-  'INVALID_FRAMEBUFFER_OPERATION_EXT': 0x0506,
-  'MAX_RENDERBUFFER_SIZE_EXT': 0x84E8,
-  'FRAMEBUFFER_BINDING_EXT': 0x8CA6,
-  'RENDERBUFFER_BINDING_EXT': 0x8CA7,
-  'FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_EXT': 0x8CD0,
-  'FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_EXT': 0x8CD1,
-  'FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_EXT': 0x8CD2,
-  'FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_EXT': 0x8CD3,
-  'FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_EXT': 0x8CD4,
-  'FRAMEBUFFER_COMPLETE_EXT': 0x8CD5,
-  'FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT': 0x8CD6,
-  'FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT': 0x8CD7,
-  'FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT': 0x8CD9,
-  'FRAMEBUFFER_INCOMPLETE_FORMATS_EXT': 0x8CDA,
-  'FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_EXT': 0x8CDB,
-  'FRAMEBUFFER_INCOMPLETE_READ_BUFFER_EXT': 0x8CDC,
-  'FRAMEBUFFER_UNSUPPORTED_EXT': 0x8CDD,
-  'MAX_COLOR_ATTACHMENTS_EXT': 0x8CDF,
-  'COLOR_ATTACHMENT0_EXT': 0x8CE0,
-  'COLOR_ATTACHMENT1_EXT': 0x8CE1,
-  'COLOR_ATTACHMENT2_EXT': 0x8CE2,
-  'COLOR_ATTACHMENT3_EXT': 0x8CE3,
-  'COLOR_ATTACHMENT4_EXT': 0x8CE4,
-  'COLOR_ATTACHMENT5_EXT': 0x8CE5,
-  'COLOR_ATTACHMENT6_EXT': 0x8CE6,
-  'COLOR_ATTACHMENT7_EXT': 0x8CE7,
-  'COLOR_ATTACHMENT8_EXT': 0x8CE8,
-  'COLOR_ATTACHMENT9_EXT': 0x8CE9,
-  'COLOR_ATTACHMENT10_EXT': 0x8CEA,
-  'COLOR_ATTACHMENT11_EXT': 0x8CEB,
-  'COLOR_ATTACHMENT12_EXT': 0x8CEC,
-  'COLOR_ATTACHMENT13_EXT': 0x8CED,
-  'COLOR_ATTACHMENT14_EXT': 0x8CEE,
-  'COLOR_ATTACHMENT15_EXT': 0x8CEF,
-  'DEPTH_ATTACHMENT_EXT': 0x8D00,
-  'STENCIL_ATTACHMENT_EXT': 0x8D20,
-  'FRAMEBUFFER_EXT': 0x8D40,
-  'RENDERBUFFER_EXT': 0x8D41,
-  'RENDERBUFFER_WIDTH_EXT': 0x8D42,
-  'RENDERBUFFER_HEIGHT_EXT': 0x8D43,
-  'RENDERBUFFER_INTERNAL_FORMAT_EXT': 0x8D44,
-  'STENCIL_INDEX1_EXT': 0x8D46,
-  'STENCIL_INDEX4_EXT': 0x8D47,
-  'STENCIL_INDEX8_EXT': 0x8D48,
-  'STENCIL_INDEX16_EXT': 0x8D49,
-  'RENDERBUFFER_RED_SIZE_EXT': 0x8D50,
-  'RENDERBUFFER_GREEN_SIZE_EXT': 0x8D51,
-  'RENDERBUFFER_BLUE_SIZE_EXT': 0x8D52,
-  'RENDERBUFFER_ALPHA_SIZE_EXT': 0x8D53,
-  'RENDERBUFFER_DEPTH_SIZE_EXT': 0x8D54,
-  'RENDERBUFFER_STENCIL_SIZE_EXT': 0x8D55,
-  'FRAMEBUFFER_SRGB_EXT': 0x8DB9,
-  'FRAMEBUFFER_SRGB_CAPABLE_EXT': 0x8DBA,
-  'LINES_ADJACENCY_EXT': 0xA,
-  'LINE_STRIP_ADJACENCY_EXT': 0xB,
-  'TRIANGLES_ADJACENCY_EXT': 0xC,
-  'TRIANGLE_STRIP_ADJACENCY_EXT': 0xD,
-  'PROGRAM_POINT_SIZE_EXT': 0x8642,
-  'MAX_VARYING_COMPONENTS_EXT': 0x8B4B,
-  'MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT': 0x8C29,
-  'FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT': 0x8CD4,
-  'FRAMEBUFFER_ATTACHMENT_LAYERED_EXT': 0x8DA7,
-  'FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT': 0x8DA8,
-  'FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT': 0x8DA9,
-  'GEOMETRY_SHADER_EXT': 0x8DD9,
-  'GEOMETRY_VERTICES_OUT_EXT': 0x8DDA,
-  'GEOMETRY_INPUT_TYPE_EXT': 0x8DDB,
-  'GEOMETRY_OUTPUT_TYPE_EXT': 0x8DDC,
-  'MAX_GEOMETRY_VARYING_COMPONENTS_EXT': 0x8DDD,
-  'MAX_VERTEX_VARYING_COMPONENTS_EXT': 0x8DDE,
-  'MAX_GEOMETRY_UNIFORM_COMPONENTS_EXT': 0x8DDF,
-  'MAX_GEOMETRY_OUTPUT_VERTICES_EXT': 0x8DE0,
-  'MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_EXT': 0x8DE1,
-  'VERTEX_ATTRIB_ARRAY_INTEGER_EXT': 0x88FD,
-  'SAMPLER_1D_ARRAY_EXT': 0x8DC0,
-  'SAMPLER_2D_ARRAY_EXT': 0x8DC1,
-  'SAMPLER_BUFFER_EXT': 0x8DC2,
-  'SAMPLER_1D_ARRAY_SHADOW_EXT': 0x8DC3,
-  'SAMPLER_2D_ARRAY_SHADOW_EXT': 0x8DC4,
-  'SAMPLER_CUBE_SHADOW_EXT': 0x8DC5,
-  'UNSIGNED_INT_VEC2_EXT': 0x8DC6,
-  'UNSIGNED_INT_VEC3_EXT': 0x8DC7,
-  'UNSIGNED_INT_VEC4_EXT': 0x8DC8,
-  'INT_SAMPLER_1D_EXT': 0x8DC9,
-  'INT_SAMPLER_2D_EXT': 0x8DCA,
-  'INT_SAMPLER_3D_EXT': 0x8DCB,
-  'INT_SAMPLER_CUBE_EXT': 0x8DCC,
-  'INT_SAMPLER_2D_RECT_EXT': 0x8DCD,
-  'INT_SAMPLER_1D_ARRAY_EXT': 0x8DCE,
-  'INT_SAMPLER_2D_ARRAY_EXT': 0x8DCF,
-  'INT_SAMPLER_BUFFER_EXT': 0x8DD0,
-  'UNSIGNED_INT_SAMPLER_1D_EXT': 0x8DD1,
-  'UNSIGNED_INT_SAMPLER_2D_EXT': 0x8DD2,
-  'UNSIGNED_INT_SAMPLER_3D_EXT': 0x8DD3,
-  'UNSIGNED_INT_SAMPLER_CUBE_EXT': 0x8DD4,
-  'UNSIGNED_INT_SAMPLER_2D_RECT_EXT': 0x8DD5,
-  'UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT': 0x8DD6,
-  'UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT': 0x8DD7,
-  'UNSIGNED_INT_SAMPLER_BUFFER_EXT': 0x8DD8,
-  'HISTOGRAM_EXT': 0x8024,
-  'PROXY_HISTOGRAM_EXT': 0x8025,
-  'HISTOGRAM_WIDTH_EXT': 0x8026,
-  'HISTOGRAM_FORMAT_EXT': 0x8027,
-  'HISTOGRAM_RED_SIZE_EXT': 0x8028,
-  'HISTOGRAM_GREEN_SIZE_EXT': 0x8029,
-  'HISTOGRAM_BLUE_SIZE_EXT': 0x802A,
-  'HISTOGRAM_ALPHA_SIZE_EXT': 0x802B,
-  'HISTOGRAM_LUMINANCE_SIZE_EXT': 0x802C,
-  'HISTOGRAM_SINK_EXT': 0x802D,
-  'MINMAX_EXT': 0x802E,
-  'MINMAX_FORMAT_EXT': 0x802F,
-  'MINMAX_SINK_EXT': 0x8030,
-  'FRAGMENT_MATERIAL_EXT': 0x8349,
-  'FRAGMENT_NORMAL_EXT': 0x834A,
-  'FRAGMENT_COLOR_EXT': 0x834C,
-  'ATTENUATION_EXT': 0x834D,
-  'SHADOW_ATTENUATION_EXT': 0x834E,
-  'TEXTURE_APPLICATION_MODE_EXT': 0x834F,
-  'TEXTURE_LIGHT_EXT': 0x8350,
-  'TEXTURE_MATERIAL_FACE_EXT': 0x8351,
-  'TEXTURE_MATERIAL_PARAMETER_EXT': 0x8352,
-  'FRAGMENT_DEPTH_EXT': 0x8452,
-  'MULTISAMPLE_EXT': 0x809D,
-  'SAMPLE_ALPHA_TO_MASK_EXT': 0x809E,
-  'SAMPLE_ALPHA_TO_ONE_EXT': 0x809F,
-  'SAMPLE_MASK_EXT': 0x80A0,
-  '1PASS_EXT': 0x80A1,
-  '2PASS_0_EXT': 0x80A2,
-  '2PASS_1_EXT': 0x80A3,
-  '4PASS_0_EXT': 0x80A4,
-  '4PASS_1_EXT': 0x80A5,
-  '4PASS_2_EXT': 0x80A6,
-  '4PASS_3_EXT': 0x80A7,
-  'SAMPLE_BUFFERS_EXT': 0x80A8,
-  'SAMPLES_EXT': 0x80A9,
-  'SAMPLE_MASK_VALUE_EXT': 0x80AA,
-  'SAMPLE_MASK_INVERT_EXT': 0x80AB,
-  'SAMPLE_PATTERN_EXT': 0x80AC,
-  'MULTISAMPLE_BIT_EXT': 0x20000000,
-  'DEPTH_STENCIL_EXT': 0x84F9,
-  'UNSIGNED_INT_24_8_EXT': 0x84FA,
-  'DEPTH24_STENCIL8_EXT': 0x88F0,
-  'TEXTURE_STENCIL_SIZE_EXT': 0x88F1,
-  'R11F_G11F_B10F_EXT': 0x8C3A,
-  'UNSIGNED_INT_10F_11F_11F_REV_EXT': 0x8C3B,
-  'RGBA_SIGNED_COMPONENTS_EXT': 0x8C3C,
-  'UNSIGNED_BYTE_3_3_2_EXT': 0x8032,
-  'UNSIGNED_SHORT_4_4_4_4_EXT': 0x8033,
-  'UNSIGNED_SHORT_5_5_5_1_EXT': 0x8034,
-  'UNSIGNED_INT_8_8_8_8_EXT': 0x8035,
-  'UNSIGNED_INT_10_10_10_2_EXT': 0x8036,
-  'TEXTURE_1D': 0x0DE0,
-  'TEXTURE_2D': 0x0DE1,
-  'PROXY_TEXTURE_1D': 0x8063,
-  'PROXY_TEXTURE_2D': 0x8064,
-  'TEXTURE_3D_EXT': 0x806F,
-  'PROXY_TEXTURE_3D_EXT': 0x8070,
-  'COLOR_TABLE_FORMAT_EXT': 0x80D8,
-  'COLOR_TABLE_WIDTH_EXT': 0x80D9,
-  'COLOR_TABLE_RED_SIZE_EXT': 0x80DA,
-  'COLOR_TABLE_GREEN_SIZE_EXT': 0x80DB,
-  'COLOR_TABLE_BLUE_SIZE_EXT': 0x80DC,
-  'COLOR_TABLE_ALPHA_SIZE_EXT': 0x80DD,
-  'COLOR_TABLE_LUMINANCE_SIZE_EXT': 0x80DE,
-  'COLOR_TABLE_INTENSITY_SIZE_EXT': 0x80DF,
-  'COLOR_INDEX1_EXT': 0x80E2,
-  'COLOR_INDEX2_EXT': 0x80E3,
-  'COLOR_INDEX4_EXT': 0x80E4,
-  'COLOR_INDEX8_EXT': 0x80E5,
-  'COLOR_INDEX12_EXT': 0x80E6,
-  'COLOR_INDEX16_EXT': 0x80E7,
-  'TEXTURE_INDEX_SIZE_EXT': 0x80ED,
-  'TEXTURE_CUBE_MAP_ARB': 0x8513,
-  'PROXY_TEXTURE_CUBE_MAP_ARB': 0x851B,
-  'PIXEL_PACK_BUFFER_EXT': 0x88EB,
-  'PIXEL_UNPACK_BUFFER_EXT': 0x88EC,
-  'PIXEL_PACK_BUFFER_BINDING_EXT': 0x88ED,
-  'PIXEL_UNPACK_BUFFER_BINDING_EXT': 0x88EF,
-  'PIXEL_TRANSFORM_2D_EXT': 0x8330,
-  'PIXEL_MAG_FILTER_EXT': 0x8331,
-  'PIXEL_MIN_FILTER_EXT': 0x8332,
-  'PIXEL_CUBIC_WEIGHT_EXT': 0x8333,
-  'CUBIC_EXT': 0x8334,
-  'AVERAGE_EXT': 0x8335,
-  'PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT': 0x8336,
-  'MAX_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT': 0x8337,
-  'PIXEL_TRANSFORM_2D_MATRIX_EXT': 0x8338,
-  'POINT_SIZE_MIN_EXT': 0x8126,
-  'POINT_SIZE_MAX_EXT': 0x8127,
-  'POINT_FADE_THRESHOLD_SIZE_EXT': 0x8128,
-  'DISTANCE_ATTENUATION_EXT': 0x8129,
-  'POLYGON_OFFSET_EXT': 0x8037,
-  'POLYGON_OFFSET_FACTOR_EXT': 0x8038,
-  'POLYGON_OFFSET_BIAS_EXT': 0x8039,
-  'RESCALE_NORMAL_EXT': 0x803A,
-  'COLOR_SUM_EXT': 0x8458,
-  'CURRENT_SECONDARY_COLOR_EXT': 0x8459,
-  'SECONDARY_COLOR_ARRAY_SIZE_EXT': 0x845A,
-  'SECONDARY_COLOR_ARRAY_TYPE_EXT': 0x845B,
-  'SECONDARY_COLOR_ARRAY_STRIDE_EXT': 0x845C,
-  'SECONDARY_COLOR_ARRAY_POINTER_EXT': 0x845D,
-  'SECONDARY_COLOR_ARRAY_EXT': 0x845E,
-  'LIGHT_MODEL_COLOR_CONTROL_EXT': 0x81F8,
-  'SINGLE_COLOR_EXT': 0x81F9,
-  'SEPARATE_SPECULAR_COLOR_EXT': 0x81FA,
-  'SHARED_TEXTURE_PALETTE_EXT': 0x81FB,
-  'STENCIL_TAG_BITS_EXT': 0x88F2,
-  'STENCIL_CLEAR_TAG_VALUE_EXT': 0x88F3,
-  'STENCIL_TEST_TWO_SIDE_EXT': 0x8910,
-  'ACTIVE_STENCIL_FACE_EXT': 0x8911,
-  'INCR_WRAP_EXT': 0x8507,
-  'DECR_WRAP_EXT': 0x8508,
-  'ALPHA4_EXT': 0x803B,
-  'ALPHA8_EXT': 0x803C,
-  'ALPHA12_EXT': 0x803D,
-  'ALPHA16_EXT': 0x803E,
-  'LUMINANCE4_EXT': 0x803F,
-  'LUMINANCE8_EXT': 0x8040,
-  'LUMINANCE12_EXT': 0x8041,
-  'LUMINANCE16_EXT': 0x8042,
-  'LUMINANCE4_ALPHA4_EXT': 0x8043,
-  'LUMINANCE6_ALPHA2_EXT': 0x8044,
-  'LUMINANCE8_ALPHA8_EXT': 0x8045,
-  'LUMINANCE12_ALPHA4_EXT': 0x8046,
-  'LUMINANCE12_ALPHA12_EXT': 0x8047,
-  'LUMINANCE16_ALPHA16_EXT': 0x8048,
-  'INTENSITY_EXT': 0x8049,
-  'INTENSITY4_EXT': 0x804A,
-  'INTENSITY8_EXT': 0x804B,
-  'INTENSITY12_EXT': 0x804C,
-  'INTENSITY16_EXT': 0x804D,
-  'RGB2_EXT': 0x804E,
-  'RGB4_EXT': 0x804F,
-  'RGB5_EXT': 0x8050,
-  'RGB8_EXT': 0x8051,
-  'RGB10_EXT': 0x8052,
-  'RGB12_EXT': 0x8053,
-  'RGB16_EXT': 0x8054,
-  'RGBA2_EXT': 0x8055,
-  'RGBA4_EXT': 0x8056,
-  'RGB5_A1_EXT': 0x8057,
-  'RGBA8_EXT': 0x8058,
-  'RGB10_A2_EXT': 0x8059,
-  'RGBA12_EXT': 0x805A,
-  'RGBA16_EXT': 0x805B,
-  'TEXTURE_RED_SIZE_EXT': 0x805C,
-  'TEXTURE_GREEN_SIZE_EXT': 0x805D,
-  'TEXTURE_BLUE_SIZE_EXT': 0x805E,
-  'TEXTURE_ALPHA_SIZE_EXT': 0x805F,
-  'TEXTURE_LUMINANCE_SIZE_EXT': 0x8060,
-  'TEXTURE_INTENSITY_SIZE_EXT': 0x8061,
-  'REPLACE_EXT': 0x8062,
-  'PROXY_TEXTURE_1D_EXT': 0x8063,
-  'PROXY_TEXTURE_2D_EXT': 0x8064,
-  'PACK_SKIP_IMAGES_EXT': 0x806B,
-  'PACK_IMAGE_HEIGHT_EXT': 0x806C,
-  'UNPACK_SKIP_IMAGES_EXT': 0x806D,
-  'UNPACK_IMAGE_HEIGHT_EXT': 0x806E,
-  'TEXTURE_3D_EXT': 0x806F,
-  'PROXY_TEXTURE_3D_EXT': 0x8070,
-  'TEXTURE_DEPTH_EXT': 0x8071,
-  'TEXTURE_WRAP_R_EXT': 0x8072,
-  'MAX_3D_TEXTURE_SIZE_EXT': 0x8073,
-  'COMPARE_REF_DEPTH_TO_TEXTURE_EXT': 0x884E,
-  'MAX_ARRAY_TEXTURE_LAYERS_EXT': 0x88FF,
-  'TEXTURE_1D_ARRAY_EXT': 0x8C18,
-  'PROXY_TEXTURE_1D_ARRAY_EXT': 0x8C19,
-  'TEXTURE_2D_ARRAY_EXT': 0x8C1A,
-  'PROXY_TEXTURE_2D_ARRAY_EXT': 0x8C1B,
-  'TEXTURE_BINDING_1D_ARRAY_EXT': 0x8C1C,
-  'TEXTURE_BINDING_2D_ARRAY_EXT': 0x8C1D,
-  'TEXTURE_BUFFER_EXT': 0x8C2A,
-  'MAX_TEXTURE_BUFFER_SIZE_EXT': 0x8C2B,
-  'TEXTURE_BINDING_BUFFER_EXT': 0x8C2C,
-  'TEXTURE_BUFFER_DATA_STORE_BINDING_EXT': 0x8C2D,
-  'TEXTURE_BUFFER_FORMAT_EXT': 0x8C2E,
-  'COMPRESSED_RGB_S3TC_DXT1_EXT': 0x83F0,
-  'COMPRESSED_RGBA_S3TC_DXT1_EXT': 0x83F1,
-  'COMPRESSED_LUMINANCE_LATC1_EXT': 0x8C70,
-  'COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT': 0x8C71,
-  'COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT': 0x8C72,
-  'COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT': 0x8C73,
-  'COMPRESSED_RED_RGTC1_EXT': 0x8DBB,
-  'COMPRESSED_SIGNED_RED_RGTC1_EXT': 0x8DBC,
-  'COMPRESSED_RED_GREEN_RGTC2_EXT': 0x8DBD,
-  'COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT': 0x8DBE,
-  'COMPRESSED_RGB_S3TC_DXT1_EXT': 0x83F0,
-  'COMPRESSED_RGBA_S3TC_DXT1_EXT': 0x83F1,
-  'COMPRESSED_RGBA_S3TC_DXT3_EXT': 0x83F2,
-  'COMPRESSED_RGBA_S3TC_DXT5_EXT': 0x83F3,
-  'NORMAL_MAP_EXT': 0x8511,
-  'REFLECTION_MAP_EXT': 0x8512,
-  'TEXTURE_CUBE_MAP_EXT': 0x8513,
-  'TEXTURE_BINDING_CUBE_MAP_EXT': 0x8514,
-  'TEXTURE_CUBE_MAP_POSITIVE_X_EXT': 0x8515,
-  'TEXTURE_CUBE_MAP_NEGATIVE_X_EXT': 0x8516,
-  'TEXTURE_CUBE_MAP_POSITIVE_Y_EXT': 0x8517,
-  'TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT': 0x8518,
-  'TEXTURE_CUBE_MAP_POSITIVE_Z_EXT': 0x8519,
-  'TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT': 0x851A,
-  'PROXY_TEXTURE_CUBE_MAP_EXT': 0x851B,
-  'MAX_CUBE_MAP_TEXTURE_SIZE_EXT': 0x851C,
-  'CLAMP_TO_EDGE_EXT': 0x812F,
-  'COMBINE_EXT': 0x8570,
-  'COMBINE_RGB_EXT': 0x8571,
-  'COMBINE_ALPHA_EXT': 0x8572,
-  'RGB_SCALE_EXT': 0x8573,
-  'ADD_SIGNED_EXT': 0x8574,
-  'INTERPOLATE_EXT': 0x8575,
-  'CONSTANT_EXT': 0x8576,
-  'PRIMARY_COLOR_EXT': 0x8577,
-  'PREVIOUS_EXT': 0x8578,
-  'SOURCE0_RGB_EXT': 0x8580,
-  'SOURCE1_RGB_EXT': 0x8581,
-  'SOURCE2_RGB_EXT': 0x8582,
-  'SOURCE0_ALPHA_EXT': 0x8588,
-  'SOURCE1_ALPHA_EXT': 0x8589,
-  'SOURCE2_ALPHA_EXT': 0x858A,
-  'OPERAND0_RGB_EXT': 0x8590,
-  'OPERAND1_RGB_EXT': 0x8591,
-  'OPERAND2_RGB_EXT': 0x8592,
-  'OPERAND0_ALPHA_EXT': 0x8598,
-  'OPERAND1_ALPHA_EXT': 0x8599,
-  'OPERAND2_ALPHA_EXT': 0x859A,
-  'DOT3_RGB_EXT': 0x8740,
-  'DOT3_RGBA_EXT': 0x8741,
-  'TEXTURE_MAX_ANISOTROPY_EXT': 0x84FE,
-  'MAX_TEXTURE_MAX_ANISOTROPY_EXT': 0x84FF,
-  'RGBA32UI_EXT': 0x8D70,
-  'RGB32UI_EXT': 0x8D71,
-  'ALPHA32UI_EXT': 0x8D72,
-  'INTENSITY32UI_EXT': 0x8D73,
-  'LUMINANCE32UI_EXT': 0x8D74,
-  'LUMINANCE_ALPHA32UI_EXT': 0x8D75,
-  'RGBA16UI_EXT': 0x8D76,
-  'RGB16UI_EXT': 0x8D77,
-  'ALPHA16UI_EXT': 0x8D78,
-  'INTENSITY16UI_EXT': 0x8D79,
-  'LUMINANCE16UI_EXT': 0x8D7A,
-  'LUMINANCE_ALPHA16UI_EXT': 0x8D7B,
-  'RGBA8UI_EXT': 0x8D7C,
-  'RGB8UI_EXT': 0x8D7D,
-  'ALPHA8UI_EXT': 0x8D7E,
-  'INTENSITY8UI_EXT': 0x8D7F,
-  'LUMINANCE8UI_EXT': 0x8D80,
-  'LUMINANCE_ALPHA8UI_EXT': 0x8D81,
-  'RGBA32I_EXT': 0x8D82,
-  'RGB32I_EXT': 0x8D83,
-  'ALPHA32I_EXT': 0x8D84,
-  'INTENSITY32I_EXT': 0x8D85,
-  'LUMINANCE32I_EXT': 0x8D86,
-  'LUMINANCE_ALPHA32I_EXT': 0x8D87,
-  'RGBA16I_EXT': 0x8D88,
-  'RGB16I_EXT': 0x8D89,
-  'ALPHA16I_EXT': 0x8D8A,
-  'INTENSITY16I_EXT': 0x8D8B,
-  'LUMINANCE16I_EXT': 0x8D8C,
-  'LUMINANCE_ALPHA16I_EXT': 0x8D8D,
-  'RGBA8I_EXT': 0x8D8E,
-  'RGB8I_EXT': 0x8D8F,
-  'ALPHA8I_EXT': 0x8D90,
-  'INTENSITY8I_EXT': 0x8D91,
-  'LUMINANCE8I_EXT': 0x8D92,
-  'LUMINANCE_ALPHA8I_EXT': 0x8D93,
-  'RED_INTEGER_EXT': 0x8D94,
-  'GREEN_INTEGER_EXT': 0x8D95,
-  'BLUE_INTEGER_EXT': 0x8D96,
-  'ALPHA_INTEGER_EXT': 0x8D97,
-  'RGB_INTEGER_EXT': 0x8D98,
-  'RGBA_INTEGER_EXT': 0x8D99,
-  'BGR_INTEGER_EXT': 0x8D9A,
-  'BGRA_INTEGER_EXT': 0x8D9B,
-  'LUMINANCE_INTEGER_EXT': 0x8D9C,
-  'LUMINANCE_ALPHA_INTEGER_EXT': 0x8D9D,
-  'RGBA_INTEGER_MODE_EXT': 0x8D9E,
-  'MAX_TEXTURE_LOD_BIAS_EXT': 0x84FD,
-  'TEXTURE_FILTER_CONTROL_EXT': 0x8500,
-  'TEXTURE_LOD_BIAS_EXT': 0x8501,
-  'MIRROR_CLAMP_EXT': 0x8742,
-  'MIRROR_CLAMP_TO_EDGE_EXT': 0x8743,
-  'MIRROR_CLAMP_TO_BORDER_EXT': 0x8912,
-  'TEXTURE_PRIORITY_EXT': 0x8066,
-  'TEXTURE_RESIDENT_EXT': 0x8067,
-  'TEXTURE_1D_BINDING_EXT': 0x8068,
-  'TEXTURE_2D_BINDING_EXT': 0x8069,
-  'TEXTURE_3D_BINDING_EXT': 0x806A,
-  'PERTURB_EXT': 0x85AE,
-  'TEXTURE_NORMAL_EXT': 0x85AF,
-  'TEXTURE_RECTANGLE_EXT': 0x84F5,
-  'TEXTURE_BINDING_RECTANGLE_EXT': 0x84F6,
-  'PROXY_TEXTURE_RECTANGLE_EXT': 0x84F7,
-  'MAX_RECTANGLE_TEXTURE_SIZE_EXT': 0x84F8,
-  'SRGB_EXT': 0x8C40,
-  'SRGB8_EXT': 0x8C41,
-  'SRGB_ALPHA_EXT': 0x8C42,
-  'SRGB8_ALPHA8_EXT': 0x8C43,
-  'SLUMINANCE_ALPHA_EXT': 0x8C44,
-  'SLUMINANCE8_ALPHA8_EXT': 0x8C45,
-  'SLUMINANCE_EXT': 0x8C46,
-  'SLUMINANCE8_EXT': 0x8C47,
-  'COMPRESSED_SRGB_EXT': 0x8C48,
-  'COMPRESSED_SRGB_ALPHA_EXT': 0x8C49,
-  'COMPRESSED_SLUMINANCE_EXT': 0x8C4A,
-  'COMPRESSED_SLUMINANCE_ALPHA_EXT': 0x8C4B,
-  'COMPRESSED_SRGB_S3TC_DXT1_EXT': 0x8C4C,
-  'COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT': 0x8C4D,
-  'COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT': 0x8C4E,
-  'COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT': 0x8C4F,
-  'RGB9_E5_EXT': 0x8C3D,
-  'UNSIGNED_INT_5_9_9_9_REV_EXT': 0x8C3E,
-  'TEXTURE_SHARED_SIZE_EXT': 0x8C3F,
-  'TEXTURE_SWIZZLE_R_EXT': 0x8E42,
-  'TEXTURE_SWIZZLE_G_EXT': 0x8E43,
-  'TEXTURE_SWIZZLE_B_EXT': 0x8E44,
-  'TEXTURE_SWIZZLE_A_EXT': 0x8E45,
-  'TEXTURE_SWIZZLE_RGBA_EXT': 0x8E46,
-  'TIME_ELAPSED_EXT': 0x88BF,
-  'TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH_EXT': 0x8C76,
-  'TRANSFORM_FEEDBACK_BUFFER_MODE_EXT': 0x8C7F,
-  'MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_EXT': 0x8C80,
-  'TRANSFORM_FEEDBACK_VARYINGS_EXT': 0x8C83,
-  'TRANSFORM_FEEDBACK_BUFFER_START_EXT': 0x8C84,
-  'TRANSFORM_FEEDBACK_BUFFER_SIZE_EXT': 0x8C85,
-  'PRIMITIVES_GENERATED_EXT': 0x8C87,
-  'TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_EXT': 0x8C88,
-  'RASTERIZER_DISCARD_EXT': 0x8C89,
-  'MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_EXT': 0x8C8A,
-  'MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_EXT': 0x8C8B,
-  'INTERLEAVED_ATTRIBS_EXT': 0x8C8C,
-  'SEPARATE_ATTRIBS_EXT': 0x8C8D,
-  'TRANSFORM_FEEDBACK_BUFFER_EXT': 0x8C8E,
-  'TRANSFORM_FEEDBACK_BUFFER_BINDING_EXT': 0x8C8F,
-  'DOUBLE_EXT': 0x140A,
-  'VERTEX_ARRAY_EXT': 0x8074,
-  'NORMAL_ARRAY_EXT': 0x8075,
-  'COLOR_ARRAY_EXT': 0x8076,
-  'INDEX_ARRAY_EXT': 0x8077,
-  'TEXTURE_COORD_ARRAY_EXT': 0x8078,
-  'EDGE_FLAG_ARRAY_EXT': 0x8079,
-  'VERTEX_ARRAY_SIZE_EXT': 0x807A,
-  'VERTEX_ARRAY_TYPE_EXT': 0x807B,
-  'VERTEX_ARRAY_STRIDE_EXT': 0x807C,
-  'VERTEX_ARRAY_COUNT_EXT': 0x807D,
-  'NORMAL_ARRAY_TYPE_EXT': 0x807E,
-  'NORMAL_ARRAY_STRIDE_EXT': 0x807F,
-  'NORMAL_ARRAY_COUNT_EXT': 0x8080,
-  'COLOR_ARRAY_SIZE_EXT': 0x8081,
-  'COLOR_ARRAY_TYPE_EXT': 0x8082,
-  'COLOR_ARRAY_STRIDE_EXT': 0x8083,
-  'COLOR_ARRAY_COUNT_EXT': 0x8084,
-  'INDEX_ARRAY_TYPE_EXT': 0x8085,
-  'INDEX_ARRAY_STRIDE_EXT': 0x8086,
-  'INDEX_ARRAY_COUNT_EXT': 0x8087,
-  'TEXTURE_COORD_ARRAY_SIZE_EXT': 0x8088,
-  'TEXTURE_COORD_ARRAY_TYPE_EXT': 0x8089,
-  'TEXTURE_COORD_ARRAY_STRIDE_EXT': 0x808A,
-  'TEXTURE_COORD_ARRAY_COUNT_EXT': 0x808B,
-  'EDGE_FLAG_ARRAY_STRIDE_EXT': 0x808C,
-  'EDGE_FLAG_ARRAY_COUNT_EXT': 0x808D,
-  'VERTEX_ARRAY_POINTER_EXT': 0x808E,
-  'NORMAL_ARRAY_POINTER_EXT': 0x808F,
-  'COLOR_ARRAY_POINTER_EXT': 0x8090,
-  'INDEX_ARRAY_POINTER_EXT': 0x8091,
-  'TEXTURE_COORD_ARRAY_POINTER_EXT': 0x8092,
-  'EDGE_FLAG_ARRAY_POINTER_EXT': 0x8093,
-  'BGRA': 0x80E1,
-  'VERTEX_SHADER_EXT': 0x8780,
-  'VERTEX_SHADER_BINDING_EXT': 0x8781,
-  'OP_INDEX_EXT': 0x8782,
-  'OP_NEGATE_EXT': 0x8783,
-  'OP_DOT3_EXT': 0x8784,
-  'OP_DOT4_EXT': 0x8785,
-  'OP_MUL_EXT': 0x8786,
-  'OP_ADD_EXT': 0x8787,
-  'OP_MADD_EXT': 0x8788,
-  'OP_FRAC_EXT': 0x8789,
-  'OP_MAX_EXT': 0x878A,
-  'OP_MIN_EXT': 0x878B,
-  'OP_SET_GE_EXT': 0x878C,
-  'OP_SET_LT_EXT': 0x878D,
-  'OP_CLAMP_EXT': 0x878E,
-  'OP_FLOOR_EXT': 0x878F,
-  'OP_ROUND_EXT': 0x8790,
-  'OP_EXP_BASE_2_EXT': 0x8791,
-  'OP_LOG_BASE_2_EXT': 0x8792,
-  'OP_POWER_EXT': 0x8793,
-  'OP_RECIP_EXT': 0x8794,
-  'OP_RECIP_SQRT_EXT': 0x8795,
-  'OP_SUB_EXT': 0x8796,
-  'OP_CROSS_PRODUCT_EXT': 0x8797,
-  'OP_MULTIPLY_MATRIX_EXT': 0x8798,
-  'OP_MOV_EXT': 0x8799,
-  'OUTPUT_VERTEX_EXT': 0x879A,
-  'OUTPUT_COLOR0_EXT': 0x879B,
-  'OUTPUT_COLOR1_EXT': 0x879C,
-  'OUTPUT_TEXTURE_COORD0_EXT': 0x879D,
-  'OUTPUT_TEXTURE_COORD1_EXT': 0x879E,
-  'OUTPUT_TEXTURE_COORD2_EXT': 0x879F,
-  'OUTPUT_TEXTURE_COORD3_EXT': 0x87A0,
-  'OUTPUT_TEXTURE_COORD4_EXT': 0x87A1,
-  'OUTPUT_TEXTURE_COORD5_EXT': 0x87A2,
-  'OUTPUT_TEXTURE_COORD6_EXT': 0x87A3,
-  'OUTPUT_TEXTURE_COORD7_EXT': 0x87A4,
-  'OUTPUT_TEXTURE_COORD8_EXT': 0x87A5,
-  'OUTPUT_TEXTURE_COORD9_EXT': 0x87A6,
-  'OUTPUT_TEXTURE_COORD10_EXT': 0x87A7,
-  'OUTPUT_TEXTURE_COORD11_EXT': 0x87A8,
-  'OUTPUT_TEXTURE_COORD12_EXT': 0x87A9,
-  'OUTPUT_TEXTURE_COORD13_EXT': 0x87AA,
-  'OUTPUT_TEXTURE_COORD14_EXT': 0x87AB,
-  'OUTPUT_TEXTURE_COORD15_EXT': 0x87AC,
-  'OUTPUT_TEXTURE_COORD16_EXT': 0x87AD,
-  'OUTPUT_TEXTURE_COORD17_EXT': 0x87AE,
-  'OUTPUT_TEXTURE_COORD18_EXT': 0x87AF,
-  'OUTPUT_TEXTURE_COORD19_EXT': 0x87B0,
-  'OUTPUT_TEXTURE_COORD20_EXT': 0x87B1,
-  'OUTPUT_TEXTURE_COORD21_EXT': 0x87B2,
-  'OUTPUT_TEXTURE_COORD22_EXT': 0x87B3,
-  'OUTPUT_TEXTURE_COORD23_EXT': 0x87B4,
-  'OUTPUT_TEXTURE_COORD24_EXT': 0x87B5,
-  'OUTPUT_TEXTURE_COORD25_EXT': 0x87B6,
-  'OUTPUT_TEXTURE_COORD26_EXT': 0x87B7,
-  'OUTPUT_TEXTURE_COORD27_EXT': 0x87B8,
-  'OUTPUT_TEXTURE_COORD28_EXT': 0x87B9,
-  'OUTPUT_TEXTURE_COORD29_EXT': 0x87BA,
-  'OUTPUT_TEXTURE_COORD30_EXT': 0x87BB,
-  'OUTPUT_TEXTURE_COORD31_EXT': 0x87BC,
-  'OUTPUT_FOG_EXT': 0x87BD,
-  'SCALAR_EXT': 0x87BE,
-  'VECTOR_EXT': 0x87BF,
-  'MATRIX_EXT': 0x87C0,
-  'VARIANT_EXT': 0x87C1,
-  'INVARIANT_EXT': 0x87C2,
-  'LOCAL_CONSTANT_EXT': 0x87C3,
-  'LOCAL_EXT': 0x87C4,
-  'MAX_VERTEX_SHADER_INSTRUCTIONS_EXT': 0x87C5,
-  'MAX_VERTEX_SHADER_VARIANTS_EXT': 0x87C6,
-  'MAX_VERTEX_SHADER_INVARIANTS_EXT': 0x87C7,
-  'MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT': 0x87C8,
-  'MAX_VERTEX_SHADER_LOCALS_EXT': 0x87C9,
-  'MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT': 0x87CA,
-  'MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT': 0x87CB,
-  'MAX_OPTIMIZED_VERTEX_SHADER_INVARIANTS_EXT': 0x87CC,
-  'MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT': 0x87CD,
-  'MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT': 0x87CE,
-  'VERTEX_SHADER_INSTRUCTIONS_EXT': 0x87CF,
-  'VERTEX_SHADER_VARIANTS_EXT': 0x87D0,
-  'VERTEX_SHADER_INVARIANTS_EXT': 0x87D1,
-  'VERTEX_SHADER_LOCAL_CONSTANTS_EXT': 0x87D2,
-  'VERTEX_SHADER_LOCALS_EXT': 0x87D3,
-  'VERTEX_SHADER_OPTIMIZED_EXT': 0x87D4,
-  'X_EXT': 0x87D5,
-  'Y_EXT': 0x87D6,
-  'Z_EXT': 0x87D7,
-  'W_EXT': 0x87D8,
-  'NEGATIVE_X_EXT': 0x87D9,
-  'NEGATIVE_Y_EXT': 0x87DA,
-  'NEGATIVE_Z_EXT': 0x87DB,
-  'NEGATIVE_W_EXT': 0x87DC,
-  'ZERO_EXT': 0x87DD,
-  'ONE_EXT': 0x87DE,
-  'NEGATIVE_ONE_EXT': 0x87DF,
-  'NORMALIZED_RANGE_EXT': 0x87E0,
-  'FULL_RANGE_EXT': 0x87E1,
-  'CURRENT_VERTEX_EXT': 0x87E2,
-  'MVP_MATRIX_EXT': 0x87E3,
-  'VARIANT_VALUE_EXT': 0x87E4,
-  'VARIANT_DATATYPE_EXT': 0x87E5,
-  'VARIANT_ARRAY_STRIDE_EXT': 0x87E6,
-  'VARIANT_ARRAY_TYPE_EXT': 0x87E7,
-  'VARIANT_ARRAY_EXT': 0x87E8,
-  'VARIANT_ARRAY_POINTER_EXT': 0x87E9,
-  'INVARIANT_VALUE_EXT': 0x87EA,
-  'INVARIANT_DATATYPE_EXT': 0x87EB,
-  'LOCAL_CONSTANT_VALUE_EXT': 0x87EC,
-  'LOCAL_CONSTANT_DATATYPE_EXT': 0x87ED,
-  'MODELVIEW0_STACK_DEPTH_EXT': 0x0BA3,
-  'MODELVIEW0_MATRIX_EXT': 0x0BA6,
-  'MODELVIEW0_EXT': 0x1700,
-  'MODELVIEW1_STACK_DEPTH_EXT': 0x8502,
-  'MODELVIEW1_MATRIX_EXT': 0x8506,
-  'VERTEX_WEIGHTING_EXT': 0x8509,
-  'MODELVIEW1_EXT': 0x850A,
-  'CURRENT_VERTEX_WEIGHT_EXT': 0x850B,
-  'VERTEX_WEIGHT_ARRAY_EXT': 0x850C,
-  'VERTEX_WEIGHT_ARRAY_SIZE_EXT': 0x850D,
-  'VERTEX_WEIGHT_ARRAY_TYPE_EXT': 0x850E,
-  'VERTEX_WEIGHT_ARRAY_STRIDE_EXT': 0x850F,
-  'VERTEX_WEIGHT_ARRAY_POINTER_EXT': 0x8510,
-  'OCCLUSION_TEST_HP': 0x8165,
-  'OCCLUSION_TEST_RESULT_HP': 0x8166,
-  'MIRRORED_REPEAT_IBM': 0x8370,
-  'RED_MIN_CLAMP_INGR': 0x8560,
-  'GREEN_MIN_CLAMP_INGR': 0x8561,
-  'BLUE_MIN_CLAMP_INGR': 0x8562,
-  'ALPHA_MIN_CLAMP_INGR': 0x8563,
-  'RED_MAX_CLAMP_INGR': 0x8564,
-  'GREEN_MAX_CLAMP_INGR': 0x8565,
-  'BLUE_MAX_CLAMP_INGR': 0x8566,
-  'ALPHA_MAX_CLAMP_INGR': 0x8567,
-  'INTERLACE_READ_INGR': 0x8568,
-  'PARALLEL_ARRAYS_INTEL': 0x83F4,
-  'VERTEX_ARRAY_PARALLEL_POINTERS_INTEL': 0x83F5,
-  'NORMAL_ARRAY_PARALLEL_POINTERS_INTEL': 0x83F6,
-  'COLOR_ARRAY_PARALLEL_POINTERS_INTEL': 0x83F7,
-  'TEXTURE_COORD_ARRAY_PARALLEL_POINTERS_INTEL': 0x83F8,
-  'KTX_FRONT_REGION': 0x0,
-  'KTX_BACK_REGION': 0x1,
-  'KTX_Z_REGION': 0x2,
-  'KTX_STENCIL_REGION': 0x3,
-  'TEXTURE_1D_STACK_MESAX': 0x8759,
-  'TEXTURE_2D_STACK_MESAX': 0x875A,
-  'PROXY_TEXTURE_1D_STACK_MESAX': 0x875B,
-  'PROXY_TEXTURE_2D_STACK_MESAX': 0x875C,
-  'TEXTURE_1D_STACK_BINDING_MESAX': 0x875D,
-  'TEXTURE_2D_STACK_BINDING_MESAX': 0x875E,
-  'PACK_INVERT_MESA': 0x8758,
-  'UNSIGNED_SHORT_8_8_MESA': 0x85BA,
-  'UNSIGNED_SHORT_8_8_REV_MESA': 0x85BB,
-  'YCBCR_MESA': 0x8757,
-  'QUERY_WAIT_NV': 0x8E13,
-  'QUERY_NO_WAIT_NV': 0x8E14,
-  'QUERY_BY_REGION_WAIT_NV': 0x8E15,
-  'QUERY_BY_REGION_NO_WAIT_NV': 0x8E16,
-  'DEPTH_STENCIL_TO_RGBA_NV': 0x886E,
-  'DEPTH_STENCIL_TO_BGRA_NV': 0x886F,
-  'DEPTH_COMPONENT32F_NV': 0x8DAB,
-  'DEPTH32F_STENCIL8_NV': 0x8DAC,
-  'FLOAT_32_UNSIGNED_INT_24_8_REV_NV': 0x8DAD,
-  'DEPTH_BUFFER_FLOAT_MODE_NV': 0x8DAF,
-  'DEPTH_CLAMP_NV': 0x864F,
-  'SAMPLE_COUNT_BITS_NV': 0x8864,
-  'CURRENT_SAMPLE_COUNT_QUERY_NV': 0x8865,
-  'QUERY_RESULT_NV': 0x8866,
-  'QUERY_RESULT_AVAILABLE_NV': 0x8867,
-  'SAMPLE_COUNT_NV': 0x8914,
-  'EVAL_2D_NV': 0x86C0,
-  'EVAL_TRIANGULAR_2D_NV': 0x86C1,
-  'MAP_TESSELLATION_NV': 0x86C2,
-  'MAP_ATTRIB_U_ORDER_NV': 0x86C3,
-  'MAP_ATTRIB_V_ORDER_NV': 0x86C4,
-  'EVAL_FRACTIONAL_TESSELLATION_NV': 0x86C5,
-  'EVAL_VERTEX_ATTRIB0_NV': 0x86C6,
-  'EVAL_VERTEX_ATTRIB1_NV': 0x86C7,
-  'EVAL_VERTEX_ATTRIB2_NV': 0x86C8,
-  'EVAL_VERTEX_ATTRIB3_NV': 0x86C9,
-  'EVAL_VERTEX_ATTRIB4_NV': 0x86CA,
-  'EVAL_VERTEX_ATTRIB5_NV': 0x86CB,
-  'EVAL_VERTEX_ATTRIB6_NV': 0x86CC,
-  'EVAL_VERTEX_ATTRIB7_NV': 0x86CD,
-  'EVAL_VERTEX_ATTRIB8_NV': 0x86CE,
-  'EVAL_VERTEX_ATTRIB9_NV': 0x86CF,
-  'EVAL_VERTEX_ATTRIB10_NV': 0x86D0,
-  'EVAL_VERTEX_ATTRIB11_NV': 0x86D1,
-  'EVAL_VERTEX_ATTRIB12_NV': 0x86D2,
-  'EVAL_VERTEX_ATTRIB13_NV': 0x86D3,
-  'EVAL_VERTEX_ATTRIB14_NV': 0x86D4,
-  'EVAL_VERTEX_ATTRIB15_NV': 0x86D5,
-  'MAX_MAP_TESSELLATION_NV': 0x86D6,
-  'MAX_RATIONAL_EVAL_ORDER_NV': 0x86D7,
-  'SAMPLE_POSITION_NV': 0x8E50,
-  'SAMPLE_MASK_NV': 0x8E51,
-  'SAMPLE_MASK_VALUE_NV': 0x8E52,
-  'TEXTURE_BINDING_RENDERBUFFER_NV': 0x8E53,
-  'TEXTURE_RENDERBUFFER_DATA_STORE_BINDING_NV': 0x8E54,
-  'TEXTURE_RENDERBUFFER_NV': 0x8E55,
-  'SAMPLER_RENDERBUFFER_NV': 0x8E56,
-  'INT_SAMPLER_RENDERBUFFER_NV': 0x8E57,
-  'UNSIGNED_INT_SAMPLER_RENDERBUFFER_NV': 0x8E58,
-  'MAX_SAMPLE_MASK_WORDS_NV': 0x8E59,
-  'ALL_COMPLETED_NV': 0x84F2,
-  'FENCE_STATUS_NV': 0x84F3,
-  'FENCE_CONDITION_NV': 0x84F4,
-  'FLOAT_R_NV': 0x8880,
-  'FLOAT_RG_NV': 0x8881,
-  'FLOAT_RGB_NV': 0x8882,
-  'FLOAT_RGBA_NV': 0x8883,
-  'FLOAT_R16_NV': 0x8884,
-  'FLOAT_R32_NV': 0x8885,
-  'FLOAT_RG16_NV': 0x8886,
-  'FLOAT_RG32_NV': 0x8887,
-  'FLOAT_RGB16_NV': 0x8888,
-  'FLOAT_RGB32_NV': 0x8889,
-  'FLOAT_RGBA16_NV': 0x888A,
-  'FLOAT_RGBA32_NV': 0x888B,
-  'TEXTURE_FLOAT_COMPONENTS_NV': 0x888C,
-  'FLOAT_CLEAR_COLOR_VALUE_NV': 0x888D,
-  'FLOAT_RGBA_MODE_NV': 0x888E,
-  'FOG_DISTANCE_MODE_NV': 0x855A,
-  'EYE_RADIAL_NV': 0x855B,
-  'EYE_PLANE_ABSOLUTE_NV': 0x855C,
-  'MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV': 0x8868,
-  'FRAGMENT_PROGRAM_NV': 0x8870,
-  'MAX_TEXTURE_COORDS_NV': 0x8871,
-  'MAX_TEXTURE_IMAGE_UNITS_NV': 0x8872,
-  'FRAGMENT_PROGRAM_BINDING_NV': 0x8873,
-  'PROGRAM_ERROR_STRING_NV': 0x8874,
-  'MAX_PROGRAM_EXEC_INSTRUCTIONS_NV': 0x88F4,
-  'MAX_PROGRAM_CALL_DEPTH_NV': 0x88F5,
-  'MAX_PROGRAM_IF_DEPTH_NV': 0x88F6,
-  'MAX_PROGRAM_LOOP_DEPTH_NV': 0x88F7,
-  'MAX_PROGRAM_LOOP_COUNT_NV': 0x88F8,
-  'RENDERBUFFER_COVERAGE_SAMPLES_NV': 0x8CAB,
-  'RENDERBUFFER_COLOR_SAMPLES_NV': 0x8E10,
-  'MAX_MULTISAMPLE_COVERAGE_MODES_NV': 0x8E11,
-  'MULTISAMPLE_COVERAGE_MODES_NV': 0x8E12,
-  'GEOMETRY_PROGRAM_NV': 0x8C26,
-  'MAX_PROGRAM_OUTPUT_VERTICES_NV': 0x8C27,
-  'MAX_PROGRAM_TOTAL_OUTPUT_COMPONENTS_NV': 0x8C28,
-  'MIN_PROGRAM_TEXEL_OFFSET_NV': 0x8904,
-  'MAX_PROGRAM_TEXEL_OFFSET_NV': 0x8905,
-  'PROGRAM_ATTRIB_COMPONENTS_NV': 0x8906,
-  'PROGRAM_RESULT_COMPONENTS_NV': 0x8907,
-  'MAX_PROGRAM_ATTRIB_COMPONENTS_NV': 0x8908,
-  'MAX_PROGRAM_RESULT_COMPONENTS_NV': 0x8909,
-  'MAX_PROGRAM_GENERIC_ATTRIBS_NV': 0x8DA5,
-  'MAX_PROGRAM_GENERIC_RESULTS_NV': 0x8DA6,
-  'HALF_FLOAT_NV': 0x140B,
-  'MAX_SHININESS_NV': 0x8504,
-  'MAX_SPOT_EXPONENT_NV': 0x8505,
-  'MULTISAMPLE_FILTER_HINT_NV': 0x8534,
-  'PIXEL_COUNTER_BITS_NV': 0x8864,
-  'CURRENT_OCCLUSION_QUERY_ID_NV': 0x8865,
-  'PIXEL_COUNT_NV': 0x8866,
-  'PIXEL_COUNT_AVAILABLE_NV': 0x8867,
-  'DEPTH_STENCIL_NV': 0x84F9,
-  'UNSIGNED_INT_24_8_NV': 0x84FA,
-  'MAX_PROGRAM_PARAMETER_BUFFER_BINDINGS_NV': 0x8DA0,
-  'MAX_PROGRAM_PARAMETER_BUFFER_SIZE_NV': 0x8DA1,
-  'VERTEX_PROGRAM_PARAMETER_BUFFER_NV': 0x8DA2,
-  'GEOMETRY_PROGRAM_PARAMETER_BUFFER_NV': 0x8DA3,
-  'FRAGMENT_PROGRAM_PARAMETER_BUFFER_NV': 0x8DA4,
-  'WRITE_PIXEL_DATA_RANGE_NV': 0x8878,
-  'READ_PIXEL_DATA_RANGE_NV': 0x8879,
-  'WRITE_PIXEL_DATA_RANGE_LENGTH_NV': 0x887A,
-  'READ_PIXEL_DATA_RANGE_LENGTH_NV': 0x887B,
-  'WRITE_PIXEL_DATA_RANGE_POINTER_NV': 0x887C,
-  'READ_PIXEL_DATA_RANGE_POINTER_NV': 0x887D,
-  'POINT_SPRITE_NV': 0x8861,
-  'COORD_REPLACE_NV': 0x8862,
-  'POINT_SPRITE_R_MODE_NV': 0x8863,
-  'FRAME_NV': 0x8E26,
-  'FIELDS_NV': 0x8E27,
-  'CURRENT_TIME_NV': 0x8E28,
-  'NUM_FILL_STREAMS_NV': 0x8E29,
-  'PRESENT_TIME_NV': 0x8E2A,
-  'PRESENT_DURATION_NV': 0x8E2B,
-  'PRIMITIVE_RESTART_NV': 0x8558,
-  'PRIMITIVE_RESTART_INDEX_NV': 0x8559,
-  'REGISTER_COMBINERS_NV': 0x8522,
-  'VARIABLE_A_NV': 0x8523,
-  'VARIABLE_B_NV': 0x8524,
-  'VARIABLE_C_NV': 0x8525,
-  'VARIABLE_D_NV': 0x8526,
-  'VARIABLE_E_NV': 0x8527,
-  'VARIABLE_F_NV': 0x8528,
-  'VARIABLE_G_NV': 0x8529,
-  'CONSTANT_COLOR0_NV': 0x852A,
-  'CONSTANT_COLOR1_NV': 0x852B,
-  'PRIMARY_COLOR_NV': 0x852C,
-  'SECONDARY_COLOR_NV': 0x852D,
-  'SPARE0_NV': 0x852E,
-  'SPARE1_NV': 0x852F,
-  'DISCARD_NV': 0x8530,
-  'E_TIMES_F_NV': 0x8531,
-  'SPARE0_PLUS_SECONDARY_COLOR_NV': 0x8532,
-  'UNSIGNED_IDENTITY_NV': 0x8536,
-  'UNSIGNED_INVERT_NV': 0x8537,
-  'EXPAND_NORMAL_NV': 0x8538,
-  'EXPAND_NEGATE_NV': 0x8539,
-  'HALF_BIAS_NORMAL_NV': 0x853A,
-  'HALF_BIAS_NEGATE_NV': 0x853B,
-  'SIGNED_IDENTITY_NV': 0x853C,
-  'SIGNED_NEGATE_NV': 0x853D,
-  'SCALE_BY_TWO_NV': 0x853E,
-  'SCALE_BY_FOUR_NV': 0x853F,
-  'SCALE_BY_ONE_HALF_NV': 0x8540,
-  'BIAS_BY_NEGATIVE_ONE_HALF_NV': 0x8541,
-  'COMBINER_INPUT_NV': 0x8542,
-  'COMBINER_MAPPING_NV': 0x8543,
-  'COMBINER_COMPONENT_USAGE_NV': 0x8544,
-  'COMBINER_AB_DOT_PRODUCT_NV': 0x8545,
-  'COMBINER_CD_DOT_PRODUCT_NV': 0x8546,
-  'COMBINER_MUX_SUM_NV': 0x8547,
-  'COMBINER_SCALE_NV': 0x8548,
-  'COMBINER_BIAS_NV': 0x8549,
-  'COMBINER_AB_OUTPUT_NV': 0x854A,
-  'COMBINER_CD_OUTPUT_NV': 0x854B,
-  'COMBINER_SUM_OUTPUT_NV': 0x854C,
-  'MAX_GENERAL_COMBINERS_NV': 0x854D,
-  'NUM_GENERAL_COMBINERS_NV': 0x854E,
-  'COLOR_SUM_CLAMP_NV': 0x854F,
-  'COMBINER0_NV': 0x8550,
-  'COMBINER1_NV': 0x8551,
-  'COMBINER2_NV': 0x8552,
-  'COMBINER3_NV': 0x8553,
-  'COMBINER4_NV': 0x8554,
-  'COMBINER5_NV': 0x8555,
-  'COMBINER6_NV': 0x8556,
-  'COMBINER7_NV': 0x8557,
-  'PER_STAGE_CONSTANTS_NV': 0x8535,
-  'EMBOSS_LIGHT_NV': 0x855D,
-  'EMBOSS_CONSTANT_NV': 0x855E,
-  'EMBOSS_MAP_NV': 0x855F,
-  'NORMAL_MAP_NV': 0x8511,
-  'REFLECTION_MAP_NV': 0x8512,
-  'COMBINE4_NV': 0x8503,
-  'SOURCE3_RGB_NV': 0x8583,
-  'SOURCE3_ALPHA_NV': 0x858B,
-  'OPERAND3_RGB_NV': 0x8593,
-  'OPERAND3_ALPHA_NV': 0x859B,
-  'TEXTURE_UNSIGNED_REMAP_MODE_NV': 0x888F,
-  'TEXTURE_RECTANGLE_NV': 0x84F5,
-  'TEXTURE_BINDING_RECTANGLE_NV': 0x84F6,
-  'PROXY_TEXTURE_RECTANGLE_NV': 0x84F7,
-  'MAX_RECTANGLE_TEXTURE_SIZE_NV': 0x84F8,
-  'OFFSET_TEXTURE_RECTANGLE_NV': 0x864C,
-  'OFFSET_TEXTURE_RECTANGLE_SCALE_NV': 0x864D,
-  'DOT_PRODUCT_TEXTURE_RECTANGLE_NV': 0x864E,
-  'RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV': 0x86D9,
-  'UNSIGNED_INT_S8_S8_8_8_NV': 0x86DA,
-  'UNSIGNED_INT_8_8_S8_S8_REV_NV': 0x86DB,
-  'DSDT_MAG_INTENSITY_NV': 0x86DC,
-  'SHADER_CONSISTENT_NV': 0x86DD,
-  'TEXTURE_SHADER_NV': 0x86DE,
-  'SHADER_OPERATION_NV': 0x86DF,
-  'CULL_MODES_NV': 0x86E0,
-  'OFFSET_TEXTURE_2D_MATRIX_NV': 0x86E1,
-  'OFFSET_TEXTURE_MATRIX_NV': 0x86E1,
-  'OFFSET_TEXTURE_2D_SCALE_NV': 0x86E2,
-  'OFFSET_TEXTURE_SCALE_NV': 0x86E2,
-  'OFFSET_TEXTURE_BIAS_NV': 0x86E3,
-  'OFFSET_TEXTURE_2D_BIAS_NV': 0x86E3,
-  'PREVIOUS_TEXTURE_INPUT_NV': 0x86E4,
-  'CONST_EYE_NV': 0x86E5,
-  'PASS_THROUGH_NV': 0x86E6,
-  'CULL_FRAGMENT_NV': 0x86E7,
-  'OFFSET_TEXTURE_2D_NV': 0x86E8,
-  'DEPENDENT_AR_TEXTURE_2D_NV': 0x86E9,
-  'DEPENDENT_GB_TEXTURE_2D_NV': 0x86EA,
-  'DOT_PRODUCT_NV': 0x86EC,
-  'DOT_PRODUCT_DEPTH_REPLACE_NV': 0x86ED,
-  'DOT_PRODUCT_TEXTURE_2D_NV': 0x86EE,
-  'DOT_PRODUCT_TEXTURE_CUBE_MAP_NV': 0x86F0,
-  'DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV': 0x86F1,
-  'DOT_PRODUCT_REFLECT_CUBE_MAP_NV': 0x86F2,
-  'DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV': 0x86F3,
-  'HILO_NV': 0x86F4,
-  'DSDT_NV': 0x86F5,
-  'DSDT_MAG_NV': 0x86F6,
-  'DSDT_MAG_VIB_NV': 0x86F7,
-  'HILO16_NV': 0x86F8,
-  'SIGNED_HILO_NV': 0x86F9,
-  'SIGNED_HILO16_NV': 0x86FA,
-  'SIGNED_RGBA_NV': 0x86FB,
-  'SIGNED_RGBA8_NV': 0x86FC,
-  'SIGNED_RGB_NV': 0x86FE,
-  'SIGNED_RGB8_NV': 0x86FF,
-  'SIGNED_LUMINANCE_NV': 0x8701,
-  'SIGNED_LUMINANCE8_NV': 0x8702,
-  'SIGNED_LUMINANCE_ALPHA_NV': 0x8703,
-  'SIGNED_LUMINANCE8_ALPHA8_NV': 0x8704,
-  'SIGNED_ALPHA_NV': 0x8705,
-  'SIGNED_ALPHA8_NV': 0x8706,
-  'SIGNED_INTENSITY_NV': 0x8707,
-  'SIGNED_INTENSITY8_NV': 0x8708,
-  'DSDT8_NV': 0x8709,
-  'DSDT8_MAG8_NV': 0x870A,
-  'DSDT8_MAG8_INTENSITY8_NV': 0x870B,
-  'SIGNED_RGB_UNSIGNED_ALPHA_NV': 0x870C,
-  'SIGNED_RGB8_UNSIGNED_ALPHA8_NV': 0x870D,
-  'HI_SCALE_NV': 0x870E,
-  'LO_SCALE_NV': 0x870F,
-  'DS_SCALE_NV': 0x8710,
-  'DT_SCALE_NV': 0x8711,
-  'MAGNITUDE_SCALE_NV': 0x8712,
-  'VIBRANCE_SCALE_NV': 0x8713,
-  'HI_BIAS_NV': 0x8714,
-  'LO_BIAS_NV': 0x8715,
-  'DS_BIAS_NV': 0x8716,
-  'DT_BIAS_NV': 0x8717,
-  'MAGNITUDE_BIAS_NV': 0x8718,
-  'VIBRANCE_BIAS_NV': 0x8719,
-  'TEXTURE_BORDER_VALUES_NV': 0x871A,
-  'TEXTURE_HI_SIZE_NV': 0x871B,
-  'TEXTURE_LO_SIZE_NV': 0x871C,
-  'TEXTURE_DS_SIZE_NV': 0x871D,
-  'TEXTURE_DT_SIZE_NV': 0x871E,
-  'TEXTURE_MAG_SIZE_NV': 0x871F,
-  'UNSIGNED_INT_S8_S8_8_8_NV': 0x86DA,
-  'UNSIGNED_INT_8_8_S8_S8_REV_NV': 0x86DB,
-  'DSDT_MAG_INTENSITY_NV': 0x86DC,
-  'DOT_PRODUCT_TEXTURE_3D_NV': 0x86EF,
-  'HILO_NV': 0x86F4,
-  'DSDT_NV': 0x86F5,
-  'DSDT_MAG_NV': 0x86F6,
-  'DSDT_MAG_VIB_NV': 0x86F7,
-  'HILO16_NV': 0x86F8,
-  'SIGNED_HILO_NV': 0x86F9,
-  'SIGNED_HILO16_NV': 0x86FA,
-  'SIGNED_RGBA_NV': 0x86FB,
-  'SIGNED_RGBA8_NV': 0x86FC,
-  'SIGNED_RGB_NV': 0x86FE,
-  'SIGNED_RGB8_NV': 0x86FF,
-  'SIGNED_LUMINANCE_NV': 0x8701,
-  'SIGNED_LUMINANCE8_NV': 0x8702,
-  'SIGNED_LUMINANCE_ALPHA_NV': 0x8703,
-  'SIGNED_LUMINANCE8_ALPHA8_NV': 0x8704,
-  'SIGNED_ALPHA_NV': 0x8705,
-  'SIGNED_ALPHA8_NV': 0x8706,
-  'SIGNED_INTENSITY_NV': 0x8707,
-  'SIGNED_INTENSITY8_NV': 0x8708,
-  'DSDT8_NV': 0x8709,
-  'DSDT8_MAG8_NV': 0x870A,
-  'DSDT8_MAG8_INTENSITY8_NV': 0x870B,
-  'SIGNED_RGB_UNSIGNED_ALPHA_NV': 0x870C,
-  'SIGNED_RGB8_UNSIGNED_ALPHA8_NV': 0x870D,
-  'OFFSET_PROJECTIVE_TEXTURE_2D_NV': 0x8850,
-  'OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV': 0x8851,
-  'OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV': 0x8852,
-  'OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV': 0x8853,
-  'OFFSET_HILO_TEXTURE_2D_NV': 0x8854,
-  'OFFSET_HILO_TEXTURE_RECTANGLE_NV': 0x8855,
-  'OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV': 0x8856,
-  'OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV': 0x8857,
-  'DEPENDENT_HILO_TEXTURE_2D_NV': 0x8858,
-  'DEPENDENT_RGB_TEXTURE_3D_NV': 0x8859,
-  'DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV': 0x885A,
-  'DOT_PRODUCT_PASS_THROUGH_NV': 0x885B,
-  'DOT_PRODUCT_TEXTURE_1D_NV': 0x885C,
-  'DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV': 0x885D,
-  'HILO8_NV': 0x885E,
-  'SIGNED_HILO8_NV': 0x885F,
-  'FORCE_BLUE_TO_ONE_NV': 0x8860,
-  'BACK_PRIMARY_COLOR_NV': 0x8C77,
-  'BACK_SECONDARY_COLOR_NV': 0x8C78,
-  'TEXTURE_COORD_NV': 0x8C79,
-  'CLIP_DISTANCE_NV': 0x8C7A,
-  'VERTEX_ID_NV': 0x8C7B,
-  'PRIMITIVE_ID_NV': 0x8C7C,
-  'GENERIC_ATTRIB_NV': 0x8C7D,
-  'TRANSFORM_FEEDBACK_ATTRIBS_NV': 0x8C7E,
-  'TRANSFORM_FEEDBACK_BUFFER_MODE_NV': 0x8C7F,
-  'MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_NV': 0x8C80,
-  'ACTIVE_VARYINGS_NV': 0x8C81,
-  'ACTIVE_VARYING_MAX_LENGTH_NV': 0x8C82,
-  'TRANSFORM_FEEDBACK_VARYINGS_NV': 0x8C83,
-  'TRANSFORM_FEEDBACK_BUFFER_START_NV': 0x8C84,
-  'TRANSFORM_FEEDBACK_BUFFER_SIZE_NV': 0x8C85,
-  'TRANSFORM_FEEDBACK_RECORD_NV': 0x8C86,
-  'PRIMITIVES_GENERATED_NV': 0x8C87,
-  'TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_NV': 0x8C88,
-  'RASTERIZER_DISCARD_NV': 0x8C89,
-  'MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_NV': 0x8C8A,
-  'MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_NV': 0x8C8B,
-  'INTERLEAVED_ATTRIBS_NV': 0x8C8C,
-  'SEPARATE_ATTRIBS_NV': 0x8C8D,
-  'TRANSFORM_FEEDBACK_BUFFER_NV': 0x8C8E,
-  'TRANSFORM_FEEDBACK_BUFFER_BINDING_NV': 0x8C8F,
-  'VERTEX_ARRAY_RANGE_NV': 0x851D,
-  'VERTEX_ARRAY_RANGE_LENGTH_NV': 0x851E,
-  'VERTEX_ARRAY_RANGE_VALID_NV': 0x851F,
-  'MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV': 0x8520,
-  'VERTEX_ARRAY_RANGE_POINTER_NV': 0x8521,
-  'VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV': 0x8533,
-  'VERTEX_PROGRAM_NV': 0x8620,
-  'VERTEX_STATE_PROGRAM_NV': 0x8621,
-  'ATTRIB_ARRAY_SIZE_NV': 0x8623,
-  'ATTRIB_ARRAY_STRIDE_NV': 0x8624,
-  'ATTRIB_ARRAY_TYPE_NV': 0x8625,
-  'CURRENT_ATTRIB_NV': 0x8626,
-  'PROGRAM_LENGTH_NV': 0x8627,
-  'PROGRAM_STRING_NV': 0x8628,
-  'MODELVIEW_PROJECTION_NV': 0x8629,
-  'IDENTITY_NV': 0x862A,
-  'INVERSE_NV': 0x862B,
-  'TRANSPOSE_NV': 0x862C,
-  'INVERSE_TRANSPOSE_NV': 0x862D,
-  'MAX_TRACK_MATRIX_STACK_DEPTH_NV': 0x862E,
-  'MAX_TRACK_MATRICES_NV': 0x862F,
-  'MATRIX0_NV': 0x8630,
-  'MATRIX1_NV': 0x8631,
-  'MATRIX2_NV': 0x8632,
-  'MATRIX3_NV': 0x8633,
-  'MATRIX4_NV': 0x8634,
-  'MATRIX5_NV': 0x8635,
-  'MATRIX6_NV': 0x8636,
-  'MATRIX7_NV': 0x8637,
-  'CURRENT_MATRIX_STACK_DEPTH_NV': 0x8640,
-  'CURRENT_MATRIX_NV': 0x8641,
-  'VERTEX_PROGRAM_POINT_SIZE_NV': 0x8642,
-  'VERTEX_PROGRAM_TWO_SIDE_NV': 0x8643,
-  'PROGRAM_PARAMETER_NV': 0x8644,
-  'ATTRIB_ARRAY_POINTER_NV': 0x8645,
-  'PROGRAM_TARGET_NV': 0x8646,
-  'PROGRAM_RESIDENT_NV': 0x8647,
-  'TRACK_MATRIX_NV': 0x8648,
-  'TRACK_MATRIX_TRANSFORM_NV': 0x8649,
-  'VERTEX_PROGRAM_BINDING_NV': 0x864A,
-  'PROGRAM_ERROR_POSITION_NV': 0x864B,
-  'VERTEX_ATTRIB_ARRAY0_NV': 0x8650,
-  'VERTEX_ATTRIB_ARRAY1_NV': 0x8651,
-  'VERTEX_ATTRIB_ARRAY2_NV': 0x8652,
-  'VERTEX_ATTRIB_ARRAY3_NV': 0x8653,
-  'VERTEX_ATTRIB_ARRAY4_NV': 0x8654,
-  'VERTEX_ATTRIB_ARRAY5_NV': 0x8655,
-  'VERTEX_ATTRIB_ARRAY6_NV': 0x8656,
-  'VERTEX_ATTRIB_ARRAY7_NV': 0x8657,
-  'VERTEX_ATTRIB_ARRAY8_NV': 0x8658,
-  'VERTEX_ATTRIB_ARRAY9_NV': 0x8659,
-  'VERTEX_ATTRIB_ARRAY10_NV': 0x865A,
-  'VERTEX_ATTRIB_ARRAY11_NV': 0x865B,
-  'VERTEX_ATTRIB_ARRAY12_NV': 0x865C,
-  'VERTEX_ATTRIB_ARRAY13_NV': 0x865D,
-  'VERTEX_ATTRIB_ARRAY14_NV': 0x865E,
-  'VERTEX_ATTRIB_ARRAY15_NV': 0x865F,
-  'MAP1_VERTEX_ATTRIB0_4_NV': 0x8660,
-  'MAP1_VERTEX_ATTRIB1_4_NV': 0x8661,
-  'MAP1_VERTEX_ATTRIB2_4_NV': 0x8662,
-  'MAP1_VERTEX_ATTRIB3_4_NV': 0x8663,
-  'MAP1_VERTEX_ATTRIB4_4_NV': 0x8664,
-  'MAP1_VERTEX_ATTRIB5_4_NV': 0x8665,
-  'MAP1_VERTEX_ATTRIB6_4_NV': 0x8666,
-  'MAP1_VERTEX_ATTRIB7_4_NV': 0x8667,
-  'MAP1_VERTEX_ATTRIB8_4_NV': 0x8668,
-  'MAP1_VERTEX_ATTRIB9_4_NV': 0x8669,
-  'MAP1_VERTEX_ATTRIB10_4_NV': 0x866A,
-  'MAP1_VERTEX_ATTRIB11_4_NV': 0x866B,
-  'MAP1_VERTEX_ATTRIB12_4_NV': 0x866C,
-  'MAP1_VERTEX_ATTRIB13_4_NV': 0x866D,
-  'MAP1_VERTEX_ATTRIB14_4_NV': 0x866E,
-  'MAP1_VERTEX_ATTRIB15_4_NV': 0x866F,
-  'MAP2_VERTEX_ATTRIB0_4_NV': 0x8670,
-  'MAP2_VERTEX_ATTRIB1_4_NV': 0x8671,
-  'MAP2_VERTEX_ATTRIB2_4_NV': 0x8672,
-  'MAP2_VERTEX_ATTRIB3_4_NV': 0x8673,
-  'MAP2_VERTEX_ATTRIB4_4_NV': 0x8674,
-  'MAP2_VERTEX_ATTRIB5_4_NV': 0x8675,
-  'MAP2_VERTEX_ATTRIB6_4_NV': 0x8676,
-  'MAP2_VERTEX_ATTRIB7_4_NV': 0x8677,
-  'MAP2_VERTEX_ATTRIB8_4_NV': 0x8678,
-  'MAP2_VERTEX_ATTRIB9_4_NV': 0x8679,
-  'MAP2_VERTEX_ATTRIB10_4_NV': 0x867A,
-  'MAP2_VERTEX_ATTRIB11_4_NV': 0x867B,
-  'MAP2_VERTEX_ATTRIB12_4_NV': 0x867C,
-  'MAP2_VERTEX_ATTRIB13_4_NV': 0x867D,
-  'MAP2_VERTEX_ATTRIB14_4_NV': 0x867E,
-  'MAP2_VERTEX_ATTRIB15_4_NV': 0x867F,
-  'MAX_PROGRAM_EXEC_INSTRUCTIONS_NV': 0x88F4,
-  'MAX_PROGRAM_CALL_DEPTH_NV': 0x88F5,
-  'MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB': 0x8B4C,
-  'BYTE': 0x1400,
-  'PALETTE4_RGB8_OES': 0x8B90,
-  'PALETTE4_RGBA8_OES': 0x8B91,
-  'PALETTE4_R5_G6_B5_OES': 0x8B92,
-  'PALETTE4_RGBA4_OES': 0x8B93,
-  'PALETTE4_RGB5_A1_OES': 0x8B94,
-  'PALETTE8_RGB8_OES': 0x8B95,
-  'PALETTE8_RGBA8_OES': 0x8B96,
-  'PALETTE8_R5_G6_B5_OES': 0x8B97,
-  'PALETTE8_RGBA4_OES': 0x8B98,
-  'PALETTE8_RGB5_A1_OES': 0x8B99,
-  'IMPLEMENTATION_COLOR_READ_TYPE_OES': 0x8B9A,
-  'IMPLEMENTATION_COLOR_READ_FORMAT_OES': 0x8B9B,
-  'INTERLACE_OML': 0x8980,
-  'INTERLACE_READ_OML': 0x8981,
-  'PACK_RESAMPLE_OML': 0x8984,
-  'UNPACK_RESAMPLE_OML': 0x8985,
-  'RESAMPLE_REPLICATE_OML': 0x8986,
-  'RESAMPLE_ZERO_FILL_OML': 0x8987,
-  'RESAMPLE_AVERAGE_OML': 0x8988,
-  'RESAMPLE_DECIMATE_OML': 0x8989,
-  'FORMAT_SUBSAMPLE_24_24_OML': 0x8982,
-  'FORMAT_SUBSAMPLE_244_244_OML': 0x8983,
-  'VERTEX23_BIT_PGI': 0x00000004,
-  'VERTEX4_BIT_PGI': 0x00000008,
-  'COLOR3_BIT_PGI': 0x00010000,
-  'COLOR4_BIT_PGI': 0x00020000,
-  'EDGEFLAG_BIT_PGI': 0x00040000,
-  'INDEX_BIT_PGI': 0x00080000,
-  'MAT_AMBIENT_BIT_PGI': 0x00100000,
-  'MAT_AMBIENT_AND_DIFFUSE_BIT_PGI': 0x00200000,
-  'MAT_DIFFUSE_BIT_PGI': 0x00400000,
-  'MAT_EMISSION_BIT_PGI': 0x00800000,
-  'MAT_COLOR_INDEXES_BIT_PGI': 0x01000000,
-  'MAT_SHININESS_BIT_PGI': 0x02000000,
-  'MAT_SPECULAR_BIT_PGI': 0x04000000,
-  'NORMAL_BIT_PGI': 0x08000000,
-  'TEXCOORD1_BIT_PGI': 0x10000000,
-  'TEXCOORD2_BIT_PGI': 0x20000000,
-  'TEXCOORD3_BIT_PGI': 0x40000000,
-  'TEXCOORD4_BIT_PGI': 0x80000000,
-  'SCREEN_COORDINATES_REND': 0x8490,
-  'INVERTED_SCREEN_W_REND': 0x8491,
-  'RGB_S3TC': 0x83A0,
-  'RGB4_S3TC': 0x83A1,
-  'RGBA_S3TC': 0x83A2,
-  'RGBA4_S3TC': 0x83A3,
-  'RGBA_DXT5_S3TC': 0x83A4,
-  'RGBA4_DXT5_S3TC': 0x83A5,
-  'EXTENDED_RANGE_SGIS': 0x85A5,
-  'MIN_RED_SGIS': 0x85A6,
-  'MAX_RED_SGIS': 0x85A7,
-  'MIN_GREEN_SGIS': 0x85A8,
-  'MAX_GREEN_SGIS': 0x85A9,
-  'MIN_BLUE_SGIS': 0x85AA,
-  'MAX_BLUE_SGIS': 0x85AB,
-  'MIN_ALPHA_SGIS': 0x85AC,
-  'MAX_ALPHA_SGIS': 0x85AD,
-  'GENERATE_MIPMAP_SGIS': 0x8191,
-  'GENERATE_MIPMAP_HINT_SGIS': 0x8192,
-  'MULTISAMPLE_SGIS': 0x809D,
-  'SAMPLE_ALPHA_TO_MASK_SGIS': 0x809E,
-  'SAMPLE_ALPHA_TO_ONE_SGIS': 0x809F,
-  'SAMPLE_MASK_SGIS': 0x80A0,
-  '1PASS_SGIS': 0x80A1,
-  '2PASS_0_SGIS': 0x80A2,
-  '2PASS_1_SGIS': 0x80A3,
-  '4PASS_0_SGIS': 0x80A4,
-  '4PASS_1_SGIS': 0x80A5,
-  '4PASS_2_SGIS': 0x80A6,
-  '4PASS_3_SGIS': 0x80A7,
-  'SAMPLE_BUFFERS_SGIS': 0x80A8,
-  'SAMPLES_SGIS': 0x80A9,
-  'SAMPLE_MASK_VALUE_SGIS': 0x80AA,
-  'SAMPLE_MASK_INVERT_SGIS': 0x80AB,
-  'SAMPLE_PATTERN_SGIS': 0x80AC,
-  'MULTISAMPLE_BIT_EXT': 0x20000000,
-  'EYE_DISTANCE_TO_POINT_SGIS': 0x81F0,
-  'OBJECT_DISTANCE_TO_POINT_SGIS': 0x81F1,
-  'EYE_DISTANCE_TO_LINE_SGIS': 0x81F2,
-  'OBJECT_DISTANCE_TO_LINE_SGIS': 0x81F3,
-  'EYE_POINT_SGIS': 0x81F4,
-  'OBJECT_POINT_SGIS': 0x81F5,
-  'EYE_LINE_SGIS': 0x81F6,
-  'OBJECT_LINE_SGIS': 0x81F7,
-  'CLAMP_TO_BORDER_SGIS': 0x812D,
-  'CLAMP_TO_EDGE_SGIS': 0x812F,
-  'TEXTURE_MIN_LOD_SGIS': 0x813A,
-  'TEXTURE_MAX_LOD_SGIS': 0x813B,
-  'TEXTURE_BASE_LEVEL_SGIS': 0x813C,
-  'TEXTURE_MAX_LEVEL_SGIS': 0x813D,
-  'ASYNC_MARKER_SGIX': 0x8329,
-  'ASYNC_HISTOGRAM_SGIX': 0x832C,
-  'MAX_ASYNC_HISTOGRAM_SGIX': 0x832D,
-  'ASYNC_TEX_IMAGE_SGIX': 0x835C,
-  'ASYNC_DRAW_PIXELS_SGIX': 0x835D,
-  'ASYNC_READ_PIXELS_SGIX': 0x835E,
-  'MAX_ASYNC_TEX_IMAGE_SGIX': 0x835F,
-  'MAX_ASYNC_DRAW_PIXELS_SGIX': 0x8360,
-  'MAX_ASYNC_READ_PIXELS_SGIX': 0x8361,
-  'ALPHA_MIN_SGIX': 0x8320,
-  'ALPHA_MAX_SGIX': 0x8321,
-  'CONVOLUTION_HINT_SGIX': 0x8316,
-  'DEPTH_COMPONENT16_SGIX': 0x81A5,
-  'DEPTH_COMPONENT24_SGIX': 0x81A6,
-  'DEPTH_COMPONENT32_SGIX': 0x81A7,
-  'FOG_OFFSET_SGIX': 0x8198,
-  'FOG_OFFSET_VALUE_SGIX': 0x8199,
-  'INTERLACE_SGIX': 0x8094,
-  'PACK_RESAMPLE_SGIX': 0x842E,
-  'UNPACK_RESAMPLE_SGIX': 0x842F,
-  'RESAMPLE_DECIMATE_SGIX': 0x8430,
-  'RESAMPLE_REPLICATE_SGIX': 0x8433,
-  'RESAMPLE_ZERO_FILL_SGIX': 0x8434,
-  'TEXTURE_COMPARE_SGIX': 0x819A,
-  'TEXTURE_COMPARE_OPERATOR_SGIX': 0x819B,
-  'TEXTURE_LEQUAL_R_SGIX': 0x819C,
-  'TEXTURE_GEQUAL_R_SGIX': 0x819D,
-  'SHADOW_AMBIENT_SGIX': 0x80BF,
-  'TEXTURE_MAX_CLAMP_S_SGIX': 0x8369,
-  'TEXTURE_MAX_CLAMP_T_SGIX': 0x836A,
-  'TEXTURE_MAX_CLAMP_R_SGIX': 0x836B,
-  'TEXTURE_MULTI_BUFFER_HINT_SGIX': 0x812E,
-  'RGB_SIGNED_SGIX': 0x85E0,
-  'RGBA_SIGNED_SGIX': 0x85E1,
-  'ALPHA_SIGNED_SGIX': 0x85E2,
-  'LUMINANCE_SIGNED_SGIX': 0x85E3,
-  'INTENSITY_SIGNED_SGIX': 0x85E4,
-  'LUMINANCE_ALPHA_SIGNED_SGIX': 0x85E5,
-  'RGB16_SIGNED_SGIX': 0x85E6,
-  'RGBA16_SIGNED_SGIX': 0x85E7,
-  'ALPHA16_SIGNED_SGIX': 0x85E8,
-  'LUMINANCE16_SIGNED_SGIX': 0x85E9,
-  'INTENSITY16_SIGNED_SGIX': 0x85EA,
-  'LUMINANCE16_ALPHA16_SIGNED_SGIX': 0x85EB,
-  'RGB_EXTENDED_RANGE_SGIX': 0x85EC,
-  'RGBA_EXTENDED_RANGE_SGIX': 0x85ED,
-  'ALPHA_EXTENDED_RANGE_SGIX': 0x85EE,
-  'LUMINANCE_EXTENDED_RANGE_SGIX': 0x85EF,
-  'INTENSITY_EXTENDED_RANGE_SGIX': 0x85F0,
-  'LUMINANCE_ALPHA_EXTENDED_RANGE_SGIX': 0x85F1,
-  'RGB16_EXTENDED_RANGE_SGIX': 0x85F2,
-  'RGBA16_EXTENDED_RANGE_SGIX': 0x85F3,
-  'ALPHA16_EXTENDED_RANGE_SGIX': 0x85F4,
-  'LUMINANCE16_EXTENDED_RANGE_SGIX': 0x85F5,
-  'INTENSITY16_EXTENDED_RANGE_SGIX': 0x85F6,
-  'LUMINANCE16_ALPHA16_EXTENDED_RANGE_SGIX': 0x85F7,
-  'MIN_LUMINANCE_SGIS': 0x85F8,
-  'MAX_LUMINANCE_SGIS': 0x85F9,
-  'MIN_INTENSITY_SGIS': 0x85FA,
-  'MAX_INTENSITY_SGIS': 0x85FB,
-  'POST_TEXTURE_FILTER_BIAS_SGIX': 0x8179,
-  'POST_TEXTURE_FILTER_SCALE_SGIX': 0x817A,
-  'POST_TEXTURE_FILTER_BIAS_RANGE_SGIX': 0x817B,
-  'POST_TEXTURE_FILTER_SCALE_RANGE_SGIX': 0x817C,
-  'VERTEX_PRECLIP_SGIX': 0x83EE,
-  'VERTEX_PRECLIP_HINT_SGIX': 0x83EF,
-  'VERTEX_PRECLIP_SGIX': 0x83EE,
-  'VERTEX_PRECLIP_HINT_SGIX': 0x83EF,
-  'COLOR_MATRIX_SGI': 0x80B1,
-  'COLOR_MATRIX_STACK_DEPTH_SGI': 0x80B2,
-  'MAX_COLOR_MATRIX_STACK_DEPTH_SGI': 0x80B3,
-  'POST_COLOR_MATRIX_RED_SCALE_SGI': 0x80B4,
-  'POST_COLOR_MATRIX_GREEN_SCALE_SGI': 0x80B5,
-  'POST_COLOR_MATRIX_BLUE_SCALE_SGI': 0x80B6,
-  'POST_COLOR_MATRIX_ALPHA_SCALE_SGI': 0x80B7,
-  'POST_COLOR_MATRIX_RED_BIAS_SGI': 0x80B8,
-  'POST_COLOR_MATRIX_GREEN_BIAS_SGI': 0x80B9,
-  'POST_COLOR_MATRIX_BLUE_BIAS_SGI': 0x80BA,
-  'POST_COLOR_MATRIX_ALPHA_BIAS_SGI': 0x80BB,
-  'COLOR_TABLE_SGI': 0x80D0,
-  'POST_CONVOLUTION_COLOR_TABLE_SGI': 0x80D1,
-  'POST_COLOR_MATRIX_COLOR_TABLE_SGI': 0x80D2,
-  'PROXY_COLOR_TABLE_SGI': 0x80D3,
-  'PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI': 0x80D4,
-  'PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI': 0x80D5,
-  'COLOR_TABLE_SCALE_SGI': 0x80D6,
-  'COLOR_TABLE_BIAS_SGI': 0x80D7,
-  'COLOR_TABLE_FORMAT_SGI': 0x80D8,
-  'COLOR_TABLE_WIDTH_SGI': 0x80D9,
-  'COLOR_TABLE_RED_SIZE_SGI': 0x80DA,
-  'COLOR_TABLE_GREEN_SIZE_SGI': 0x80DB,
-  'COLOR_TABLE_BLUE_SIZE_SGI': 0x80DC,
-  'COLOR_TABLE_ALPHA_SIZE_SGI': 0x80DD,
-  'COLOR_TABLE_LUMINANCE_SIZE_SGI': 0x80DE,
-  'COLOR_TABLE_INTENSITY_SIZE_SGI': 0x80DF,
-  'TEXTURE_COLOR_TABLE_SGI': 0x80BC,
-  'PROXY_TEXTURE_COLOR_TABLE_SGI': 0x80BD,
-  'UNPACK_CONSTANT_DATA_SUNX': 0x81D5,
-  'TEXTURE_CONSTANT_DATA_SUNX': 0x81D6,
-  'WRAP_BORDER_SUN': 0x81D4,
-  'GLOBAL_ALPHA_SUN': 0x81D9,
-  'GLOBAL_ALPHA_FACTOR_SUN': 0x81DA,
-  'QUAD_MESH_SUN': 0x8614,
-  'TRIANGLE_MESH_SUN': 0x8615,
-  'SLICE_ACCUM_SUN': 0x85CC,
-  'RESTART_SUN': 0x01,
-  'REPLACE_MIDDLE_SUN': 0x02,
-  'REPLACE_OLDEST_SUN': 0x03,
-  'TRIANGLE_LIST_SUN': 0x81D7,
-  'REPLACEMENT_CODE_SUN': 0x81D8,
-  'REPLACEMENT_CODE_ARRAY_SUN': 0x85C0,
-  'REPLACEMENT_CODE_ARRAY_TYPE_SUN': 0x85C1,
-  'REPLACEMENT_CODE_ARRAY_STRIDE_SUN': 0x85C2,
-  'REPLACEMENT_CODE_ARRAY_POINTER_SUN': 0x85C3,
-  'R1UI_V3F_SUN': 0x85C4,
-  'R1UI_C4UB_V3F_SUN': 0x85C5,
-  'R1UI_C3F_V3F_SUN': 0x85C6,
-  'R1UI_N3F_V3F_SUN': 0x85C7,
-  'R1UI_C4F_N3F_V3F_SUN': 0x85C8,
-  'R1UI_T2F_V3F_SUN': 0x85C9,
-  'R1UI_T2F_N3F_V3F_SUN': 0x85CA,
-  'R1UI_T2F_C4F_N3F_V3F_SUN': 0x85CB,
-  'PHONG_WIN': 0x80EA,
-  'PHONG_HINT_WIN': 0x80EB,
-  'FOG_SPECULAR_TEXTURE_WIN': 0x80EC
-};
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-post.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-post.js
deleted file mode 100644
index fd5a40f..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-post.js
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
-shouldBeTrue("successfullyParsed");
-debug('<br /><span class="pass">TEST COMPLETE</span>');
-notifyFinishedToHarness()
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-style.css b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-style.css
deleted file mode 100644
index f12147c..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-style.css
+++ /dev/null
@@ -1,12 +0,0 @@
-.pass {
-    font-weight: bold;
-    color: green;
-}
-.fail {
-    font-weight: bold;
-    color: red;
-}
-#console {
-    white-space: pre-wrap;
-    font-family: monospace;
-}
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/webgl-test-harness.js b/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/webgl-test-harness.js
deleted file mode 100644
index 4cd9eec..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/webgl-test-harness.js
+++ /dev/null
@@ -1,584 +0,0 @@
-/*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
-*/
-
-// This is a test harness for running javascript tests in the browser.
-// The only identifier exposed by this harness is WebGLTestHarnessModule.
-//
-// To use it make an HTML page with an iframe. Then call the harness like this
-//
-//    function reportResults(type, msg, success) {
-//      ...
-//      return true;
-//    }
-//
-//    var fileListURL = '00_test_list.txt';
-//    var testHarness = new WebGLTestHarnessModule.TestHarness(
-//        iframe,
-//        fileListURL,
-//        reportResults,
-//        options);
-//
-// The harness will load the fileListURL and parse it for the URLs, one URL
-// per line preceded by options, see below. URLs should be on the same domain
-// and at the  same folder level or below the main html file.  If any URL ends
-// in .txt it will be parsed as well so you can nest .txt files. URLs inside a
-// .txt file should be relative to that text file.
-//
-// During startup, for each page found the reportFunction will be called with
-// WebGLTestHarnessModule.TestHarness.reportType.ADD_PAGE and msg will be
-// the URL of the test.
-//
-// Each test is required to call testHarness.reportResults. This is most easily
-// accomplished by storing that value on the main window with
-//
-//     window.webglTestHarness = testHarness
-//
-// and then adding these to functions to your tests.
-//
-//     function reportTestResultsToHarness(success, msg) {
-//       if (window.parent.webglTestHarness) {
-//         window.parent.webglTestHarness.reportResults(success, msg);
-//       }
-//     }
-//
-//     function notifyFinishedToHarness() {
-//       if (window.parent.webglTestHarness) {
-//         window.parent.webglTestHarness.notifyFinished();
-//       }
-//     }
-//
-// This way your tests will still run without the harness and you can use
-// any testing framework you want.
-//
-// Each test should call reportTestResultsToHarness with true for success if it
-// succeeded and false if it fail followed and any message it wants to
-// associate with the test. If your testing framework supports checking for
-// timeout you can call it with success equal to undefined in that case.
-//
-// To run the tests, call testHarness.runTests(options);
-//
-// For each test run, before the page is loaded the reportFunction will be
-// called with WebGLTestHarnessModule.TestHarness.reportType.START_PAGE and msg
-// will be the URL of the test. You may return false if you want the test to be
-// skipped.
-//
-// For each test completed the reportFunction will be called with
-// with WebGLTestHarnessModule.TestHarness.reportType.TEST_RESULT,
-// success = true on success, false on failure, undefined on timeout
-// and msg is any message the test choose to pass on.
-//
-// When all the tests on the page have finished your page must call
-// notifyFinishedToHarness.  If notifyFinishedToHarness is not called
-// the harness will assume the test timed out.
-//
-// When all the tests on a page have finished OR the page as timed out the
-// reportFunction will be called with
-// WebGLTestHarnessModule.TestHarness.reportType.FINISH_PAGE
-// where success = true if the page has completed or undefined if the page timed
-// out.
-//
-// Finally, when all the tests have completed the reportFunction will be called
-// with WebGLTestHarnessModule.TestHarness.reportType.FINISHED_ALL_TESTS.
-//
-// Harness Options
-//
-// These are passed in to the TestHarness as a JavaScript object
-//
-// version: (required!)
-//
-//     Specifies a version used to filter tests. Tests marked as requiring
-//     a version greater than this version will not be included.
-//
-//     example: new TestHarness(...., {version: "3.1.2"});
-//
-// minVersion:
-//
-//     Specifies the minimum version a test must require to be included.
-//     This basically flips the filter so that only tests marked with
-//     --min-version will be included if they are at this minVersion or
-//     greater.
-//
-//     example: new TestHarness(...., {minVersion: "2.3.1"});
-//
-// fast:
-//
-//     Specifies to skip any tests marked as slow.
-//
-//     example: new TestHarness(..., {fast: true});
-//
-// Test Options:
-//
-// Any test URL or .txt file can be prefixed by the following options
-//
-// min-version:
-//
-//     Sets the minimum version requires to include this test. A version is
-//     passed into the harness options. Any test marked as requiring a
-//     min-version greater than the version passed to the harness is skipped.
-//     This allows you to add new tests to a suite of tests for a future
-//     version of the suite without including the test in the current version.
-//     If no -min-version is specified it is inheriited from the .txt file
-//     including it. The default is 1.0.0
-//
-//     example:  --min-version 2.1.3 sometest.html
-//
-// slow:
-//
-//     Marks a test as slow. Slow tests can be skipped by passing fastOnly: true
-//     to the TestHarness. Of course you need to pass all tests but sometimes
-//     you'd like to test quickly and run only the fast subset of tests.
-//
-//     example:  --slow some-test-that-takes-2-mins.html
-//
-
-WebGLTestHarnessModule = function() {
-
-/**
- * Wrapped logging function.
- */
-var log = function(msg) {
-  if (window.console && window.console.log) {
-    window.console.log(msg);
-  }
-};
-
-/**
- * Loads text from an external file. This function is synchronous.
- * @param {string} url The url of the external file.
- * @param {!function(bool, string): void} callback that is sent a bool for
- *     success and the string.
- */
-var loadTextFileAsynchronous = function(url, callback) {
-  log ("loading: " + url);
-  var error = 'loadTextFileSynchronous failed to load url "' + url + '"';
-  var request;
-  if (window.XMLHttpRequest) {
-    request = new XMLHttpRequest();
-    if (request.overrideMimeType) {
-      request.overrideMimeType('text/plain');
-    }
-  } else {
-    throw 'XMLHttpRequest is disabled';
-  }
-  try {
-    request.open('GET', url, true);
-    request.onreadystatechange = function() {
-      if (request.readyState == 4) {
-        var text = '';
-        // HTTP reports success with a 200 status. The file protocol reports
-        // success with zero. HTTP does not use zero as a status code (they
-        // start at 100).
-        // https://developer.mozilla.org/En/Using_XMLHttpRequest
-        var success = request.status == 200 || request.status == 0;
-        if (success) {
-          text = request.responseText;
-        }
-        log("loaded: " + url);
-        callback(success, text);
-      }
-    };
-    request.send(null);
-  } catch (e) {
-    log("failed to load: " + url);
-    callback(false, '');
-  }
-};
-
-/**
- * Compare version strings.
- */
-var greaterThanOrEqualToVersion = function(have, want) {
-  have = have.split(" ")[0].split(".");
-  want = want.split(" ")[0].split(".");
-
-  //have 1.2.3   want  1.1
-  //have 1.1.1   want  1.1
-  //have 1.0.9   want  1.1
-  //have 1.1     want  1.1.1
-
-  for (var ii = 0; ii < want.length; ++ii) {
-    var wantNum = parseInt(want[ii]);
-    var haveNum = have[ii] ? parseInt(have[ii]) : 0
-    if (haveNum < wantNum) {
-      return false;
-    }
-  }
-  return true;
-};
-
-/**
- * Reads a file, recursively adding files referenced inside.
- *
- * Each line of URL is parsed, comments starting with '#' or ';'
- * or '//' are stripped.
- *
- * arguments beginning with -- are extracted
- *
- * lines that end in .txt are recursively scanned for more files
- * other lines are added to the list of files.
- *
- * @param {string} url The url of the file to read.
- * @param {void function(boolean, !Array.<string>)} callback.
- *      Callback that is called with true for success and an
- *      array of filenames.
- * @param {Object} options. Optional options
- *
- * Options:
- *    version: {string} The version of the conformance test.
- *    Tests with the argument --min-version <version> will
- *    be ignored version is less then <version>
- *
- */
-var getFileList = function(url, callback, options) {
-  var files = [];
-
-  var copyObject = function(obj) {
-    return JSON.parse(JSON.stringify(obj));
-  };
-
-  var toCamelCase = function(str) {
-    return str.replace(/-([a-z])/g, function (g) { return g[1].toUpperCase() });
-  };
-
-  var globalOptions = copyObject(options);
-  globalOptions.defaultVersion = "1.0";
-
-  var getFileListImpl = function(prefix, line, lineNum, hierarchicalOptions, callback) {
-    var files = [];
-
-    var args = line.split(/\s+/);
-    var nonOptions = [];
-    var useTest = true;
-    var testOptions = {};
-    for (var jj = 0; jj < args.length; ++jj) {
-      var arg = args[jj];
-      if (arg[0] == '-') {
-        if (arg[1] != '-') {
-          throw ("bad option at in " + url + ":" + lineNum + ": " + arg);
-        }
-        var option = arg.substring(2);
-        switch (option) {
-          // no argument options.
-          case 'slow':
-            testOptions[toCamelCase(option)] = true;
-            break;
-          // one argument options.
-          case 'min-version':
-            ++jj;
-            testOptions[toCamelCase(option)] = args[jj];
-            break;
-          default:
-            throw ("bad unknown option '" + option + "' at in " + url + ":" + lineNum + ": " + arg);
-        }
-      } else {
-        nonOptions.push(arg);
-      }
-    }
-    var url = prefix + nonOptions.join(" ");
-
-    if (url.substr(url.length - 4) != '.txt') {
-      var minVersion = testOptions.minVersion;
-      if (!minVersion) {
-        minVersion = hierarchicalOptions.defaultVersion;
-      }
-      var slow = testOptions.slow;
-      if (!slow) {
-        slow = hierarchicalOptions.defaultSlow;
-      }
-
-      if (globalOptions.fast && slow) {
-        useTest = false;
-      } else if (globalOptions.minVersion) {
-        useTest = greaterThanOrEqualToVersion(minVersion, globalOptions.minVersion);
-      } else {
-        useTest = greaterThanOrEqualToVersion(globalOptions.version, minVersion);
-      }
-    }
-
-    if (!useTest) {
-      callback(true, []);
-      return;
-    }
-
-    if (url.substr(url.length - 4) == '.txt') {
-      // If a version was explicity specified pass it down.
-      if (testOptions.minVersion) {
-        hierarchicalOptions.defaultVersion = testOptions.minVersion;
-      }
-      if (testOptions.slow) {
-        hierarchicalOptions.defaultSlow = testOptions.slow;
-      }
-      loadTextFileAsynchronous(url, function() {
-        return function(success, text) {
-          if (!success) {
-            callback(false, '');
-            return;
-          }
-          var lines = text.split('\n');
-          var prefix = '';
-          var lastSlash = url.lastIndexOf('/');
-          if (lastSlash >= 0) {
-            prefix = url.substr(0, lastSlash + 1);
-          }
-          var fail = false;
-          var count = 1;
-          var index = 0;
-          for (var ii = 0; ii < lines.length; ++ii) {
-            var str = lines[ii].replace(/^\s\s*/, '').replace(/\s\s*$/, '');
-            if (str.length > 4 &&
-                str[0] != '#' &&
-                str[0] != ";" &&
-                str.substr(0, 2) != "//") {
-              ++count;
-              getFileListImpl(prefix, str, ii + 1, copyObject(hierarchicalOptions), function(index) {
-                return function(success, new_files) {
-                  //log("got files: " + new_files.length);
-                  if (success) {
-                    files[index] = new_files;
-                  }
-                  finish(success);
-                };
-              }(index++));
-            }
-          }
-          finish(true);
-
-          function finish(success) {
-            if (!success) {
-              fail = true;
-            }
-            --count;
-            //log("count: " + count);
-            if (!count) {
-              callback(!fail, files);
-            }
-          }
-        }
-      }());
-    } else {
-      files.push(url);
-      callback(true, files);
-    }
-  };
-
-  getFileListImpl('', url, 1, globalOptions, function(success, files) {
-    // flatten
-    var flat = [];
-    flatten(files);
-    function flatten(files) {
-      for (var ii = 0; ii < files.length; ++ii) {
-        var value = files[ii];
-        if (typeof(value) == "string") {
-          flat.push(value);
-        } else {
-          flatten(value);
-        }
-      }
-    }
-    callback(success, flat);
-  });
-};
-
-var FilterURL = (function() {
-  var prefix = window.location.pathname;
-  prefix = prefix.substring(0, prefix.lastIndexOf("/") + 1);
-  return function(url) {
-    if (url.substring(0, prefix.length) == prefix) {
-      url = url.substring(prefix.length);
-    }
-    return url;
-  };
-}());
-
-var TestFile = function(url) {
-  this.url = url;
-};
-
-var Test = function(file) {
-  this.file = file;
-};
-
-var TestHarness = function(iframe, filelistUrl, reportFunc, options) {
-  this.window = window;
-  this.iframes = iframe.length ? iframe : [iframe];
-  this.reportFunc = reportFunc;
-  this.timeoutDelay = 20000;
-  this.files = [];
-  this.allowSkip = options.allowSkip;
-
-  var that = this;
-  getFileList(filelistUrl, function() {
-    return function(success, files) {
-      that.addFiles_(success, files);
-    };
-  }(), options);
-
-};
-
-TestHarness.reportType = {
-  ADD_PAGE: 1,
-  READY: 2,
-  START_PAGE: 3,
-  TEST_RESULT: 4,
-  FINISH_PAGE: 5,
-  FINISHED_ALL_TESTS: 6
-};
-
-TestHarness.prototype.addFiles_ = function(success, files) {
-  if (!success) {
-    this.reportFunc(
-        TestHarness.reportType.FINISHED_ALL_TESTS,
-        '',
-        'Unable to load tests. Are you running locally?\n' +
-        'You need to run from a server or configure your\n' +
-        'browser to allow access to local files (not recommended).\n\n' +
-        'Note: An easy way to run from a server:\n\n' +
-        '\tcd path_to_tests\n' +
-        '\tpython -m SimpleHTTPServer\n\n' +
-        'then point your browser to ' +
-          '<a href="http://localhost:8000/webgl-conformance-tests.html">' +
-          'http://localhost:8000/webgl-conformance-tests.html</a>',
-        false)
-    return;
-  }
-  log("total files: " + files.length);
-  for (var ii = 0; ii < files.length; ++ii) {
-    log("" + ii + ": " + files[ii]);
-    this.files.push(new TestFile(files[ii]));
-    this.reportFunc(TestHarness.reportType.ADD_PAGE, '', files[ii], undefined);
-  }
-  this.reportFunc(TestHarness.reportType.READY, '', undefined, undefined);
-}
-
-TestHarness.prototype.runTests = function(opt_options) {
-  var options = opt_options || { };
-  options.start = options.start || 0;
-  options.count = options.count || this.files.length;
-
-  this.idleIFrames = this.iframes.slice(0);
-  this.runningTests = {};
-  var testsToRun = [];
-  for (var ii = 0; ii < options.count; ++ii) {
-    testsToRun.push(ii + options.start);
-  }
-  this.numTestsRemaining = options.count;
-  this.testsToRun = testsToRun;
-  this.startNextTest();
-};
-
-TestHarness.prototype.setTimeout = function(test) {
-  var that = this;
-  test.timeoutId = this.window.setTimeout(function() {
-      that.timeout(test);
-    }, this.timeoutDelay);
-};
-
-TestHarness.prototype.clearTimeout = function(test) {
-  this.window.clearTimeout(test.timeoutId);
-};
-
-TestHarness.prototype.startNextTest = function() {
-  if (this.numTestsRemaining == 0) {
-    log("done");
-    this.reportFunc(TestHarness.reportType.FINISHED_ALL_TESTS,
-                    '', '', true);
-  } else {
-    while (this.testsToRun.length > 0 && this.idleIFrames.length > 0) {
-      var testId = this.testsToRun.shift();
-      var iframe = this.idleIFrames.shift();
-      this.startTest(iframe, this.files[testId]);
-    }
-  }
-};
-
-TestHarness.prototype.startTest = function(iframe, testFile) {
-  var test = {
-    iframe: iframe,
-    testFile: testFile
-  };
-  var url = testFile.url;
-  this.runningTests[url] = test;
-  log("loading: " + url);
-  if (this.reportFunc(TestHarness.reportType.START_PAGE, url, url, undefined)) {
-    iframe.src = url;
-    this.setTimeout(test);
-  } else {
-    this.reportResults(url, !!this.allowSkip, "skipped", true);
-    this.notifyFinished(url);
-  }
-};
-
-TestHarness.prototype.getTest = function(url) {
-  var test = this.runningTests[FilterURL(url)];
-  if (!test) {
-    throw("unknown test:" + url);
-  }
-  return test;
-};
-
-TestHarness.prototype.reportResults = function(url, success, msg, skipped) {
-  url = FilterURL(url);
-  var test = this.getTest(url);
-  this.clearTimeout(test);
-  log(success ? "PASS" : "FAIL", msg);
-  this.reportFunc(TestHarness.reportType.TEST_RESULT, url, msg, success, skipped);
-  // For each result we get, reset the timeout
-  this.setTimeout(test);
-};
-
-TestHarness.prototype.dequeTest = function(test) {
-  this.clearTimeout(test);
-  this.idleIFrames.push(test.iframe);
-  delete this.runningTests[test.testFile.url];
-  --this.numTestsRemaining;
-}
-
-TestHarness.prototype.notifyFinished = function(url) {
-  url = FilterURL(url);
-  var test = this.getTest(url);
-  log(url + ": finished");
-  this.dequeTest(test);
-  this.reportFunc(TestHarness.reportType.FINISH_PAGE, url, url, true);
-  this.startNextTest();
-};
-
-TestHarness.prototype.timeout = function(test) {
-  this.dequeTest(test);
-  var url = test.testFile.url;
-  log(url + ": timeout");
-  this.reportFunc(TestHarness.reportType.FINISH_PAGE, url, url, undefined);
-  this.startNextTest();
-};
-
-TestHarness.prototype.setTimeoutDelay = function(x) {
-  this.timeoutDelay = x;
-};
-
-return {
-    'TestHarness': TestHarness
-  };
-
-}();
-
-
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/texImage2DHTML-expected.txt b/LayoutTests/http/tests/webgl/1.0.2/texImage2DHTML-expected.txt
deleted file mode 100644
index a2be55d..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/texImage2DHTML-expected.txt
+++ /dev/null
@@ -1,5 +0,0 @@
-This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
-
-Test: resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html
-PASS
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/texImage2DHTML.html b/LayoutTests/http/tests/webgl/1.0.2/texImage2DHTML.html
deleted file mode 100644
index a8f92b9..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/texImage2DHTML.html
+++ /dev/null
@@ -1,18 +0,0 @@
-<!-- This file is auto-generated by generate-webgl-tests.py. DO NOT EDIT -->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Conformance Test Wrapper for texImage2DHTML.html</title>
-<script type="text/javascript" src="resources/conformance/resources/js-test-pre.js"></script>
-<script type="text/javascript" src="resources/webkit-webgl-test-harness.js"></script>
-</head>
-<body>
-<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
-Test: <a href="resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html">resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html</a>
-<div id="result"></div>
-<div id="iframe">
-<iframe src="resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html" width="800" height="600"></iframe>
-</div>
-</body>
-</html>
diff --git a/LayoutTests/http/tests/webgl/1.0.2/texSubImage2DHTML-expected.txt b/LayoutTests/http/tests/webgl/1.0.2/texSubImage2DHTML-expected.txt
deleted file mode 100644
index 4c43d6a..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/texSubImage2DHTML-expected.txt
+++ /dev/null
@@ -1,5 +0,0 @@
-This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
-
-Test: resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html
-PASS
-
diff --git a/LayoutTests/http/tests/webgl/1.0.2/texSubImage2DHTML.html b/LayoutTests/http/tests/webgl/1.0.2/texSubImage2DHTML.html
deleted file mode 100644
index 7fad7e5..0000000
--- a/LayoutTests/http/tests/webgl/1.0.2/texSubImage2DHTML.html
+++ /dev/null
@@ -1,18 +0,0 @@
-<!-- This file is auto-generated by generate-webgl-tests.py. DO NOT EDIT -->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Conformance Test Wrapper for texSubImage2DHTML.html</title>
-<script type="text/javascript" src="resources/conformance/resources/js-test-pre.js"></script>
-<script type="text/javascript" src="resources/webkit-webgl-test-harness.js"></script>
-</head>
-<body>
-<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
-Test: <a href="resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html">resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html</a>
-<div id="result"></div>
-<div id="iframe">
-<iframe src="resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html" width="800" height="600"></iframe>
-</div>
-</body>
-</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt b/LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt
similarity index 64%
rename from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt
index d8c32de..ada59cb 100644
--- a/LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt
+++ b/LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs-expected.txt
@@ -1,3 +1,4 @@
+CONSOLE MESSAGE: Unable to get image data from canvas because the canvas has been tainted by cross-origin data.
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
 Test: ../../../../resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html
diff --git a/LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html b/LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html
similarity index 100%
rename from LayoutTests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/readPixelsBadArgs.html
diff --git a/LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt b/LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt
similarity index 100%
rename from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/texImage2DHTML-expected.txt
diff --git a/LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML.html b/LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/texImage2DHTML.html
similarity index 100%
rename from LayoutTests/webgl/1.0.x/conformance/more/functions/texImage2DHTML.html
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/texImage2DHTML.html
diff --git a/LayoutTests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML-expected.txt b/LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML-expected.txt
similarity index 100%
rename from LayoutTests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML-expected.txt
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML-expected.txt
diff --git a/LayoutTests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML.html b/LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML.html
similarity index 100%
rename from LayoutTests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML.html
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/more/functions/texSubImage2DHTML.html
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt b/LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
similarity index 83%
rename from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
index 29cb42a..effac97 100644
--- a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
+++ b/LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
@@ -1,3 +1,4 @@
+CONSOLE MESSAGE: [loadCrossOriginImage]
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
 Test: ../../../../resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt b/LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
similarity index 84%
rename from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
index a04d796..b2d672e 100644
--- a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
+++ b/LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
@@ -1,3 +1,4 @@
+CONSOLE MESSAGE: [loadCrossOriginImage]
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
 Test: ../../../../resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html b/LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
similarity index 100%
rename from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance.html b/LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance.html
similarity index 100%
rename from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance.html
rename to LayoutTests/http/tests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance.html
diff --git a/LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt b/LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt
similarity index 66%
rename from LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt
index d480a44..5756c22 100644
--- a/LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt
+++ b/LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs-expected.txt
@@ -1,3 +1,4 @@
+CONSOLE MESSAGE: Unable to get image data from canvas because the canvas has been tainted by cross-origin data.
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
 Test: ../../../../resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html?webglVersion=2
diff --git a/LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs.html b/LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs.html
similarity index 100%
rename from LayoutTests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs.html
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/readPixelsBadArgs.html
diff --git a/LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML-expected.txt b/LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/texImage2DHTML-expected.txt
similarity index 100%
rename from LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML-expected.txt
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/texImage2DHTML-expected.txt
diff --git a/LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html b/LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html
similarity index 100%
rename from LayoutTests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/texImage2DHTML.html
diff --git a/LayoutTests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML-expected.txt b/LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML-expected.txt
similarity index 100%
rename from LayoutTests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML-expected.txt
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML-expected.txt
diff --git a/LayoutTests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML.html b/LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML.html
similarity index 100%
rename from LayoutTests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML.html
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/more/functions/texSubImage2DHTML.html
diff --git a/LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-expected.txt b/LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-expected.txt
similarity index 84%
rename from LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-expected.txt
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-expected.txt
index f990f24..a4daf90 100644
--- a/LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-expected.txt
+++ b/LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-expected.txt
@@ -1,3 +1,4 @@
+CONSOLE MESSAGE: [loadCrossOriginImage]
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
 Test: ../../../../resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html?webglVersion=2
diff --git a/LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt b/LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
similarity index 85%
rename from LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
index 2437f19..f94f43c 100644
--- a/LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
+++ b/LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
@@ -1,3 +1,4 @@
+CONSOLE MESSAGE: [loadCrossOriginImage]
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
 Test: ../../../../resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html?webglVersion=2
diff --git a/LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html b/LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
similarity index 100%
rename from LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
diff --git a/LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance.html b/LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance.html
similarity index 100%
rename from LayoutTests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance.html
rename to LayoutTests/http/tests/webgl/2.0.y/conformance/textures/misc/origin-clean-conformance.html
diff --git a/LayoutTests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt b/LayoutTests/http/tests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
similarity index 85%
rename from LayoutTests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
rename to LayoutTests/http/tests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
index caf3a50..a026f60 100644
--- a/LayoutTests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
+++ b/LayoutTests/http/tests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
@@ -1,3 +1,4 @@
+CONSOLE MESSAGE: [loadCrossOriginImage]
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
 Test: ../../../../resources/webgl_test_files/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html?webglVersion=2
diff --git a/LayoutTests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html b/LayoutTests/http/tests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html
similarity index 100%
rename from LayoutTests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html
rename to LayoutTests/http/tests/webgl/2.0.y/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js b/LayoutTests/http/tests/webgl/resources/js-test-pre.js
similarity index 89%
rename from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js
rename to LayoutTests/http/tests/webgl/resources/js-test-pre.js
index 184956e..75bdbce 100644
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js
+++ b/LayoutTests/http/tests/webgl/resources/js-test-pre.js
@@ -24,7 +24,7 @@
 (function() {
   var testHarnessInitialized = false;
 
-  var initNonKhronosFramework = function(waitUntilDone) {
+  var initNonKhronosFramework = function() {
     if (testHarnessInitialized) {
       return;
     }
@@ -58,12 +58,8 @@
     /* -- end platform specific code --*/
   }
 
-  this.initTestingHarnessWaitUntilDone = function() {
-    initNonKhronosFramework(true);
-  }
-
   this.initTestingHarness = function() {
-    initNonKhronosFramework(false);
+    initNonKhronosFramework();
   }
 }());
 
@@ -89,6 +85,19 @@
   }
 }
 
+function _logToConsole(msg)
+{
+    if (window.console)
+      window.console.log(msg);
+}
+
+var _jsTestPreVerboseLogging = false;
+
+function enableJSTestPreVerboseLogging()
+{
+    _jsTestPreVerboseLogging = true;
+}
+
 function description(msg)
 {
     initTestingHarness();
@@ -103,13 +112,24 @@
         description.replaceChild(span, description.firstChild);
     else
         description.appendChild(span);
+    if (_jsTestPreVerboseLogging) {
+        _logToConsole(msg);
+    }
+}
+
+function _addSpan(contents)
+{
+    var span = document.createElement("span");
+    document.getElementById("console").appendChild(span); // insert it first so XHTML knows the namespace
+    span.innerHTML = contents + '<br />';
 }
 
 function debug(msg)
 {
-    var span = document.createElement("span");
-    document.getElementById("console").appendChild(span); // insert it first so XHTML knows the namespace
-    span.innerHTML = msg + '<br />';
+    _addSpan(msg);
+    if (_jsTestPreVerboseLogging) {
+	_logToConsole(msg);
+    }
 }
 
 function escapeHTML(text)
@@ -120,13 +140,17 @@
 function testPassed(msg)
 {
     reportTestResultsToHarness(true, msg);
-    debug('<span><span class="pass">PASS</span> ' + escapeHTML(msg) + '</span>');
+    _addSpan('<span><span class="pass">PASS</span> ' + escapeHTML(msg) + '</span>');
+    if (_jsTestPreVerboseLogging) {
+	_logToConsole('PASS ' + msg);
+    }
 }
 
 function testFailed(msg)
 {
     reportTestResultsToHarness(false, msg);
-    debug('<span><span class="fail">FAIL</span> ' + escapeHTML(msg) + '</span>');
+    _addSpan('<span><span class="fail">FAIL</span> ' + escapeHTML(msg) + '</span>');
+    _logToConsole('FAIL ' + msg);
 }
 
 function areArraysEqual(_a, _b)
@@ -410,21 +434,32 @@
 }
 
 function shouldBeType(_a, _type) {
-	var exception;
-	var _av;
-	try {
-		_av = eval(_a);
-	} catch (e) {
-		exception = e;
-	}
+    var exception;
+    var _av;
+    try {
+        _av = eval(_a);
+    } catch (e) {
+        exception = e;
+    }
 
-	var _typev = eval(_type);
+    var _typev = eval(_type);
 
-	if (_av instanceof _typev) {
-		testPassed(_a + " is an instance of " + _type);
-	} else {
-		testFailed(_a + " is not an instance of " + _type);
-	}
+    if(_typev === Number){
+        if(_av instanceof Number){
+            testPassed(_a + " is an instance of Number");
+        }
+        else if(typeof(_av) === 'number'){
+            testPassed(_a + " is an instance of Number");
+        }
+        else{
+            testFailed(_a + " is not an instance of Number");
+        }
+    }
+    else if (_av instanceof _typev) {
+        testPassed(_a + " is an instance of " + _type);
+    } else {
+        testFailed(_a + " is not an instance of " + _type);
+    }
 }
 
 function assertMsg(assertion, msg) {
@@ -467,7 +502,6 @@
 function finishTest() {
   successfullyParsed = true;
   var epilogue = document.createElement("script");
-
   var basePath = "";
   var expectedBase = "js-test-pre.js";
   var scripts = document.getElementsByTagName('script');
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html
similarity index 100%
rename from LayoutTests/webgl/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/functions/readPixelsBadArgs.html
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html
similarity index 100%
rename from LayoutTests/webgl/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/functions/texImage2DHTML.html
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html
similarity index 100%
rename from LayoutTests/webgl/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/functions/texSubImage2DHTML.html
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.css b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/unit.css
similarity index 100%
rename from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.css
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/unit.css
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.js b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/unit.js
similarity index 84%
rename from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.js
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/unit.js
index 706be55..3ca21c4 100644
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/unit.js
+++ b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/unit.js
@@ -3,26 +3,9 @@
 */
 
 /*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
 */
 
 /* -- plaform specific code -- */
@@ -57,6 +40,7 @@
   autorun : true,
   message : null,
   delay : 0,
+  autoinit: true,
 
   startUnit : function(){ return []; },
   setup : function() { return arguments; },
@@ -69,6 +53,46 @@
 var __testLog__;
 var __backlog__ = [];
 
+var getUrlOptions = (function() {
+  var _urlOptionsParsed = false;
+  var _urlOptions = {};
+  return function() {
+    if (!_urlOptionsParsed) {
+      var s = window.location.href;
+      var q = s.indexOf("?");
+      var e = s.indexOf("#");
+      if (e < 0) {
+        e = s.length;
+      }
+      var query = s.substring(q + 1, e);
+      var pairs = query.split("&");
+      for (var ii = 0; ii < pairs.length; ++ii) {
+        var keyValue = pairs[ii].split("=");
+        var key = keyValue[0];
+        var value = decodeURIComponent(keyValue[1]);
+        _urlOptions[key] = value;
+      }
+      _urlOptionsParsed = true;
+    }
+
+    return _urlOptions;
+  }
+})();
+
+if (typeof quietMode == 'undefined') {
+  var quietMode = (function() {
+    var _quietModeChecked = false;
+    var _isQuiet = false;
+    return function() {
+      if (!_quietModeChecked) {
+        _isQuiet = (getUrlOptions().quiet == 1);
+        _quietModeChecked = true;
+      }
+      return _isQuiet;
+    }
+  })();
+}
+
 Object.toSource = function(a, seen){
   if (a == null) return "null";
   if (typeof a == 'boolean') return a ? "true" : "false";
@@ -238,26 +262,28 @@
 }
 
 function testPassed(assertName, name) {
-  var d = document.createElement('div');
-  var h = document.createElement('h3');
-  var d1 = document.createElement("span");
-  h.appendChild(d1);
-  d1.appendChild(document.createTextNode("PASS: "));
-  d1.style.color = "green";
-  h.appendChild(document.createTextNode(
-      name==null ? assertName : name + " (in " + assertName + ")"));
-  d.appendChild(h);
-  var args = []
-  for (var i=2; i<arguments.length; i++) {
-    var a = arguments[i];
-    var p = document.createElement('p');
-    p.style.whiteSpace = 'pre';
-    p.textContent = (a == null) ? "null" :
-                    (typeof a == 'boolean' || typeof a == 'string') ? a : Object.toSource(a);
-    args.push(p.textContent);
-    d.appendChild(p);
+  if (!quietMode()) {
+    var d = document.createElement('div');
+    var h = document.createElement('h3');
+    var d1 = document.createElement("span");
+    h.appendChild(d1);
+    d1.appendChild(document.createTextNode("PASS: "));
+    d1.style.color = "green";
+    h.appendChild(document.createTextNode(
+        name==null ? assertName : name + " (in " + assertName + ")"));
+    d.appendChild(h);
+    var args = []
+    for (var i=2; i<arguments.length; i++) {
+      var a = arguments[i];
+      var p = document.createElement('p');
+      p.style.whiteSpace = 'pre';
+      p.textContent = (a == null) ? "null" :
+                      (typeof a == 'boolean' || typeof a == 'string') ? a : Object.toSource(a);
+      args.push(p.textContent);
+      d.appendChild(p);
+    }
+    __testLog__.appendChild(d);
   }
-  __testLog__.appendChild(d);
   doTestNotify([assertName, name].concat(args).join("--"));
 }
 
@@ -389,6 +415,38 @@
   return true;
 }
 
+function assertArrayEqualsWithEpsilon(name, v, p, l) {
+  if (l == null) { l = p; p = v; v = name; name = null; }
+  if (!v) {
+    testFailed("assertArrayEqualsWithEpsilon: first array undefined", name, v, p);
+    return false;
+  }
+  if (!p) {
+    testFailed("assertArrayEqualsWithEpsilon: second array undefined", name, v, p);
+    return false;
+  }
+  if (!l) {
+    testFailed("assertArrayEqualsWithEpsilon: limit array undefined", name, v, p);
+    return false;
+  }
+  if (v.length != p.length) {
+    testFailed("assertArrayEqualsWithEpsilon", name, v, p, l);
+    return false;
+  }
+  if (v.length != l.length) {
+    testFailed("assertArrayEqualsWithEpsilon", name, v, p, l);
+    return false;
+  }
+  for (var ii = 0; ii < v.length; ++ii) {
+    if (Math.abs(v[ii]- p[ii])>l[ii]) {
+      testFailed("assertArrayEqualsWithEpsilon", name, v, p, l);
+      return false;
+    }
+  }
+  testPassed("assertArrayEqualsWithEpsilon", name, v, p, l);
+  return true;
+}
+
 function assertNotEquals(name, v, p) {
   if (p == null) { p = v; v = name; name = null; }
   if (compare(v, p)) {
@@ -901,10 +959,12 @@
 }
 
 window.addEventListener('load', function(){
-  // let the browser hopefully finish updating the gl canvas surfaces if we are given a delay
-  if (Tests.delay)
-    setTimeout(initTests, Tests.delay);
-  else
-    initTests()
+  if (Tests.autoinit) {
+    // let the browser hopefully finish updating the gl canvas surfaces if we are given a delay
+    if (Tests.delay)
+      setTimeout(initTests, Tests.delay);
+    else
+      initTests()
+  }
 }, false);
 
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/util.js b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/util.js
similarity index 95%
rename from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/util.js
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/util.js
index 2366caf..78cc08a 100644
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/conformance/more/util.js
+++ b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/more/util.js
@@ -3,26 +3,9 @@
 */
 
 /*
-** Copyright (c) 2012 The Khronos Group Inc.
-**
-** Permission is hereby granted, free of charge, to any person obtaining a
-** copy of this software and/or associated documentation files (the
-** "Materials"), to deal in the Materials without restriction, including
-** without limitation the rights to use, copy, modify, merge, publish,
-** distribute, sublicense, and/or sell copies of the Materials, and to
-** permit persons to whom the Materials are furnished to do so, subject to
-** the following conditions:
-**
-** The above copyright notice and this permission notice shall be included
-** in all copies or substantial portions of the Materials.
-**
-** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
 */
 
 function loadTexture(gl, elem, mipmaps) {
@@ -841,7 +824,7 @@
     if (!this.initialized) this.init();
     var gl = this.gl;
     for (var i=0; i<arguments.length; i++) {
-      if (arguments[i] == null) continue;
+      if (arguments[i] == null || arguments[i] == -1) continue;
       gl.bindBuffer(gl.ARRAY_BUFFER, this.vbos[i]);
       gl.vertexAttribPointer(arguments[i], this.data[i].size, gl.FLOAT, false, 0, 0);
       gl.enableVertexAttribArray(arguments[i]);
@@ -1020,6 +1003,40 @@
   return true;
 }
 
+// Assert that f generates a GL error from a list.
+function assertGLErrorIn(gl, expectedErrorList, name, f) {
+  if (f == null) { f = name; name = null; }
+
+  var actualError = 0;
+  try {
+    f();
+  } catch(e) {
+    if ('glError' in e) {
+      actualError = e.glError;
+    } else {
+      testFailed("assertGLError: UNEXPCETED EXCEPTION", name, f);
+      return false;
+    }
+  }
+
+  var expectedErrorStrList = [];
+  var expectedErrorSet = {};
+  for (var i in expectedErrorList) {
+    var cur = expectedErrorList[i];
+    expectedErrorSet[cur] = true;
+    expectedErrorStrList.push(getGLErrorAsString(gl, cur));
+  }
+  var expectedErrorListStr = "[" + expectedErrorStrList.join(", ") + "]";
+
+  if (actualError in expectedErrorSet) {
+    return true;
+  }
+
+  testFailed("assertGLError: expected: " + expectedErrorListStr +
+             " actual: " + getGLErrorAsString(gl, actualError), name, f);
+  return false;
+}
+
 // Assert that f generates some GL error. Used in situations where it's
 // ambigious which of multiple possible errors will be generated.
 function assertSomeGLError(gl, name, f) {
@@ -1063,6 +1080,24 @@
   return true;
 }
 
+function assertThrows(gl, shouldThrow, info, func) {
+  var didThrow = false;
+  try {
+    func();
+  } catch (e) {
+    var didGLError = (e instanceof GLError);
+    if (!didGLError) {
+      didThrow = true;
+    }
+  }
+
+  var text = shouldThrow ? "Should throw: "
+                         : "Should not throw: ";
+  var func = (didThrow == shouldThrow) ? testPassed : testFailed;
+
+  func(text + info);
+}
+
 Quad = {
   vertices : [
     -1,-1,0,
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
similarity index 100%
rename from LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html
similarity index 100%
rename from LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html b/LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html
similarity index 100%
rename from LayoutTests/webgl/resources/webgl_test_files/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html
rename to LayoutTests/http/tests/webgl/resources/webgl_test_files/conformance2/textures/misc/origin-clean-conformance-offscreencanvas.html
diff --git a/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/js-test-post.js b/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/js-test-post.js
new file mode 100644
index 0000000..23df550
--- /dev/null
+++ b/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/js-test-post.js
@@ -0,0 +1,27 @@
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+shouldBeTrue("successfullyParsed");
+_addSpan('<br /><span class="pass">TEST COMPLETE</span>');
+if (_jsTestPreVerboseLogging) {
+    _bufferedLogToConsole('TEST COMPLETE');
+}
+
+{
+    const e_results = document.createElement('div');
+    let fails_class = 'pass';
+    if (RESULTS.fail) {
+        fails_class = 'fail';
+    }
+    e_results.classList.add('pass');
+    e_results.innerHTML = `<p>TEST COMPLETE: ${RESULTS.pass} PASS, ` +
+      `<span class="${fails_class}">${RESULTS.fail} FAIL</span></p>`;
+
+    const e_desc = document.getElementById("description");
+    e_desc.appendChild(e_results);
+}
+
+notifyFinishedToHarness()
diff --git a/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/js-test-pre.js b/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/js-test-pre.js
new file mode 100644
index 0000000..e1cb9f7
--- /dev/null
+++ b/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/js-test-pre.js
@@ -0,0 +1,801 @@
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+(function() {
+  var testHarnessInitialized = false;
+
+  var initNonKhronosFramework = function() {
+    if (testHarnessInitialized) {
+      return;
+    }
+    testHarnessInitialized = true;
+
+    /* -- plaform specific code -- */
+
+    // WebKit Specific code. Add your code here.
+    if (window.testRunner && !window.layoutTestController) {
+      window.layoutTestController = window.testRunner;
+    }
+
+    if (window.layoutTestController) {
+      window.layoutTestController.dumpAsText();
+      window.layoutTestController.waitUntilDone();
+    }
+    if (window.internals) {
+      // The WebKit testing system compares console output.
+      // Because the output of the WebGL Tests is GPU dependent
+      // we turn off console messages.
+      window.console.log = function() { };
+      window.console.error = function() { };
+      window.internals.settings.setWebGLErrorsToConsoleEnabled(false);
+    }
+
+    /* -- end platform specific code --*/
+  }
+
+  this.initTestingHarness = function() {
+    initNonKhronosFramework();
+  }
+}());
+
+var getUrlOptions = (function() {
+  var _urlOptionsParsed = false;
+  var _urlOptions = {};
+  return function() {
+    if (!_urlOptionsParsed) {
+      var s = window.location.href;
+      var q = s.indexOf("?");
+      var e = s.indexOf("#");
+      if (e < 0) {
+        e = s.length;
+      }
+      var query = s.substring(q + 1, e);
+      var pairs = query.split("&");
+      for (var ii = 0; ii < pairs.length; ++ii) {
+        var keyValue = pairs[ii].split("=");
+        var key = keyValue[0];
+        var value = decodeURIComponent(keyValue[1]);
+        _urlOptions[key] = value;
+      }
+      _urlOptionsParsed = true;
+    }
+
+    return _urlOptions;
+  }
+})();
+
+if (typeof quietMode == 'undefined') {
+  var quietMode = (function() {
+    var _quietModeChecked = false;
+    var _isQuiet = false;
+    return function() {
+      if (!_quietModeChecked) {
+        _isQuiet = (getUrlOptions().quiet == 1);
+        _quietModeChecked = true;
+      }
+      return _isQuiet;
+    }
+  })();
+}
+
+function nonKhronosFrameworkNotifyDone() {
+  // WebKit Specific code. Add your code here.
+  if (window.layoutTestController) {
+    window.layoutTestController.notifyDone();
+  }
+}
+
+const RESULTS = {
+  pass: 0,
+  fail: 0,
+};
+
+function reportTestResultsToHarness(success, msg) {
+  if (success) {
+    RESULTS.pass += 1;
+  } else {
+    RESULTS.fail += 1;
+  }
+  if (window.parent.webglTestHarness) {
+    window.parent.webglTestHarness.reportResults(window.location.pathname, success, msg);
+  }
+}
+
+function reportSkippedTestResultsToHarness(success, msg) {
+  if (window.parent.webglTestHarness) {
+    window.parent.webglTestHarness.reportResults(window.location.pathname, success, msg, true);
+  }
+}
+
+function notifyFinishedToHarness() {
+  if (window._didNotifyFinishedToHarness) {
+    testFailed("Duplicate notifyFinishedToHarness()");
+  }
+  window._didNotifyFinishedToHarness = true;
+
+  if (window.parent.webglTestHarness) {
+    window.parent.webglTestHarness.notifyFinished(window.location.pathname);
+  }
+  if (window.nonKhronosFrameworkNotifyDone) {
+    window.nonKhronosFrameworkNotifyDone();
+  }
+}
+
+var _bufferedConsoleLogs = [];
+
+function _bufferedLogToConsole(msg)
+{
+  if (_bufferedConsoleLogs) {
+    _bufferedConsoleLogs.push(msg);
+  } else if (window.console) {
+    window.console.log(msg);
+  }
+}
+
+// Public entry point exposed to many other files.
+function bufferedLogToConsole(msg)
+{
+  _bufferedLogToConsole(msg);
+}
+
+// Called implicitly by testFailed().
+function _flushBufferedLogsToConsole()
+{
+  if (_bufferedConsoleLogs) {
+    if (window.console) {
+      for (var ii = 0; ii < _bufferedConsoleLogs.length; ++ii) {
+        window.console.log(_bufferedConsoleLogs[ii]);
+      }
+    }
+    _bufferedConsoleLogs = null;
+  }
+}
+
+var _jsTestPreVerboseLogging = false;
+
+function enableJSTestPreVerboseLogging()
+{
+    _jsTestPreVerboseLogging = true;
+}
+
+function description(msg)
+{
+    initTestingHarness();
+    if (msg === undefined) {
+      msg = document.title;
+    }
+    // For MSIE 6 compatibility
+    var span = document.createElement("span");
+    span.innerHTML = '<p>' + msg + '</p><p>On success, you will see a series of "<span class="pass">PASS</span>" messages, followed by "<span class="pass">TEST COMPLETE</span>".</p>';
+    var description = document.getElementById("description");
+    if (description.firstChild)
+        description.replaceChild(span, description.firstChild);
+    else
+        description.appendChild(span);
+    if (_jsTestPreVerboseLogging) {
+        _bufferedLogToConsole(msg);
+    }
+}
+
+function _addSpan(contents)
+{
+    var span = document.createElement("span");
+    document.getElementById("console").appendChild(span); // insert it first so XHTML knows the namespace
+    span.innerHTML = contents + '<br />';
+}
+
+function debug(msg)
+{
+    if (!quietMode())
+      _addSpan(msg);
+    if (_jsTestPreVerboseLogging) {
+        _bufferedLogToConsole(msg);
+    }
+}
+
+function escapeHTML(text)
+{
+    return text.replace(/&/g, "&amp;").replace(/</g, "&lt;");
+}
+/**
+ * Defines the exception type for a test failure.
+ * @constructor
+ * @param {string} message The error message.
+ */
+var TestFailedException = function (message) {
+   this.message = message;
+   this.name = "TestFailedException";
+};
+
+/**
+ * @param  {string=} msg
+ */
+function testPassed(msg) {
+    msg = msg || 'Passed';
+    if (_currentTestName)
+      msg = _currentTestName + ': ' + msg;
+
+    reportTestResultsToHarness(true, msg);
+
+    if (!quietMode())
+      _addSpan('<span><span class="pass">PASS</span> ' + escapeHTML(msg) + '</span>');
+    if (_jsTestPreVerboseLogging) {
+        _bufferedLogToConsole('PASS ' + msg);
+    }
+}
+
+/**
+ * @param  {string=} msg
+ */
+function testFailed(msg) {
+    msg = msg || 'Failed';
+    if (_currentTestName)
+      msg = _currentTestName + ': ' + msg;
+
+    reportTestResultsToHarness(false, msg);
+    _addSpan('<span><span class="fail">FAIL</span> ' + escapeHTML(msg) + '</span>');
+    _bufferedLogToConsole('FAIL ' + msg);
+    _flushBufferedLogsToConsole();
+}
+
+var _currentTestName;
+
+/**
+ * Sets the current test name for usage within testPassedOptions/testFailedOptions.
+ * @param {string=} name The name to set as the current test name.
+ */
+function setCurrentTestName(name)
+{
+    _currentTestName = name;
+}
+
+/**
+ * Gets the current test name in use within testPassedOptions/testFailedOptions.
+ * @return {string} The name of the current test.
+ */
+function getCurrentTestName()
+{
+    return _currentTestName;
+}
+
+/**
+ * Variation of the testPassed function, with the option to not show (and thus not count) the test's pass result.
+ * @param {string} msg The message to be shown in the pass result.
+ * @param {boolean} addSpan Indicates whether the message will be visible (thus counted in the results) or not.
+ */
+function testPassedOptions(msg, addSpan)
+{
+    if (addSpan && !quietMode())
+    {
+        reportTestResultsToHarness(true, _currentTestName + ": " + msg);
+        _addSpan('<span><span class="pass">PASS</span> ' + escapeHTML(_currentTestName) + ": " + escapeHTML(msg) + '</span>');
+    }
+    if (_jsTestPreVerboseLogging) {
+        _bufferedLogToConsole('PASS ' + msg);
+    }
+}
+
+/**
+ * Report skipped tests.
+ * @param {string} msg The message to be shown in the skip result.
+ * @param {boolean} addSpan Indicates whether the message will be visible (thus counted in the results) or not.
+ */
+function testSkippedOptions(msg, addSpan)
+{
+    if (addSpan && !quietMode())
+    {
+        reportSkippedTestResultsToHarness(true, _currentTestName + ": " + msg);
+        _addSpan('<span><span class="warn">SKIP</span> ' + escapeHTML(_currentTestName) + ": " + escapeHTML(msg) + '</span>');
+    }
+    if (_jsTestPreVerboseLogging) {
+        _bufferedLogToConsole('SKIP' + msg);
+    }
+}
+
+/**
+ * Variation of the testFailed function, with the option to throw an exception or not.
+ * @param {string} msg The message to be shown in the fail result.
+ * @param {boolean} exthrow Indicates whether the function will throw a TestFailedException or not.
+ */
+function testFailedOptions(msg, exthrow)
+{
+    reportTestResultsToHarness(false, _currentTestName + ": " + msg);
+    _addSpan('<span><span class="fail">FAIL</span> ' + escapeHTML(_currentTestName) + ": " + escapeHTML(msg) + '</span>');
+    _bufferedLogToConsole('FAIL ' + msg);
+    _flushBufferedLogsToConsole();
+    if (exthrow) {
+        _currentTestName = ""; //Remembering to set the name of current testcase to empty string.
+        throw new TestFailedException(msg);
+    }
+}
+
+function areArraysEqual(_a, _b)
+{
+    try {
+        if (_a.length !== _b.length)
+            return false;
+        for (var i = 0; i < _a.length; i++)
+            if (_a[i] !== _b[i])
+                return false;
+    } catch (ex) {
+        return false;
+    }
+    return true;
+}
+
+function isMinusZero(n)
+{
+    // the only way to tell 0 from -0 in JS is the fact that 1/-0 is
+    // -Infinity instead of Infinity
+    return n === 0 && 1/n < 0;
+}
+
+function isResultCorrect(_actual, _expected)
+{
+    if (_expected === 0)
+        return _actual === _expected && (1/_actual) === (1/_expected);
+    if (_actual === _expected)
+        return true;
+    if (typeof(_expected) == "number" && isNaN(_expected))
+        return typeof(_actual) == "number" && isNaN(_actual);
+    if (Object.prototype.toString.call(_expected) == Object.prototype.toString.call([]))
+        return areArraysEqual(_actual, _expected);
+    return false;
+}
+
+function stringify(v)
+{
+    if (v === 0 && 1/v < 0)
+        return "-0";
+    else return "" + v;
+}
+
+function evalAndLog(_a)
+{
+  if (typeof _a != "string")
+    debug("WARN: tryAndLog() expects a string argument");
+
+  // Log first in case things go horribly wrong or this causes a sync event.
+  debug(_a);
+
+  var _av;
+  try {
+     _av = eval(_a);
+  } catch (e) {
+    testFailed(_a + " threw exception " + e);
+  }
+  return _av;
+}
+
+function shouldBeString(evalable, expected) {
+    const val = eval(evalable);
+    const text = evalable + " should be " + expected + ".";
+    if (val == expected) {
+        testPassed(text);
+    } else {
+        testFailed(text + " (was " + val + ")");
+    }
+}
+
+function shouldBe(_a, _b, quiet)
+{
+    if (typeof _a != "string" || typeof _b != "string")
+        debug("WARN: shouldBe() expects string arguments");
+    var exception;
+    var _av;
+    try {
+        _av = eval(_a);
+    } catch (e) {
+        exception = e;
+    }
+    var _bv = eval(_b);
+
+    if (exception)
+        testFailed(_a + " should be " + _bv + ". Threw exception " + exception);
+    else if (isResultCorrect(_av, _bv)) {
+        if (!quiet) {
+            testPassed(_a + " is " + _b);
+        }
+    } else if (typeof(_av) == typeof(_bv))
+        testFailed(_a + " should be " + _bv + ". Was " + stringify(_av) + ".");
+    else
+        testFailed(_a + " should be " + _bv + " (of type " + typeof _bv + "). Was " + _av + " (of type " + typeof _av + ").");
+}
+
+function shouldNotBe(_a, _b, quiet)
+{
+    if (typeof _a != "string" || typeof _b != "string")
+        debug("WARN: shouldNotBe() expects string arguments");
+    var exception;
+    var _av;
+    try {
+        _av = eval(_a);
+    } catch (e) {
+        exception = e;
+    }
+    var _bv = eval(_b);
+
+    if (exception)
+        testFailed(_a + " should not be " + _bv + ". Threw exception " + exception);
+    else if (!isResultCorrect(_av, _bv)) {
+        if (!quiet) {
+            testPassed(_a + " is not " + _b);
+        }
+    } else
+        testFailed(_a + " should not be " + _bv + ".");
+}
+
+function shouldBeTrue(_a) { shouldBe(_a, "true"); }
+function shouldBeFalse(_a) { shouldBe(_a, "false"); }
+function shouldBeNaN(_a) { shouldBe(_a, "NaN"); }
+function shouldBeNull(_a) { shouldBe(_a, "null"); }
+
+function shouldBeEqualToString(a, b)
+{
+  var unevaledString = '"' + b.replace(/"/g, "\"") + '"';
+  shouldBe(a, unevaledString);
+}
+
+function shouldEvaluateTo(actual, expected) {
+  // A general-purpose comparator.  'actual' should be a string to be
+  // evaluated, as for shouldBe(). 'expected' may be any type and will be
+  // used without being eval'ed.
+  if (expected == null) {
+    // Do this before the object test, since null is of type 'object'.
+    shouldBeNull(actual);
+  } else if (typeof expected == "undefined") {
+    shouldBeUndefined(actual);
+  } else if (typeof expected == "function") {
+    // All this fuss is to avoid the string-arg warning from shouldBe().
+    try {
+      var actualValue = eval(actual);
+    } catch (e) {
+      testFailed("Evaluating " + actual + ": Threw exception " + e);
+      return;
+    }
+    shouldBe("'" + actualValue.toString().replace(/\n/g, "") + "'",
+             "'" + expected.toString().replace(/\n/g, "") + "'");
+  } else if (typeof expected == "object") {
+    shouldBeTrue(actual + " == '" + expected + "'");
+  } else if (typeof expected == "string") {
+    shouldBe(actual, expected);
+  } else if (typeof expected == "boolean") {
+    shouldBe("typeof " + actual, "'boolean'");
+    if (expected)
+      shouldBeTrue(actual);
+    else
+      shouldBeFalse(actual);
+  } else if (typeof expected == "number") {
+    shouldBe(actual, stringify(expected));
+  } else {
+    debug(expected + " is unknown type " + typeof expected);
+    shouldBeTrue(actual, "'"  +expected.toString() + "'");
+  }
+}
+
+function shouldBeNonZero(_a)
+{
+  var exception;
+  var _av;
+  try {
+     _av = eval(_a);
+  } catch (e) {
+     exception = e;
+  }
+
+  if (exception)
+    testFailed(_a + " should be non-zero. Threw exception " + exception);
+  else if (_av != 0)
+    testPassed(_a + " is non-zero.");
+  else
+    testFailed(_a + " should be non-zero. Was " + _av);
+}
+
+function shouldBeNonNull(_a)
+{
+  var exception;
+  var _av;
+  try {
+     _av = eval(_a);
+  } catch (e) {
+     exception = e;
+  }
+
+  if (exception)
+    testFailed(_a + " should be non-null. Threw exception " + exception);
+  else if (_av != null)
+    testPassed(_a + " is non-null.");
+  else
+    testFailed(_a + " should be non-null. Was " + _av);
+}
+
+function shouldBeUndefined(_a)
+{
+  var exception;
+  var _av;
+  try {
+     _av = eval(_a);
+  } catch (e) {
+     exception = e;
+  }
+
+  if (exception)
+    testFailed(_a + " should be undefined. Threw exception " + exception);
+  else if (typeof _av == "undefined")
+    testPassed(_a + " is undefined.");
+  else
+    testFailed(_a + " should be undefined. Was " + _av);
+}
+
+function shouldBeDefined(_a)
+{
+  var exception;
+  var _av;
+  try {
+     _av = eval(_a);
+  } catch (e) {
+     exception = e;
+  }
+
+  if (exception)
+    testFailed(_a + " should be defined. Threw exception " + exception);
+  else if (_av !== undefined)
+    testPassed(_a + " is defined.");
+  else
+    testFailed(_a + " should be defined. Was " + _av);
+}
+
+function shouldBeLessThanOrEqual(_a, _b) {
+    if (typeof _a != "string" || typeof _b != "string")
+        debug("WARN: shouldBeLessThanOrEqual expects string arguments");
+
+    var exception;
+    var _av;
+    try {
+        _av = eval(_a);
+    } catch (e) {
+        exception = e;
+    }
+    var _bv = eval(_b);
+
+    if (exception)
+        testFailed(_a + " should be <= " + _b + ". Threw exception " + exception);
+    else if (typeof _av == "undefined" || _av > _bv)
+        testFailed(_a + " should be >= " + _b + ". Was " + _av + " (of type " + typeof _av + ").");
+    else
+        testPassed(_a + " is <= " + _b);
+}
+
+function shouldBeGreaterThanOrEqual(_a, _b) {
+    if (typeof _a != "string" || typeof _b != "string")
+        debug("WARN: shouldBeGreaterThanOrEqual expects string arguments");
+
+    var exception;
+    var _av;
+    try {
+        _av = eval(_a);
+    } catch (e) {
+        exception = e;
+    }
+    var _bv = eval(_b);
+
+    if (exception)
+        testFailed(_a + " should be >= " + _b + ". Threw exception " + exception);
+    else if (typeof _av == "undefined" || _av < _bv)
+        testFailed(_a + " should be >= " + _b + ". Was " + _av + " (of type " + typeof _av + ").");
+    else
+        testPassed(_a + " is >= " + _b);
+}
+
+function expectTrue(v, msg) {
+  if (v) {
+    testPassed(msg);
+  } else {
+    testFailed(msg);
+  }
+}
+
+function maxArrayDiff(a, b) {
+    if (a.length != b.length)
+        throw new Error(`a and b have different lengths: ${a.length} vs ${b.length}`);
+
+    let diff = 0;
+    for (const i in a) {
+        diff = Math.max(diff, Math.abs(a[i] - b[i]));
+    }
+    return diff;
+}
+
+function expectArray(was, expected, maxDiff=0) {
+    const diff = maxArrayDiff(expected, was);
+    let str = `Expected [${expected.toString()}]`;
+    let fn = testPassed;
+    if (maxDiff) {
+        str += ' +/- ' + maxDiff;
+    }
+    if (diff > maxDiff) {
+        fn = testFailed;
+        str += `, was [${was.toString()}]`;
+    }
+    fn(str);
+}
+
+function shouldThrow(_a, _e)
+{
+  var exception;
+  var _av;
+  try {
+     _av = eval(_a);
+  } catch (e) {
+     exception = e;
+  }
+
+  var _ev;
+  if (_e)
+      _ev =  eval(_e);
+
+  if (exception) {
+    if (typeof _e == "undefined" || exception == _ev)
+      testPassed(_a + " threw exception " + exception + ".");
+    else
+      testFailed(_a + " should throw " + (typeof _e == "undefined" ? "an exception" : _ev) + ". Threw exception " + exception + ".");
+  } else if (typeof _av == "undefined")
+    testFailed(_a + " should throw " + (typeof _e == "undefined" ? "an exception" : _ev) + ". Was undefined.");
+  else
+    testFailed(_a + " should throw " + (typeof _e == "undefined" ? "an exception" : _ev) + ". Was " + _av + ".");
+}
+
+function shouldNotThrow(evalStr, desc) {
+  desc = desc || `\`${evalStr}\``;
+  try {
+    eval(evalStr);
+    testPassed(`${desc} should not throw.`);
+  } catch (e) {
+    testFailed(`${desc} should not throw, but threw exception ${e}.`);
+  }
+}
+
+
+function shouldBeType(_a, _type) {
+    var exception;
+    var _av;
+    try {
+        _av = eval(_a);
+    } catch (e) {
+        exception = e;
+    }
+
+    var _typev = eval(_type);
+
+    if(_typev === Number){
+        if(_av instanceof Number){
+            testPassed(_a + " is an instance of Number");
+        }
+        else if(typeof(_av) === 'number'){
+            testPassed(_a + " is an instance of Number");
+        }
+        else{
+            testFailed(_a + " is not an instance of Number");
+        }
+    }
+    else if (_av instanceof _typev) {
+        testPassed(_a + " is an instance of " + _type);
+    } else {
+        testFailed(_a + " is not an instance of " + _type);
+    }
+}
+
+/**
+ * Shows a message in case expression test fails.
+ * @param {boolean} exp
+ * @param {straing} message
+ */
+function checkMessage(exp, message) {
+    if ( !exp )
+        _addSpan('<span><span class="warn">WARNING</span> ' + escapeHTML(_currentTestName) + ": " + escapeHTML(message) + '</span>');
+}
+
+function assertMsg(assertion, msg) {
+    if (assertion) {
+        testPassed(msg);
+    } else {
+        testFailed(msg);
+    }
+}
+
+/**
+ * Variation of the assertMsg function, with the option to not show (and thus not count) the test's pass result,
+ * and throw or not a TestFailedException in case of failure.
+ * @param {boolean} assertion If this is true, means success, else failure.
+ * @param {?string} msg The message to be shown in the result.
+ * @param {boolean} verbose In case of success, determines if the test will show it's result and count in the results.
+ * @param {boolean} exthrow In case of failure, determines if the function will throw a TestFailedException.
+ */
+function assertMsgOptions(assertion, msg, verbose, exthrow) {
+    if (assertion) {
+        testPassedOptions(msg, verbose);
+    } else {
+        testFailedOptions(msg, exthrow);
+    }
+}
+
+
+function webglHarnessCollectGarbage() {
+    if (window.GCController) {
+        window.GCController.collect();
+        return;
+    }
+
+    if (window.opera && window.opera.collect) {
+        window.opera.collect();
+        return;
+    }
+
+    try {
+        window.QueryInterface(Components.interfaces.nsIInterfaceRequestor)
+              .getInterface(Components.interfaces.nsIDOMWindowUtils)
+              .garbageCollect();
+        return;
+    } catch(e) {}
+
+    if (window.gc) {
+        window.gc();
+        return;
+    }
+
+    if (window.CollectGarbage) {
+        CollectGarbage();
+        return;
+    }
+
+    // WebKit's MiniBrowser.
+    if (window.$vm) {
+        window.$vm.gc();
+        return;
+    }
+
+    function gcRec(n) {
+        if (n < 1)
+            return {};
+        var temp = {i: "ab" + i + (i / 100000)};
+        temp += "foo";
+        gcRec(n-1);
+    }
+    for (var i = 0; i < 1000; i++)
+        gcRec(10);
+}
+
+function finishTest() {
+  successfullyParsed = true;
+  var epilogue = document.createElement("script");
+  var basePath = "";
+  var expectedBase = "js-test-pre.js";
+  var scripts = document.getElementsByTagName('script');
+  for (var script, i = 0; script = scripts[i]; i++) {
+    var src = script.src;
+    var l = src.length;
+    if (src.substr(l - expectedBase.length) == expectedBase) {
+      basePath = src.substr(0, l - expectedBase.length);
+      break;
+    }
+  }
+  epilogue.src = basePath + "js-test-post.js";
+  document.body.appendChild(epilogue);
+}
+
+/// Prefer `call(() => { ... })` to `(() => { ... })()`\
+/// This way, it's clear up-front that we're calling not just defining.
+function call(fn) {
+    return fn();
+}
+
+/// `for (const i of range(3))` => 0, 1, 2
+/// Don't use `for...in range(n)`, it will not work.
+function* range(n) {
+  for (let i = 0; i < n; i++) {
+    yield i;
+  }
+}
diff --git a/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/webgl-test-utils.js b/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/webgl-test-utils.js
new file mode 100644
index 0000000..9affa10
--- /dev/null
+++ b/LayoutTests/http/tests/webgl/resources/webgl_test_files/js/webgl-test-utils.js
@@ -0,0 +1,3552 @@
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+var WebGLTestUtils = (function() {
+"use strict";
+
+/**
+ * Wrapped logging function.
+ * @param {string} msg The message to log.
+ */
+var log = function(msg) {
+  bufferedLogToConsole(msg);
+};
+
+/**
+ * Wrapped logging function.
+ * @param {string} msg The message to log.
+ */
+var error = function(msg) {
+  // For the time being, diverting this to window.console.log rather
+  // than window.console.error. If anyone cares enough they can
+  // generalize the mechanism in js-test-pre.js.
+  log(msg);
+};
+
+/**
+ * Turn off all logging.
+ */
+var loggingOff = function() {
+  log = function() {};
+  error = function() {};
+};
+
+const ENUM_NAME_REGEX = RegExp('[A-Z][A-Z0-9_]*');
+const ENUM_NAME_BY_VALUE = {};
+const ENUM_NAME_PROTOTYPES = new Map();
+
+/**
+ * Converts a WebGL enum to a string.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} value The enum value.
+ * @return {string} The enum as a string.
+ */
+var glEnumToString = function(glOrExt, value) {
+  if (value === undefined)
+    throw new Error('glEnumToString: `value` must not be undefined');
+
+  const proto = glOrExt.__proto__;
+  if (!ENUM_NAME_PROTOTYPES.has(proto)) {
+    ENUM_NAME_PROTOTYPES.set(proto, true);
+
+    for (const k in proto) {
+      if (!ENUM_NAME_REGEX.test(k)) continue;
+
+      const v = glOrExt[k];
+      if (ENUM_NAME_BY_VALUE[v] === undefined) {
+        ENUM_NAME_BY_VALUE[v] = k;
+      } else {
+        ENUM_NAME_BY_VALUE[v] += '/' + k;
+      }
+    }
+  }
+
+  const key = ENUM_NAME_BY_VALUE[value];
+  if (key !== undefined) return key;
+
+  return "0x" + Number(value).toString(16);
+};
+
+var lastError = "";
+
+/**
+ * Returns the last compiler/linker error.
+ * @return {string} The last compiler/linker error.
+ */
+var getLastError = function() {
+  return lastError;
+};
+
+/**
+ * Whether a haystack ends with a needle.
+ * @param {string} haystack String to search
+ * @param {string} needle String to search for.
+ * @param {boolean} True if haystack ends with needle.
+ */
+var endsWith = function(haystack, needle) {
+  return haystack.substr(haystack.length - needle.length) === needle;
+};
+
+/**
+ * Whether a haystack starts with a needle.
+ * @param {string} haystack String to search
+ * @param {string} needle String to search for.
+ * @param {boolean} True if haystack starts with needle.
+ */
+var startsWith = function(haystack, needle) {
+  return haystack.substr(0, needle.length) === needle;
+};
+
+/**
+ * A vertex shader for a single texture.
+ * @type {string}
+ */
+var simpleTextureVertexShader = [
+  'attribute vec4 vPosition;',
+  'attribute vec2 texCoord0;',
+  'varying vec2 texCoord;',
+  'void main() {',
+  '    gl_Position = vPosition;',
+  '    texCoord = texCoord0;',
+  '}'].join('\n');
+
+/**
+ * A vertex shader for a single texture.
+ * @type {string}
+ */
+var simpleTextureVertexShaderESSL300 = [
+  '#version 300 es',
+  'layout(location=0) in vec4 vPosition;',
+  'layout(location=1) in vec2 texCoord0;',
+  'out vec2 texCoord;',
+  'void main() {',
+  '    gl_Position = vPosition;',
+  '    texCoord = texCoord0;',
+  '}'].join('\n');
+
+/**
+ * A fragment shader for a single texture.
+ * @type {string}
+ */
+var simpleTextureFragmentShader = [
+  'precision mediump float;',
+  'uniform sampler2D tex;',
+  'varying vec2 texCoord;',
+  'void main() {',
+  '    gl_FragData[0] = texture2D(tex, texCoord);',
+  '}'].join('\n');
+
+/**
+ * A fragment shader for a single texture.
+ * @type {string}
+ */
+var simpleTextureFragmentShaderESSL300 = [
+  '#version 300 es',
+  'precision highp float;',
+  'uniform highp sampler2D tex;',
+  'in vec2 texCoord;',
+  'out vec4 out_color;',
+  'void main() {',
+  '    out_color = texture(tex, texCoord);',
+  '}'].join('\n');
+
+/**
+ * A fragment shader for a single texture with high precision.
+ * @type {string}
+ */
+var simpleHighPrecisionTextureFragmentShader = [
+  'precision highp float;',
+  'uniform highp sampler2D tex;',
+  'varying vec2 texCoord;',
+  'void main() {',
+  '    gl_FragData[0] = texture2D(tex, texCoord);',
+  '}'].join('\n');
+
+/**
+ * A fragment shader for a single cube map texture.
+ * @type {string}
+ */
+var simpleCubeMapTextureFragmentShader = [
+  'precision mediump float;',
+  'uniform samplerCube tex;',
+  'uniform highp int face;',
+  'varying vec2 texCoord;',
+  'void main() {',
+  // Transform [0, 1] -> [-1, 1]
+  '    vec2 texC2 = (texCoord * 2.) - 1.;',
+  // Transform 2d tex coord. to each face of TEXTURE_CUBE_MAP coord.
+  '    vec3 texCube = vec3(0., 0., 0.);',
+  '    if (face == 34069) {',         // TEXTURE_CUBE_MAP_POSITIVE_X
+  '        texCube = vec3(1., -texC2.y, -texC2.x);',
+  '    } else if (face == 34070) {',  // TEXTURE_CUBE_MAP_NEGATIVE_X
+  '        texCube = vec3(-1., -texC2.y, texC2.x);',
+  '    } else if (face == 34071) {',  // TEXTURE_CUBE_MAP_POSITIVE_Y
+  '        texCube = vec3(texC2.x, 1., texC2.y);',
+  '    } else if (face == 34072) {',  // TEXTURE_CUBE_MAP_NEGATIVE_Y
+  '        texCube = vec3(texC2.x, -1., -texC2.y);',
+  '    } else if (face == 34073) {',  // TEXTURE_CUBE_MAP_POSITIVE_Z
+  '        texCube = vec3(texC2.x, -texC2.y, 1.);',
+  '    } else if (face == 34074) {',  // TEXTURE_CUBE_MAP_NEGATIVE_Z
+  '        texCube = vec3(-texC2.x, -texC2.y, -1.);',
+  '    }',
+  '    gl_FragData[0] = textureCube(tex, texCube);',
+  '}'].join('\n');
+
+/**
+ * A vertex shader for a single texture.
+ * @type {string}
+ */
+var noTexCoordTextureVertexShader = [
+  'attribute vec4 vPosition;',
+  'varying vec2 texCoord;',
+  'void main() {',
+  '    gl_Position = vPosition;',
+  '    texCoord = vPosition.xy * 0.5 + 0.5;',
+  '}'].join('\n');
+
+/**
+ * A vertex shader for a uniform color.
+ * @type {string}
+ */
+var simpleVertexShader = [
+  'attribute vec4 vPosition;',
+  'void main() {',
+  '    gl_Position = vPosition;',
+  '}'].join('\n');
+
+/**
+ * A vertex shader for a uniform color.
+ * @type {string}
+ */
+var simpleVertexShaderESSL300 = [
+  '#version 300 es',
+  'in vec4 vPosition;',
+  'void main() {',
+  '    gl_Position = vPosition;',
+  '}'].join('\n');
+
+/**
+ * A fragment shader for a uniform color.
+ * @type {string}
+ */
+var simpleColorFragmentShader = [
+  'precision mediump float;',
+  'uniform vec4 u_color;',
+  'void main() {',
+  '    gl_FragData[0] = u_color;',
+  '}'].join('\n');
+
+/**
+ * A fragment shader for a uniform color.
+ * @type {string}
+ */
+var simpleColorFragmentShaderESSL300 = [
+  '#version 300 es',
+  'precision mediump float;',
+  'out vec4 out_color;',
+  'uniform vec4 u_color;',
+  'void main() {',
+  '    out_color = u_color;',
+  '}'].join('\n');
+
+/**
+ * A vertex shader for vertex colors.
+ * @type {string}
+ */
+var simpleVertexColorVertexShader = [
+  'attribute vec4 vPosition;',
+  'attribute vec4 a_color;',
+  'varying vec4 v_color;',
+  'void main() {',
+  '    gl_Position = vPosition;',
+  '    v_color = a_color;',
+  '}'].join('\n');
+
+/**
+ * A fragment shader for vertex colors.
+ * @type {string}
+ */
+var simpleVertexColorFragmentShader = [
+  'precision mediump float;',
+  'varying vec4 v_color;',
+  'void main() {',
+  '    gl_FragData[0] = v_color;',
+  '}'].join('\n');
+
+/**
+ * Creates a program, attaches shaders, binds attrib locations, links the
+ * program and calls useProgram.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<!WebGLShader|string>} shaders The shaders to
+ *        attach, or the source, or the id of a script to get
+ *        the source from.
+ * @param {!Array.<string>} opt_attribs The attribs names.
+ * @param {!Array.<number>} opt_locations The locations for the attribs.
+ * @param {boolean} opt_logShaders Whether to log shader source.
+ */
+var setupProgram = function(
+    gl, shaders, opt_attribs, opt_locations, opt_logShaders) {
+  var realShaders = [];
+  var program = gl.createProgram();
+  var shaderCount = 0;
+  for (var ii = 0; ii < shaders.length; ++ii) {
+    var shader = shaders[ii];
+    var shaderType = undefined;
+    if (typeof shader == 'string') {
+      var element = document.getElementById(shader);
+      if (element) {
+        if (element.type != "x-shader/x-vertex" && element.type != "x-shader/x-fragment")
+          shaderType = ii ? gl.FRAGMENT_SHADER : gl.VERTEX_SHADER;
+        shader = loadShaderFromScript(gl, shader, shaderType, undefined, opt_logShaders);
+      } else if (endsWith(shader, ".vert")) {
+        shader = loadShaderFromFile(gl, shader, gl.VERTEX_SHADER, undefined, opt_logShaders);
+      } else if (endsWith(shader, ".frag")) {
+        shader = loadShaderFromFile(gl, shader, gl.FRAGMENT_SHADER, undefined, opt_logShaders);
+      } else {
+        shader = loadShader(gl, shader, ii ? gl.FRAGMENT_SHADER : gl.VERTEX_SHADER, undefined, opt_logShaders);
+      }
+    } else if (opt_logShaders) {
+      throw 'Shader source logging requested but no shader source provided';
+    }
+    if (shader) {
+      ++shaderCount;
+      gl.attachShader(program, shader);
+    }
+  }
+  if (shaderCount != 2) {
+    error("Error in compiling shader");
+    return null;
+  }
+  if (opt_attribs) {
+    for (var ii = 0; ii < opt_attribs.length; ++ii) {
+      gl.bindAttribLocation(
+          program,
+          opt_locations ? opt_locations[ii] : ii,
+          opt_attribs[ii]);
+    }
+  }
+  gl.linkProgram(program);
+
+  // Check the link status
+  var linked = gl.getProgramParameter(program, gl.LINK_STATUS);
+  if (!linked) {
+      // something went wrong with the link
+      lastError = gl.getProgramInfoLog (program);
+      error("Error in program linking:" + lastError);
+
+      gl.deleteProgram(program);
+      return null;
+  }
+
+  gl.useProgram(program);
+  return program;
+};
+
+/**
+ * Creates a program, attaches shader, sets up trasnform feedback varyings,
+ * binds attrib locations, links the program and calls useProgram.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<!WebGLShader|string>} shaders The shaders to
+ *        attach, or the source, or the id of a script to get
+ *        the source from.
+ * @param {!Array.<string>} varyings The transform feedback varying names.
+ * @param {number} bufferMode The mode used to capture the varying variables.
+ * @param {!Array.<string>} opt_attribs The attribs names.
+ * @param {!Array.<number>} opt_locations The locations for the attribs.
+ * @param {boolean} opt_logShaders Whether to log shader source.
+ */
+var setupTransformFeedbackProgram = function(
+    gl, shaders, varyings, bufferMode, opt_attribs, opt_locations, opt_logShaders, opt_skipCompileStatus) {
+  var realShaders = [];
+  var program = gl.createProgram();
+  var shaderCount = 0;
+  for (var ii = 0; ii < shaders.length; ++ii) {
+    var shader = shaders[ii];
+    var shaderType = undefined;
+    if (typeof shader == 'string') {
+      var element = document.getElementById(shader);
+      if (element) {
+        if (element.type != "x-shader/x-vertex" && element.type != "x-shader/x-fragment")
+          shaderType = ii ? gl.FRAGMENT_SHADER : gl.VERTEX_SHADER;
+        shader = loadShaderFromScript(gl, shader, shaderType, undefined, opt_logShaders, opt_skipCompileStatus);
+      } else if (endsWith(shader, ".vert")) {
+        shader = loadShaderFromFile(gl, shader, gl.VERTEX_SHADER, undefined, opt_logShaders, opt_skipCompileStatus);
+      } else if (endsWith(shader, ".frag")) {
+        shader = loadShaderFromFile(gl, shader, gl.FRAGMENT_SHADER, undefined, opt_logShaders, opt_skipCompileStatus);
+      } else {
+        shader = loadShader(gl, shader, ii ? gl.FRAGMENT_SHADER : gl.VERTEX_SHADER, undefined, opt_logShaders, undefined, undefined, opt_skipCompileStatus);
+      }
+    } else if (opt_logShaders) {
+      throw 'Shader source logging requested but no shader source provided';
+    }
+    if (shader) {
+      ++shaderCount;
+      gl.attachShader(program, shader);
+    }
+  }
+  if (shaderCount != 2) {
+    error("Error in compiling shader");
+    return null;
+  }
+
+  if (opt_attribs) {
+    for (var ii = 0; ii < opt_attribs.length; ++ii) {
+      gl.bindAttribLocation(
+          program,
+          opt_locations ? opt_locations[ii] : ii,
+          opt_attribs[ii]);
+    }
+  }
+
+  gl.transformFeedbackVaryings(program, varyings, bufferMode);
+
+  gl.linkProgram(program);
+
+  // Check the link status
+  var linked = gl.getProgramParameter(program, gl.LINK_STATUS);
+  if (!linked) {
+      // something went wrong with the link
+      lastError = gl.getProgramInfoLog (program);
+      error("Error in program linking:" + lastError);
+
+      gl.deleteProgram(program);
+      return null;
+  }
+
+  gl.useProgram(program);
+  return program;
+};
+
+/**
+ * Creates a simple texture program.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @return {WebGLProgram}
+ */
+var setupNoTexCoordTextureProgram = function(gl) {
+  return setupProgram(gl,
+                      [noTexCoordTextureVertexShader, simpleTextureFragmentShader],
+                      ['vPosition'],
+                      [0]);
+};
+
+/**
+ * Creates a simple texture program.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @param {number} opt_texcoordLocation The attrib location for texture coords.
+ * @param {string} opt_fragmentShaderOverride The alternative fragment shader to use.
+ * @return {WebGLProgram}
+ */
+var setupSimpleTextureProgram = function(
+    gl, opt_positionLocation, opt_texcoordLocation, opt_fragmentShaderOverride) {
+  opt_positionLocation = opt_positionLocation || 0;
+  opt_texcoordLocation = opt_texcoordLocation || 1;
+  opt_fragmentShaderOverride = opt_fragmentShaderOverride || simpleTextureFragmentShader;
+  return setupProgram(gl,
+                      [simpleTextureVertexShader, opt_fragmentShaderOverride],
+                      ['vPosition', 'texCoord0'],
+                      [opt_positionLocation, opt_texcoordLocation]);
+};
+
+/**
+ * Creates a simple texture program using glsl version 300.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @param {number} opt_texcoordLocation The attrib location for texture coords.
+ * @param {string} opt_fragmentShaderOverride The alternative fragment shader to use.
+ * @return {WebGLProgram}
+ */
+var setupSimpleTextureProgramESSL300 = function(
+    gl, opt_positionLocation, opt_texcoordLocation, opt_fragmentShaderOverride) {
+  opt_positionLocation = opt_positionLocation || 0;
+  opt_texcoordLocation = opt_texcoordLocation || 1;
+  opt_fragmentShaderOverride = opt_fragmentShaderOverride || simpleTextureFragmentShaderESSL300;
+  return setupProgram(gl,
+                      [simpleTextureVertexShaderESSL300, opt_fragmentShaderOverride],
+                      ['vPosition', 'texCoord0'],
+                      [opt_positionLocation, opt_texcoordLocation]);
+};
+
+/**
+ * Creates a simple cube map texture program.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @param {number} opt_texcoordLocation The attrib location for texture coords.
+ * @return {WebGLProgram}
+ */
+var setupSimpleCubeMapTextureProgram = function(
+    gl, opt_positionLocation, opt_texcoordLocation) {
+  opt_positionLocation = opt_positionLocation || 0;
+  opt_texcoordLocation = opt_texcoordLocation || 1;
+  return setupProgram(gl,
+                      [simpleTextureVertexShader, simpleCubeMapTextureFragmentShader],
+                      ['vPosition', 'texCoord0'],
+                      [opt_positionLocation, opt_texcoordLocation]);
+};
+
+/**
+ * Creates a simple vertex color program.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @param {number} opt_vertexColorLocation The attrib location
+ *        for vertex colors.
+ * @return {WebGLProgram}
+ */
+var setupSimpleVertexColorProgram = function(
+    gl, opt_positionLocation, opt_vertexColorLocation) {
+  opt_positionLocation = opt_positionLocation || 0;
+  opt_vertexColorLocation = opt_vertexColorLocation || 1;
+  return setupProgram(gl,
+                      [simpleVertexColorVertexShader, simpleVertexColorFragmentShader],
+                      ['vPosition', 'a_color'],
+                      [opt_positionLocation, opt_vertexColorLocation]);
+};
+
+/**
+ * Creates a simple color program.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @return {WebGLProgram}
+ */
+var setupSimpleColorProgram = function(gl, opt_positionLocation) {
+  opt_positionLocation = opt_positionLocation || 0;
+  return setupProgram(gl,
+                      [simpleVertexShader, simpleColorFragmentShader],
+                      ['vPosition'],
+                      [opt_positionLocation]);
+};
+
+/**
+ * Creates buffers for a textured unit quad and attaches them to vertex attribs.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @param {number} opt_texcoordLocation The attrib location for texture coords.
+ * @param {!Object} various options. See setupQuad for details.
+ * @return {!Array.<WebGLBuffer>} The buffer objects that were
+ *      created.
+ */
+var setupUnitQuad = function(gl, opt_positionLocation, opt_texcoordLocation, options) {
+  return setupQuadWithTexCoords(gl, [ 0.0, 0.0 ], [ 1.0, 1.0 ],
+                                opt_positionLocation, opt_texcoordLocation,
+                                options);
+};
+
+/**
+ * Creates buffers for a textured quad with specified lower left
+ * and upper right texture coordinates, and attaches them to vertex
+ * attribs.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<number>} lowerLeftTexCoords The texture coordinates for the lower left corner.
+ * @param {!Array.<number>} upperRightTexCoords The texture coordinates for the upper right corner.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @param {number} opt_texcoordLocation The attrib location for texture coords.
+ * @param {!Object} various options. See setupQuad for details.
+ * @return {!Array.<WebGLBuffer>} The buffer objects that were
+ *      created.
+ */
+var setupQuadWithTexCoords = function(
+    gl, lowerLeftTexCoords, upperRightTexCoords,
+    opt_positionLocation, opt_texcoordLocation, options) {
+  var defaultOptions = {
+    positionLocation: opt_positionLocation || 0,
+    texcoordLocation: opt_texcoordLocation || 1,
+    lowerLeftTexCoords: lowerLeftTexCoords,
+    upperRightTexCoords: upperRightTexCoords
+  };
+  if (options) {
+    for (var prop in options) {
+      defaultOptions[prop] = options[prop]
+    }
+  }
+  return setupQuad(gl, defaultOptions);
+};
+
+/**
+ * Makes a quad with various options.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Object} options
+ *
+ * scale: scale to multiply unit quad values by. default 1.0.
+ * positionLocation: attribute location for position.
+ * texcoordLocation: attribute location for texcoords.
+ *     If this does not exist no texture coords are created.
+ * lowerLeftTexCoords: an array of 2 values for the
+ *     lowerLeftTexCoords.
+ * upperRightTexCoords: an array of 2 values for the
+ *     upperRightTexCoords.
+ */
+var setupQuad = function(gl, options) {
+  var positionLocation = options.positionLocation || 0;
+  var scale = options.scale || 1;
+
+  var objects = [];
+
+  var vertexObject = gl.createBuffer();
+  gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
+  gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([
+       1.0 * scale ,  1.0 * scale,
+      -1.0 * scale ,  1.0 * scale,
+      -1.0 * scale , -1.0 * scale,
+       1.0 * scale ,  1.0 * scale,
+      -1.0 * scale , -1.0 * scale,
+       1.0 * scale , -1.0 * scale]), gl.STATIC_DRAW);
+  gl.enableVertexAttribArray(positionLocation);
+  gl.vertexAttribPointer(positionLocation, 2, gl.FLOAT, false, 0, 0);
+  objects.push(vertexObject);
+
+  if (options.texcoordLocation !== undefined) {
+    var llx = options.lowerLeftTexCoords[0];
+    var lly = options.lowerLeftTexCoords[1];
+    var urx = options.upperRightTexCoords[0];
+    var ury = options.upperRightTexCoords[1];
+
+    vertexObject = gl.createBuffer();
+    gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
+    gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([
+        urx, ury,
+        llx, ury,
+        llx, lly,
+        urx, ury,
+        llx, lly,
+        urx, lly]), gl.STATIC_DRAW);
+    gl.enableVertexAttribArray(options.texcoordLocation);
+    gl.vertexAttribPointer(options.texcoordLocation, 2, gl.FLOAT, false, 0, 0);
+    objects.push(vertexObject);
+  }
+
+  return objects;
+};
+
+/**
+ * Creates a program and buffers for rendering a textured quad.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for
+ *        position. Default = 0.
+ * @param {number} opt_texcoordLocation The attrib location for
+ *        texture coords. Default = 1.
+ * @param {!Object} various options defined by setupQuad, plus an option
+          fragmentShaderOverride to specify a custom fragment shader.
+ * @return {!WebGLProgram}
+ */
+var setupTexturedQuad = function(
+    gl, opt_positionLocation, opt_texcoordLocation, options) {
+  var program = setupSimpleTextureProgram(
+      gl, opt_positionLocation, opt_texcoordLocation, options && options.fragmentShaderOverride);
+  setupUnitQuad(gl, opt_positionLocation, opt_texcoordLocation, options);
+  return program;
+};
+
+/**
+ * Creates a program and buffers for rendering a color quad.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @param {!Object} various options. See setupQuad for details.
+ * @return {!WebGLProgram}
+ */
+var setupColorQuad = function(gl, opt_positionLocation, options) {
+  opt_positionLocation = opt_positionLocation || 0;
+  var program = setupSimpleColorProgram(gl, opt_positionLocation);
+  setupUnitQuad(gl, opt_positionLocation, 0, options);
+  return program;
+};
+
+/**
+ * Creates a program and buffers for rendering a textured quad with
+ * specified lower left and upper right texture coordinates.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<number>} lowerLeftTexCoords The texture coordinates for the lower left corner.
+ * @param {!Array.<number>} upperRightTexCoords The texture coordinates for the upper right corner.
+ * @param {number} opt_positionLocation The attrib location for position.
+ * @param {number} opt_texcoordLocation The attrib location for texture coords.
+ * @return {!WebGLProgram}
+ */
+var setupTexturedQuadWithTexCoords = function(
+    gl, lowerLeftTexCoords, upperRightTexCoords,
+    opt_positionLocation, opt_texcoordLocation) {
+  var program = setupSimpleTextureProgram(
+      gl, opt_positionLocation, opt_texcoordLocation);
+  setupQuadWithTexCoords(gl, lowerLeftTexCoords, upperRightTexCoords,
+                         opt_positionLocation, opt_texcoordLocation);
+  return program;
+};
+
+/**
+ * Creates a program and buffers for rendering a textured quad with
+ * a cube map texture.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} opt_positionLocation The attrib location for
+ *        position. Default = 0.
+ * @param {number} opt_texcoordLocation The attrib location for
+ *        texture coords. Default = 1.
+ * @return {!WebGLProgram}
+ */
+var setupTexturedQuadWithCubeMap = function(
+    gl, opt_positionLocation, opt_texcoordLocation) {
+  var program = setupSimpleCubeMapTextureProgram(
+      gl, opt_positionLocation, opt_texcoordLocation);
+  setupUnitQuad(gl, opt_positionLocation, opt_texcoordLocation, undefined);
+  return program;
+};
+
+/**
+ * Creates a unit quad with only positions of a given resolution.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} gridRes The resolution of the mesh grid,
+ *     expressed in the number of quads across and down.
+ * @param {number} opt_positionLocation The attrib location for position.
+ */
+var setupIndexedQuad = function (
+    gl, gridRes, opt_positionLocation, opt_flipOddTriangles) {
+  return setupIndexedQuadWithOptions(gl,
+    { gridRes: gridRes,
+      positionLocation: opt_positionLocation,
+      flipOddTriangles: opt_flipOddTriangles
+    });
+};
+
+/**
+ * Creates a quad with various options.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Object} options The options. See below.
+ * @return {!Array.<WebGLBuffer>} The created buffers.
+ *     [positions, <colors>, indices]
+ *
+ * Options:
+ *   gridRes: number of quads across and down grid.
+ *   positionLocation: attrib location for position
+ *   flipOddTriangles: reverse order of vertices of every other
+ *       triangle
+ *   positionOffset: offset added to each vertex
+ *   positionMult: multipier for each vertex
+ *   colorLocation: attrib location for vertex colors. If
+ *      undefined no vertex colors will be created.
+ */
+var setupIndexedQuadWithOptions = function (gl, options) {
+  var positionLocation = options.positionLocation || 0;
+  var objects = [];
+
+  var gridRes = options.gridRes || 1;
+  var positionOffset = options.positionOffset || 0;
+  var positionMult = options.positionMult || 1;
+  var vertsAcross = gridRes + 1;
+  var numVerts = vertsAcross * vertsAcross;
+  var positions = new Float32Array(numVerts * 3);
+  var indices = new Uint16Array(6 * gridRes * gridRes);
+  var poffset = 0;
+
+  for (var yy = 0; yy <= gridRes; ++yy) {
+    for (var xx = 0; xx <= gridRes; ++xx) {
+      positions[poffset + 0] = (-1 + 2 * xx / gridRes) * positionMult + positionOffset;
+      positions[poffset + 1] = (-1 + 2 * yy / gridRes) * positionMult + positionOffset;
+      positions[poffset + 2] = 0;
+
+      poffset += 3;
+    }
+  }
+
+  var buf = gl.createBuffer();
+  gl.bindBuffer(gl.ARRAY_BUFFER, buf);
+  gl.bufferData(gl.ARRAY_BUFFER, positions, gl.STATIC_DRAW);
+  gl.enableVertexAttribArray(positionLocation);
+  gl.vertexAttribPointer(positionLocation, 3, gl.FLOAT, false, 0, 0);
+  objects.push(buf);
+
+  if (options.colorLocation !== undefined) {
+    var colors = new Float32Array(numVerts * 4);
+    poffset = 0;
+    for (var yy = 0; yy <= gridRes; ++yy) {
+      for (var xx = 0; xx <= gridRes; ++xx) {
+        if (options.color !== undefined) {
+          colors[poffset + 0] = options.color[0];
+          colors[poffset + 1] = options.color[1];
+          colors[poffset + 2] = options.color[2];
+          colors[poffset + 3] = options.color[3];
+        } else {
+          colors[poffset + 0] = xx / gridRes;
+          colors[poffset + 1] = yy / gridRes;
+          colors[poffset + 2] = (xx / gridRes) * (yy / gridRes);
+          colors[poffset + 3] = (yy % 2) * 0.5 + 0.5;
+        }
+        poffset += 4;
+      }
+    }
+
+    buf = gl.createBuffer();
+    gl.bindBuffer(gl.ARRAY_BUFFER, buf);
+    gl.bufferData(gl.ARRAY_BUFFER, colors, gl.STATIC_DRAW);
+    gl.enableVertexAttribArray(options.colorLocation);
+    gl.vertexAttribPointer(options.colorLocation, 4, gl.FLOAT, false, 0, 0);
+    objects.push(buf);
+  }
+
+  var tbase = 0;
+  for (var yy = 0; yy < gridRes; ++yy) {
+    var index = yy * vertsAcross;
+    for (var xx = 0; xx < gridRes; ++xx) {
+      indices[tbase + 0] = index + 0;
+      indices[tbase + 1] = index + 1;
+      indices[tbase + 2] = index + vertsAcross;
+      indices[tbase + 3] = index + vertsAcross;
+      indices[tbase + 4] = index + 1;
+      indices[tbase + 5] = index + vertsAcross + 1;
+
+      if (options.flipOddTriangles) {
+        indices[tbase + 4] = index + vertsAcross + 1;
+        indices[tbase + 5] = index + 1;
+      }
+
+      index += 1;
+      tbase += 6;
+    }
+  }
+
+  buf = gl.createBuffer();
+  gl.bindBuffer(gl.ELEMENT_ARRAY_BUFFER, buf);
+  gl.bufferData(gl.ELEMENT_ARRAY_BUFFER, indices, gl.STATIC_DRAW);
+  objects.push(buf);
+
+  return objects;
+};
+
+/**
+ * Returns the constructor for a typed array that corresponds to the given
+ * WebGL type.
+ * @param {!WebGLRenderingContext} gl A WebGLRenderingContext.
+ * @param {number} type The WebGL type (eg, gl.UNSIGNED_BYTE)
+ * @return {!Constructor} The typed array constructor that
+ *      corresponds to the given type.
+ */
+var glTypeToTypedArrayType = function(gl, type) {
+  switch (type) {
+    case gl.BYTE:
+      return window.Int8Array;
+    case gl.UNSIGNED_BYTE:
+      return window.Uint8Array;
+    case gl.SHORT:
+      return window.Int16Array;
+    case gl.UNSIGNED_SHORT:
+    case gl.UNSIGNED_SHORT_5_6_5:
+    case gl.UNSIGNED_SHORT_4_4_4_4:
+    case gl.UNSIGNED_SHORT_5_5_5_1:
+      return window.Uint16Array;
+    case gl.INT:
+      return window.Int32Array;
+    case gl.UNSIGNED_INT:
+    case gl.UNSIGNED_INT_5_9_9_9_REV:
+    case gl.UNSIGNED_INT_10F_11F_11F_REV:
+    case gl.UNSIGNED_INT_2_10_10_10_REV:
+    case gl.UNSIGNED_INT_24_8:
+      return window.Uint32Array;
+    case gl.HALF_FLOAT:
+    case 0x8D61:  // HALF_FLOAT_OES
+      return window.Uint16Array;
+    case gl.FLOAT:
+      return window.Float32Array;
+    default:
+      throw 'unknown gl type ' + glEnumToString(gl, type);
+  }
+};
+
+/**
+ * Returns the number of bytes per component for a given WebGL type.
+ * @param {!WebGLRenderingContext} gl A WebGLRenderingContext.
+ * @param {GLenum} type The WebGL type (eg, gl.UNSIGNED_BYTE)
+ * @return {number} The number of bytes per component.
+ */
+var getBytesPerComponent = function(gl, type) {
+  switch (type) {
+    case gl.BYTE:
+    case gl.UNSIGNED_BYTE:
+      return 1;
+    case gl.SHORT:
+    case gl.UNSIGNED_SHORT:
+    case gl.UNSIGNED_SHORT_5_6_5:
+    case gl.UNSIGNED_SHORT_4_4_4_4:
+    case gl.UNSIGNED_SHORT_5_5_5_1:
+    case gl.HALF_FLOAT:
+    case 0x8D61:  // HALF_FLOAT_OES
+      return 2;
+    case gl.INT:
+    case gl.UNSIGNED_INT:
+    case gl.UNSIGNED_INT_5_9_9_9_REV:
+    case gl.UNSIGNED_INT_10F_11F_11F_REV:
+    case gl.UNSIGNED_INT_2_10_10_10_REV:
+    case gl.UNSIGNED_INT_24_8:
+    case gl.FLOAT:
+      return 4;
+    default:
+      throw 'unknown gl type ' + glEnumToString(gl, type);
+  }
+};
+
+/**
+ * Returns the number of typed array elements per pixel for a given WebGL
+ * format/type combination. The corresponding typed array type can be determined
+ * by calling glTypeToTypedArrayType.
+ * @param {!WebGLRenderingContext} gl A WebGLRenderingContext.
+ * @param {GLenum} format The WebGL format (eg, gl.RGBA)
+ * @param {GLenum} type The WebGL type (eg, gl.UNSIGNED_BYTE)
+ * @return {number} The number of typed array elements per pixel.
+ */
+var getTypedArrayElementsPerPixel = function(gl, format, type) {
+  switch (type) {
+    case gl.UNSIGNED_SHORT_5_6_5:
+    case gl.UNSIGNED_SHORT_4_4_4_4:
+    case gl.UNSIGNED_SHORT_5_5_5_1:
+      return 1;
+    case gl.UNSIGNED_BYTE:
+      break;
+    default:
+      throw 'not a gl type for color information ' + glEnumToString(gl, type);
+  }
+
+  switch (format) {
+    case gl.RGBA:
+      return 4;
+    case gl.RGB:
+      return 3;
+    case gl.LUMINANCE_ALPHA:
+      return 2;
+    case gl.LUMINANCE:
+    case gl.ALPHA:
+      return 1;
+    default:
+      throw 'unknown gl format ' + glEnumToString(gl, format);
+  }
+};
+
+/**
+ * Fills the given texture with a solid color.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!WebGLTexture} tex The texture to fill.
+ * @param {number} width The width of the texture to create.
+ * @param {number} height The height of the texture to create.
+ * @param {!Array.<number>} color The color to fill with.
+ *        where each element is in the range 0 to 255.
+ * @param {number} opt_level The level of the texture to fill. Default = 0.
+ * @param {number} opt_format The format for the texture.
+ * @param {number} opt_internalFormat The internal format for the texture.
+ */
+var fillTexture = function(gl, tex, width, height, color, opt_level, opt_format, opt_type, opt_internalFormat) {
+  opt_level = opt_level || 0;
+  opt_format = opt_format || gl.RGBA;
+  opt_type = opt_type || gl.UNSIGNED_BYTE;
+  opt_internalFormat = opt_internalFormat || opt_format;
+  var pack = gl.getParameter(gl.UNPACK_ALIGNMENT);
+  var numComponents = color.length;
+  var bytesPerComponent = getBytesPerComponent(gl, opt_type);
+  var rowSize = numComponents * width * bytesPerComponent;
+  // See equation 3.10 in ES 2.0 spec and equation 3.13 in ES 3.0 spec for paddedRowLength calculation.
+  // k is paddedRowLength.
+  // n is numComponents.
+  // l is width.
+  // a is pack.
+  // s is bytesPerComponent.
+  var paddedRowLength;
+  if (bytesPerComponent >= pack)
+    paddedRowLength = numComponents * width;
+  else
+    paddedRowLength = Math.floor((rowSize + pack - 1) / pack) * pack / bytesPerComponent;
+  var size = width * numComponents + (height - 1) * paddedRowLength;
+  var buf = new (glTypeToTypedArrayType(gl, opt_type))(size);
+  for (var yy = 0; yy < height; ++yy) {
+    var off = yy * paddedRowLength;
+    for (var xx = 0; xx < width; ++xx) {
+      for (var jj = 0; jj < numComponents; ++jj) {
+        buf[off++] = color[jj];
+      }
+    }
+  }
+  gl.bindTexture(gl.TEXTURE_2D, tex);
+  gl.texImage2D(
+      gl.TEXTURE_2D, opt_level, opt_internalFormat, width, height, 0,
+      opt_format, opt_type, buf);
+};
+
+/**
+ * Creates a texture and fills it with a solid color.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} width The width of the texture to create.
+ * @param {number} height The height of the texture to create.
+ * @param {!Array.<number>} color The color to fill with. A 4 element array
+ *        where each element is in the range 0 to 255.
+ * @return {!WebGLTexture}
+ */
+var createColoredTexture = function(gl, width, height, color) {
+  var tex = gl.createTexture();
+  fillTexture(gl, tex, width, height, color);
+  return tex;
+};
+
+var ubyteToFloat = function(c) {
+  return c / 255;
+};
+
+var ubyteColorToFloatColor = function(color) {
+  var floatColor = [];
+  for (var ii = 0; ii < color.length; ++ii) {
+    floatColor[ii] = ubyteToFloat(color[ii]);
+  }
+  return floatColor;
+};
+
+/**
+ * Sets the "u_color" uniform of the current program to color.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<number>} color 4 element array of 0-1 color
+ *      components.
+ */
+var setFloatDrawColor = function(gl, color) {
+  var program = gl.getParameter(gl.CURRENT_PROGRAM);
+  var colorLocation = gl.getUniformLocation(program, "u_color");
+  gl.uniform4fv(colorLocation, color);
+};
+
+/**
+ * Sets the "u_color" uniform of the current program to color.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<number>} color 4 element array of 0-255 color
+ *      components.
+ */
+var setUByteDrawColor = function(gl, color) {
+  setFloatDrawColor(gl, ubyteColorToFloatColor(color));
+};
+
+/**
+ * Draws a previously setup quad in the given color.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<number>} color The color to draw with. A 4
+ *        element array where each element is in the range 0 to
+ *        1.
+ */
+var drawFloatColorQuad = function(gl, color) {
+  var program = gl.getParameter(gl.CURRENT_PROGRAM);
+  var colorLocation = gl.getUniformLocation(program, "u_color");
+  gl.uniform4fv(colorLocation, color);
+  gl.drawArrays(gl.TRIANGLES, 0, 6);
+};
+
+
+/**
+ * Draws a previously setup quad in the given color.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<number>} color The color to draw with. A 4
+ *        element array where each element is in the range 0 to
+ *        255.
+ */
+var drawUByteColorQuad = function(gl, color) {
+  drawFloatColorQuad(gl, ubyteColorToFloatColor(color));
+};
+
+/**
+ * Draws a previously setupUnitQuad.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ */
+var drawUnitQuad = function(gl) {
+  gl.drawArrays(gl.TRIANGLES, 0, 6);
+};
+
+var dummySetProgramAndDrawNothing = function(gl) {
+  if (!gl._wtuDummyProgram) {
+    gl._wtuDummyProgram = setupProgram(gl, [
+      "void main() { gl_Position = vec4(0.0); }",
+      "void main() { gl_FragColor = vec4(0.0); }"
+    ], [], []);
+  }
+  gl.useProgram(gl._wtuDummyProgram);
+  gl.drawArrays(gl.TRIANGLES, 0, 3);
+};
+
+/**
+ * Clears then Draws a previously setupUnitQuad.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!Array.<number>} opt_color The color to fill clear with before
+ *        drawing. A 4 element array where each element is in the range 0 to
+ *        255. Default [255, 255, 255, 255]
+ */
+var clearAndDrawUnitQuad = function(gl, opt_color) {
+  opt_color = opt_color || [255, 255, 255, 255];
+  gl.clearColor(
+      opt_color[0] / 255,
+      opt_color[1] / 255,
+      opt_color[2] / 255,
+      opt_color[3] / 255);
+  gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
+  drawUnitQuad(gl);
+};
+
+/**
+ * Draws a quad previously setup with setupIndexedQuad.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} gridRes Resolution of grid.
+ */
+var drawIndexedQuad = function(gl, gridRes) {
+  gl.drawElements(gl.TRIANGLES, gridRes * gridRes * 6, gl.UNSIGNED_SHORT, 0);
+};
+
+/**
+ * Draws a previously setupIndexedQuad
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number} gridRes Resolution of grid.
+ * @param {!Array.<number>} opt_color The color to fill clear with before
+ *        drawing. A 4 element array where each element is in the range 0 to
+ *        255. Default [255, 255, 255, 255]
+ */
+var clearAndDrawIndexedQuad = function(gl, gridRes, opt_color) {
+  opt_color = opt_color || [255, 255, 255, 255];
+  gl.clearColor(
+      opt_color[0] / 255,
+      opt_color[1] / 255,
+      opt_color[2] / 255,
+      opt_color[3] / 255);
+  gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
+  drawIndexedQuad(gl, gridRes);
+};
+
+/**
+ * Clips a range to min, max
+ * (Eg. clipToRange(-5,7,0,20) would return {value:0,extent:2}
+ * @param {number} value start of range
+ * @param {number} extent extent of range
+ * @param {number} min min.
+ * @param {number} max max.
+ * @return {!{value:number,extent:number}} The clipped value.
+ */
+var clipToRange = function(value, extent, min, max) {
+  if (value < min) {
+    extent -= min - value;
+    value = min;
+  }
+  var end = value + extent;
+  if (end > max) {
+    extent -= end - max;
+  }
+  if (extent < 0) {
+    value = max;
+    extent = 0;
+  }
+  return {value:value, extent: extent};
+};
+
+/**
+ * Determines if the passed context is an instance of a WebGLRenderingContext
+ * or later variant (like WebGL2RenderingContext)
+ * @param {CanvasRenderingContext} ctx The context to check.
+ */
+var isWebGLContext = function(ctx) {
+  if (ctx instanceof WebGLRenderingContext)
+    return true;
+
+  if ('WebGL2RenderingContext' in window && ctx instanceof WebGL2RenderingContext)
+    return true;
+
+  return false;
+};
+
+/**
+ * Creates a check rect is used by checkCanvasRects.
+ * @param {number} x left corner of region to check.
+ * @param {number} y bottom corner of region to check in case of checking from
+ *        a GL context or top corner in case of checking from a 2D context.
+ * @param {number} width width of region to check.
+ * @param {number} height width of region to check.
+ * @param {!Array.<number>} color The color expected. A 4 element array where
+ *        each element is in the range 0 to 255.
+ * @param {string} opt_msg Message to associate with success. Eg
+ *        ("should be red").
+ * @param {number} opt_errorRange Optional. Acceptable error in
+ *        color checking. 0 by default.
+ */
+var makeCheckRect = function(x, y, width, height, color, msg, errorRange) {
+  var rect = {
+    'x': x, 'y': y,
+    'width': width, 'height': height,
+    'color': color, 'msg': msg,
+    'errorRange': errorRange,
+
+    'checkRect': function (buf, l, b, w) {
+      for (var px = (x - l) ; px < (x + width - l) ; ++px) {
+        for (var py = (y - b) ; py < (y + height - b) ; ++py) {
+          var offset = (py * w + px) * 4;
+          for (var j = 0; j < color.length; ++j) {
+            if (Math.abs(buf[offset + j] - color[j]) > errorRange) {
+              testFailed(msg);
+              var was = buf[offset + 0].toString();
+              for (j = 1; j < color.length; ++j) {
+                was += "," + buf[offset + j];
+              }
+              debug('at (' + px + ', ' + py +
+                    ') expected: ' + color + ' was ' + was);
+              return;
+            }
+          }
+        }
+      }
+      testPassed(msg);
+    }
+  }
+  return rect;
+};
+
+/**
+ * Checks that a portions of a canvas or the currently attached framebuffer is 1 color.
+ * @param {!WebGLRenderingContext|CanvasRenderingContext2D} gl The
+ *         WebGLRenderingContext or 2D context to use.
+ * @param {!Array.<checkRect>} array of rects to check for matching color.
+ */
+var checkCanvasRects = function(gl, rects) {
+  if (rects.length > 0) {
+    var left = rects[0].x;
+    var right = rects[0].x + rects[1].width;
+    var bottom = rects[0].y;
+    var top = rects[0].y + rects[0].height;
+    for (var i = 1; i < rects.length; ++i) {
+      left = Math.min(left, rects[i].x);
+      right = Math.max(right, rects[i].x + rects[i].width);
+      bottom = Math.min(bottom, rects[i].y);
+      top = Math.max(top, rects[i].y + rects[i].height);
+    }
+    var width = right - left;
+    var height = top - bottom;
+    var buf = new Uint8Array(width * height * 4);
+    gl.readPixels(left, bottom, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buf);
+    for (var i = 0; i < rects.length; ++i) {
+      rects[i].checkRect(buf, left, bottom, width);
+    }
+  }
+};
+
+/**
+ * Checks that a portion of a canvas or the currently attached framebuffer is 1 color.
+ * @param {!WebGLRenderingContext|CanvasRenderingContext2D} gl The
+ *         WebGLRenderingContext or 2D context to use.
+ * @param {number} x left corner of region to check.
+ * @param {number} y bottom corner of region to check in case of checking from
+ *        a GL context or top corner in case of checking from a 2D context.
+ * @param {number} width width of region to check.
+ * @param {number} height width of region to check.
+ * @param {!Array.<number>} color The color expected. A 4 element array where
+ *        each element is in the range 0 to 255.
+ * @param {number} opt_errorRange Optional. Acceptable error in
+ *        color checking. 0 by default.
+ * @param {!function()} sameFn Function to call if all pixels
+ *        are the same as color.
+ * @param {!function()} differentFn Function to call if a pixel
+ *        is different than color
+ * @param {!function()} logFn Function to call for logging.
+ * @param {TypedArray} opt_readBackBuf optional buffer to read back into.
+ *        Typically passed to either reuse buffer, or support readbacks from
+ *        floating-point/norm16 framebuffers.
+ * @param {GLenum} opt_readBackType optional read back type, defaulting to
+ *        gl.UNSIGNED_BYTE. Can be used to support readback from floating-point
+ *        /norm16 framebuffers.
+ * @param {GLenum} opt_readBackFormat optional read back format, defaulting to
+ *        gl.RGBA. Can be used to support readback from norm16
+ *        framebuffers.
+ */
+var checkCanvasRectColor = function(gl, x, y, width, height, color, opt_errorRange, sameFn, differentFn, logFn, opt_readBackBuf, opt_readBackType, opt_readBackFormat) {
+  if (isWebGLContext(gl) && !gl.getParameter(gl.FRAMEBUFFER_BINDING)) {
+    // We're reading the backbuffer so clip.
+    var xr = clipToRange(x, width, 0, gl.canvas.width);
+    var yr = clipToRange(y, height, 0, gl.canvas.height);
+    if (!xr.extent || !yr.extent) {
+      logFn("checking rect: effective width or height is zero");
+      sameFn();
+      return;
+    }
+    x = xr.value;
+    y = yr.value;
+    width = xr.extent;
+    height = yr.extent;
+  }
+  var errorRange = opt_errorRange || 0;
+  if (!errorRange.length) {
+    errorRange = [errorRange, errorRange, errorRange, errorRange]
+  }
+  var buf;
+  if (isWebGLContext(gl)) {
+    buf = opt_readBackBuf ? opt_readBackBuf : new Uint8Array(width * height * 4);
+    var readBackType = opt_readBackType ? opt_readBackType : gl.UNSIGNED_BYTE;
+    var readBackFormat = opt_readBackFormat ? opt_readBackFormat : gl.RGBA;
+    gl.readPixels(x, y, width, height, readBackFormat, readBackType, buf);
+  } else {
+    buf = gl.getImageData(x, y, width, height).data;
+  }
+  for (var i = 0; i < width * height; ++i) {
+    var offset = i * 4;
+    for (var j = 0; j < color.length; ++j) {
+      if (Math.abs(buf[offset + j] - color[j]) > errorRange[j]) {
+        var was = buf[offset + 0].toString();
+        for (j = 1; j < color.length; ++j) {
+          was += "," + buf[offset + j];
+        }
+        differentFn('at (' + (x + (i % width)) + ', ' + (y + Math.floor(i / width)) +
+                    ') expected: ' + color + ' was ' + was, buf);
+        return;
+      }
+    }
+  }
+  sameFn();
+};
+
+/**
+ * Checks that a portion of a canvas or the currently attached framebuffer is 1 color.
+ * @param {!WebGLRenderingContext|CanvasRenderingContext2D} gl The
+ *         WebGLRenderingContext or 2D context to use.
+ * @param {number} x left corner of region to check.
+ * @param {number} y bottom corner of region to check in case of checking from
+ *        a GL context or top corner in case of checking from a 2D context.
+ * @param {number} width width of region to check.
+ * @param {number} height width of region to check.
+ * @param {!Array.<number>} color The color expected. A 4 element array where
+ *        each element is in the range 0 to 255.
+ * @param {string} opt_msg Message to associate with success or failure. Eg
+ *        ("should be red").
+ * @param {number} opt_errorRange Optional. Acceptable error in
+ *        color checking. 0 by default.
+ * @param {TypedArray} opt_readBackBuf optional buffer to read back into.
+ *        Typically passed to either reuse buffer, or support readbacks from
+ *        floating-point/norm16 framebuffers.
+ * @param {GLenum} opt_readBackType optional read back type, defaulting to
+ *        gl.UNSIGNED_BYTE. Can be used to support readback from floating-point
+ *        /norm16 framebuffers.
+ * @param {GLenum} opt_readBackFormat optional read back format, defaulting to
+ *        gl.RGBA. Can be used to support readback from floating-point
+ *        /norm16 framebuffers.
+ */
+var checkCanvasRect = function(gl, x, y, width, height, color, opt_msg, opt_errorRange, opt_readBackBuf, opt_readBackType, opt_readBackFormat) {
+  checkCanvasRectColor(
+      gl, x, y, width, height, color, opt_errorRange,
+      function() {
+        var msg = opt_msg;
+        if (msg === undefined)
+          msg = "should be " + color.toString();
+        testPassed(msg);
+      },
+      function(differentMsg) {
+        var msg = opt_msg;
+        if (msg === undefined)
+          msg = "should be " + color.toString();
+        testFailed(msg + "\n" + differentMsg);
+      },
+      debug,
+      opt_readBackBuf,
+      opt_readBackType,
+      opt_readBackFormat);
+};
+
+/**
+ * Checks that an entire canvas or the currently attached framebuffer is 1 color.
+ * @param {!WebGLRenderingContext|CanvasRenderingContext2D} gl The
+ *         WebGLRenderingContext or 2D context to use.
+ * @param {!Array.<number>} color The color expected. A 4 element array where
+ *        each element is in the range 0 to 255.
+ * @param {string} msg Message to associate with success. Eg ("should be red").
+ * @param {number} errorRange Optional. Acceptable error in
+ *        color checking. 0 by default.
+ */
+var checkCanvas = function(gl, color, msg, errorRange) {
+  checkCanvasRect(gl, 0, 0, gl.canvas.width, gl.canvas.height, color, msg, errorRange);
+};
+
+/**
+ * Checks a rectangular area both inside the area and outside
+ * the area.
+ * @param {!WebGLRenderingContext|CanvasRenderingContext2D} gl The
+ *         WebGLRenderingContext or 2D context to use.
+ * @param {number} x left corner of region to check.
+ * @param {number} y bottom corner of region to check in case of checking from
+ *        a GL context or top corner in case of checking from a 2D context.
+ * @param {number} width width of region to check.
+ * @param {number} height width of region to check.
+ * @param {!Array.<number>} innerColor The color expected inside
+ *     the area. A 4 element array where each element is in the
+ *     range 0 to 255.
+ * @param {!Array.<number>} outerColor The color expected
+ *     outside. A 4 element array where each element is in the
+ *     range 0 to 255.
+ * @param {!number} opt_edgeSize: The number of pixels to skip
+ *     around the edges of the area. Defaut 0.
+ * @param {!{width:number, height:number}} opt_outerDimensions
+ *     The outer dimensions. Default the size of gl.canvas.
+ */
+var checkAreaInAndOut = function(gl, x, y, width, height, innerColor, outerColor, opt_edgeSize, opt_outerDimensions) {
+  var outerDimensions = opt_outerDimensions || { width: gl.canvas.width, height: gl.canvas.height };
+  var edgeSize = opt_edgeSize || 0;
+  checkCanvasRect(gl, x + edgeSize, y + edgeSize, width - edgeSize * 2, height - edgeSize * 2, innerColor);
+  checkCanvasRect(gl, 0, 0, x - edgeSize, outerDimensions.height, outerColor);
+  checkCanvasRect(gl, x + width + edgeSize, 0, outerDimensions.width - x - width - edgeSize, outerDimensions.height, outerColor);
+  checkCanvasRect(gl, 0, 0, outerDimensions.width, y - edgeSize, outerColor);
+  checkCanvasRect(gl, 0, y + height + edgeSize, outerDimensions.width, outerDimensions.height - y - height - edgeSize, outerColor);
+};
+
+/**
+ * Checks that an entire buffer matches the floating point values provided.
+ * (WebGL 2.0 only)
+ * @param {!WebGL2RenderingContext} gl The WebGL2RenderingContext to use.
+ * @param {number} target The buffer target to bind to.
+ * @param {!Array.<number>} expected The values expected.
+ * @param {string} opt_msg Optional. Message to associate with success. Eg ("should be red").
+ * @param {number} opt_errorRange Optional. Acceptable error in value checking. 0.001 by default.
+ */
+var checkFloatBuffer = function(gl, target, expected, opt_msg, opt_errorRange) {
+  if (opt_msg === undefined)
+    opt_msg = "buffer should match expected values";
+
+  if (opt_errorRange === undefined)
+    opt_errorRange = 0.001;
+
+  var floatArray = new Float32Array(expected.length);
+  gl.getBufferSubData(target, 0, floatArray);
+
+  for (var i = 0; i < expected.length; i++) {
+    if (Math.abs(floatArray[i] - expected[i]) > opt_errorRange) {
+      testFailed(opt_msg);
+      debug('at [' + i + '] expected: ' + expected[i] + ' was ' + floatArray[i]);
+      return;
+    }
+  }
+  testPassed(opt_msg);
+};
+
+/**
+ * Loads a texture, calls callback when finished.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} url URL of image to load
+ * @param {function(!Image): void} callback Function that gets called after
+ *        image has loaded
+ * @return {!WebGLTexture} The created texture.
+ */
+var loadTexture = function(gl, url, callback) {
+    var texture = gl.createTexture();
+    gl.bindTexture(gl.TEXTURE_2D, texture);
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
+    var image = new Image();
+    image.onload = function() {
+        gl.bindTexture(gl.TEXTURE_2D, texture);
+        gl.pixelStorei(gl.UNPACK_FLIP_Y_WEBGL, true);
+        gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, image);
+        callback(image);
+    };
+    image.src = url;
+    return texture;
+};
+
+/**
+ * Checks whether the bound texture has expected dimensions. One corner pixel
+ * of the texture will be changed as a side effect.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!WebGLTexture} texture The texture to check.
+ * @param {number} width Expected width.
+ * @param {number} height Expected height.
+ * @param {GLenum} opt_format The texture's format. Defaults to RGBA.
+ * @param {GLenum} opt_type The texture's type. Defaults to UNSIGNED_BYTE.
+ */
+var checkTextureSize = function(gl, width, height, opt_format, opt_type) {
+  opt_format = opt_format || gl.RGBA;
+  opt_type = opt_type || gl.UNSIGNED_BYTE;
+
+  var numElements = getTypedArrayElementsPerPixel(gl, opt_format, opt_type);
+  var buf = new (glTypeToTypedArrayType(gl, opt_type))(numElements);
+
+  var errors = 0;
+  gl.texSubImage2D(gl.TEXTURE_2D, 0, width - 1, height - 1, 1, 1, opt_format, opt_type, buf);
+  if (gl.getError() != gl.NO_ERROR) {
+    testFailed("Texture was smaller than the expected size " + width + "x" + height);
+    ++errors;
+  }
+  gl.texSubImage2D(gl.TEXTURE_2D, 0, width - 1, height, 1, 1, opt_format, opt_type, buf);
+  if (gl.getError() == gl.NO_ERROR) {
+    testFailed("Texture was taller than " + height);
+    ++errors;
+  }
+  gl.texSubImage2D(gl.TEXTURE_2D, 0, width, height - 1, 1, 1, opt_format, opt_type, buf);
+  if (gl.getError() == gl.NO_ERROR) {
+    testFailed("Texture was wider than " + width);
+    ++errors;
+  }
+  if (errors == 0) {
+    testPassed("Texture had the expected size " + width + "x" + height);
+  }
+};
+
+/**
+ * Makes a shallow copy of an object.
+ * @param {!Object} src Object to copy
+ * @return {!Object} The copy of src.
+ */
+var shallowCopyObject = function(src) {
+  var dst = {};
+  for (var attr in src) {
+    if (src.hasOwnProperty(attr)) {
+      dst[attr] = src[attr];
+    }
+  }
+  return dst;
+};
+
+/**
+ * Checks if an attribute exists on an object case insensitive.
+ * @param {!Object} obj Object to check
+ * @param {string} attr Name of attribute to look for.
+ * @return {string?} The name of the attribute if it exists,
+ *         undefined if not.
+ */
+var hasAttributeCaseInsensitive = function(obj, attr) {
+  var lower = attr.toLowerCase();
+  for (var key in obj) {
+    if (obj.hasOwnProperty(key) && key.toLowerCase() == lower) {
+      return key;
+    }
+  }
+};
+
+/**
+ * Returns a map of URL querystring options
+ * @return {Object?} Object containing all the values in the URL querystring
+ */
+var getUrlOptions = (function() {
+  var _urlOptionsParsed = false;
+  var _urlOptions = {};
+  return function() {
+    if (!_urlOptionsParsed) {
+      var s = window.location.href;
+      var q = s.indexOf("?");
+      var e = s.indexOf("#");
+      if (e < 0) {
+        e = s.length;
+      }
+      var query = s.substring(q + 1, e);
+      var pairs = query.split("&");
+      for (var ii = 0; ii < pairs.length; ++ii) {
+        var keyValue = pairs[ii].split("=");
+        var key = keyValue[0];
+        var value = decodeURIComponent(keyValue[1]);
+        _urlOptions[key] = value;
+      }
+      _urlOptionsParsed = true;
+    }
+
+    return _urlOptions;
+  }
+})();
+
+var default3DContextVersion = 1;
+
+/**
+ * Set the default context version for create3DContext.
+ * Initially the default version is 1.
+ * @param {number} Default version of WebGL contexts.
+ */
+var setDefault3DContextVersion = function(version) {
+    default3DContextVersion = version;
+};
+
+/**
+ * Get the default contex version for create3DContext.
+ * First it looks at the URI option |webglVersion|. If it does not exist,
+ * then look at the global default3DContextVersion variable.
+ */
+var getDefault3DContextVersion = function() {
+    return parseInt(getUrlOptions().webglVersion, 10) || default3DContextVersion;
+};
+
+/**
+ * Creates a webgl context.
+ * @param {!Canvas|string} opt_canvas The canvas tag to get
+ *     context from. If one is not passed in one will be
+ *     created. If it's a string it's assumed to be the id of a
+ *     canvas.
+ * @param {Object} opt_attributes Context attributes.
+ * @param {!number} opt_version Version of WebGL context to create.
+ *     The default version can be set by calling setDefault3DContextVersion.
+ * @return {!WebGLRenderingContext} The created context.
+ */
+var create3DContext = function(opt_canvas, opt_attributes, opt_version) {
+  if (window.initTestingHarness) {
+    window.initTestingHarness();
+  }
+  var attributes = shallowCopyObject(opt_attributes || {});
+  if (!hasAttributeCaseInsensitive(attributes, "antialias")) {
+    attributes.antialias = false;
+  }
+  if (!opt_version) {
+    opt_version = getDefault3DContextVersion();
+  }
+  opt_canvas = opt_canvas || document.createElement("canvas");
+  if (typeof opt_canvas == 'string') {
+    opt_canvas = document.getElementById(opt_canvas);
+  }
+  var context = null;
+
+  var names;
+  switch (opt_version) {
+    case 2:
+      names = ["webgl2"]; break;
+    default:
+      names = ["webgl", "experimental-webgl"]; break;
+  }
+
+  for (var i = 0; i < names.length; ++i) {
+    try {
+      context = opt_canvas.getContext(names[i], attributes);
+    } catch (e) {
+    }
+    if (context) {
+      break;
+    }
+  }
+  if (!context) {
+    testFailed("Unable to fetch WebGL rendering context for Canvas");
+  } else {
+    if (!window._wtu_contexts) {
+      window._wtu_contexts = []
+    }
+    window._wtu_contexts.push(context);
+  }
+  return context;
+};
+
+/**
+ * Indicates whether the given context is WebGL 2.0 or greater.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @return {boolean} True if the given context is WebGL 2.0 or greater.
+ */
+var isWebGL2 = function(gl) {
+  // Duck typing is used so that the conformance suite can be run
+  // against libraries emulating WebGL 1.0 on top of WebGL 2.0.
+  return !!gl.drawArraysInstanced;
+};
+
+/**
+ * Defines the exception type for a GL error.
+ * @constructor
+ * @param {string} message The error message.
+ * @param {number} error GL error code
+ */
+function GLErrorException (message, error) {
+   this.message = message;
+   this.name = "GLErrorException";
+   this.error = error;
+};
+
+/**
+ * Wraps a WebGL function with a function that throws an exception if there is
+ * an error.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} fname Name of function to wrap.
+ * @return {function()} The wrapped function.
+ */
+var createGLErrorWrapper = function(context, fname) {
+  return function() {
+    var rv = context[fname].apply(context, arguments);
+    var err = context.getError();
+    if (err != context.NO_ERROR) {
+      var msg = "GL error " + glEnumToString(context, err) + " in " + fname;
+      throw new GLErrorException(msg, err);
+    }
+    return rv;
+  };
+};
+
+/**
+ * Creates a WebGL context where all functions are wrapped to throw an exception
+ * if there is an error.
+ * @param {!Canvas} canvas The HTML canvas to get a context from.
+ * @param {Object} opt_attributes Context attributes.
+ * @param {!number} opt_version Version of WebGL context to create
+ * @return {!Object} The wrapped context.
+ */
+function create3DContextWithWrapperThatThrowsOnGLError(canvas, opt_attributes, opt_version) {
+  var context = create3DContext(canvas, opt_attributes, opt_version);
+  var wrap = {};
+  for (var i in context) {
+    try {
+      if (typeof context[i] == 'function') {
+        wrap[i] = createGLErrorWrapper(context, i);
+      } else {
+        wrap[i] = context[i];
+      }
+    } catch (e) {
+      error("createContextWrapperThatThrowsOnGLError: Error accessing " + i);
+    }
+  }
+  wrap.getError = function() {
+      return context.getError();
+  };
+  return wrap;
+};
+
+/**
+ * Tests that an evaluated expression generates a specific GL error.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number|Array.<number>} glErrors The expected gl error or an array of expected errors.
+ * @param {string} evalStr The string to evaluate.
+ */
+var shouldGenerateGLError = function(gl, glErrors, evalStr, opt_msg) {
+  var exception;
+  try {
+    eval(evalStr);
+  } catch (e) {
+    exception = e;
+  }
+  if (exception) {
+    testFailed(evalStr + " threw exception " + exception);
+    return -1;
+  } else {
+    if (!opt_msg) {
+      opt_msg = "after evaluating: " + evalStr;
+    }
+    return glErrorShouldBe(gl, glErrors, opt_msg);
+  }
+};
+
+/**
+ * Tests that an evaluated expression does not generate a GL error.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} evalStr The string to evaluate.
+ */
+var failIfGLError = function(gl, evalStr) {
+  var exception;
+  try {
+    eval(evalStr);
+  } catch (e) {
+    exception = e;
+  }
+  if (exception) {
+    testFailed(evalStr + " threw exception " + exception);
+  } else {
+    glErrorShouldBeImpl(gl, gl.NO_ERROR, false, "after evaluating: " + evalStr);
+  }
+};
+
+/**
+ * Tests that the first error GL returns is the specified error.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number|Array.<number>} glErrors The expected gl error or an array of expected errors.
+ * @param {string} opt_msg Optional additional message.
+ */
+var glErrorShouldBe = function(gl, glErrors, opt_msg) {
+  return glErrorShouldBeImpl(gl, glErrors, true, opt_msg);
+};
+
+const glErrorAssert = function(gl, glErrors, opt_msg) {
+  return glErrorShouldBeImpl(gl, glErrors, false, opt_msg);
+};
+
+/**
+ * Tests that the given framebuffer has a specific status
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number|Array.<number>} glStatuses The expected gl
+ *        status or an array of expected statuses.
+ * @param {string} opt_msg Optional additional message.
+ */
+var framebufferStatusShouldBe = function(gl, target, glStatuses, opt_msg) {
+  if (!glStatuses.length) {
+    glStatuses = [glStatuses];
+  }
+  opt_msg = opt_msg || "";
+  const status = gl.checkFramebufferStatus(target);
+  const ndx = glStatuses.indexOf(status);
+  const expected = glStatuses.map((status) => {
+    return glEnumToString(gl, status);
+  }).join(' or ');
+  if (ndx < 0) {
+    let msg = "checkFramebufferStatus expected" + ((glStatuses.length > 1) ? " one of: " : ": ") +
+      expected +  ". Was " + glEnumToString(gl, status);
+    if (opt_msg) {
+      msg += ": " + opt_msg;
+    }
+    testFailed(msg);
+    return false;
+  }
+  let msg = `checkFramebufferStatus was ${glEnumToString(gl, status)}`;
+  if (glStatuses.length > 1) {
+    msg += `, one of: ${expected}`;
+  }
+  if (opt_msg) {
+    msg += ": " + opt_msg;
+  }
+  testPassed(msg);
+  return [status];
+}
+
+/**
+ * Tests that the first error GL returns is the specified error. Allows suppression of successes.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {number|Array.<number>} glErrors The expected gl error or an array of expected errors.
+ * @param {boolean} reportSuccesses Whether to report successes as passes, or to silently pass.
+ * @param {string} opt_msg Optional additional message.
+ */
+var glErrorShouldBeImpl = function(gl, glErrors, reportSuccesses, opt_msg) {
+  if (!glErrors.length) {
+    glErrors = [glErrors];
+  }
+  opt_msg = opt_msg || "";
+
+  const fnErrStr = function(errVal) {
+    if (errVal == 0) return "NO_ERROR";
+    return glEnumToString(gl, errVal);
+  };
+
+  var err = gl.getError();
+  var ndx = glErrors.indexOf(err);
+  var errStrs = [];
+  for (var ii = 0; ii < glErrors.length; ++ii) {
+    errStrs.push(fnErrStr(glErrors[ii]));
+  }
+  var expected = errStrs.join(" or ");
+  if (ndx < 0) {
+    var msg = "getError expected" + ((glErrors.length > 1) ? " one of: " : ": ");
+    testFailed(msg + expected +  ". Was " + fnErrStr(err) + " : " + opt_msg);
+  } else if (reportSuccesses) {
+    var msg = "getError was " + ((glErrors.length > 1) ? "one of: " : "expected value: ");
+    testPassed(msg + expected + " : " + opt_msg);
+  }
+  return err;
+};
+
+/**
+ * Tests that a function throws or not.
+ * @param {!WebGLContext} gl The WebGLContext to use.
+ * @param throwType Type of thrown error (e.g. TypeError), or false.
+ * @param {string} info Info on what's being tested
+ * @param {function} func The func to test.
+ */
+var shouldThrow = function(gl, throwType, info, func) {
+  while (gl.getError()) {}
+
+  var shouldThrow = (throwType != false);
+
+  try {
+    func();
+
+    if (shouldThrow) {
+      testFailed("Should throw a " + throwType.name + ": " + info);
+    } else {
+      testPassed("Should not have thrown: " + info);
+    }
+  } catch (e) {
+    if (shouldThrow) {
+      if (e instanceof throwType) {
+        testPassed("Should throw a " + throwType.name + ": " + info);
+      } else {
+        testFailed("Should throw a " + throwType.name + ", threw " + e.name + ": " + info);
+      }
+    } else {
+      testFailed("Should not have thrown: " + info);
+    }
+
+    if (gl.getError()) {
+      testFailed("Should not generate an error when throwing: " + info);
+    }
+  }
+
+  while (gl.getError()) {}
+};
+
+/**
+ * Links a WebGL program, throws if there are errors.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!WebGLProgram} program The WebGLProgram to link.
+ * @param {function(string): void} opt_errorCallback callback for errors.
+ */
+var linkProgram = function(gl, program, opt_errorCallback) {
+  var errFn = opt_errorCallback || testFailed;
+  // Link the program
+  gl.linkProgram(program);
+
+  // Check the link status
+  var linked = gl.getProgramParameter(program, gl.LINK_STATUS);
+  if (!linked) {
+    // something went wrong with the link
+    var error = gl.getProgramInfoLog (program);
+
+    errFn("Error in program linking:" + error);
+
+    gl.deleteProgram(program);
+  }
+};
+
+/**
+ * Loads text from an external file. This function is asynchronous.
+ * @param {string} url The url of the external file.
+ * @param {!function(bool, string): void} callback that is sent a bool for
+ *     success and the string.
+ */
+var loadTextFileAsync = function(url, callback) {
+  log ("loading: " + url);
+  var error = 'loadTextFileAsync failed to load url "' + url + '"';
+  var request;
+  if (window.XMLHttpRequest) {
+    request = new XMLHttpRequest();
+    if (request.overrideMimeType) {
+      request.overrideMimeType('text/plain');
+    }
+  } else {
+    throw 'XMLHttpRequest is disabled';
+  }
+  try {
+    request.open('GET', url, true);
+    request.onreadystatechange = function() {
+      if (request.readyState == 4) {
+        var text = '';
+        // HTTP reports success with a 200 status. The file protocol reports
+        // success with zero. HTTP does not use zero as a status code (they
+        // start at 100).
+        // https://developer.mozilla.org/En/Using_XMLHttpRequest
+        var success = request.status == 200 || request.status == 0;
+        if (success) {
+          text = request.responseText;
+          log("completed load request: " + url);
+        } else {
+          log("loading " + url + " resulted in unexpected status: " + request.status + " " + request.statusText);
+        }
+        callback(success, text);
+      }
+    };
+    request.onerror = function(errorEvent) {
+      log("error occurred loading " + url);
+      callback(false, '');
+    };
+    request.send(null);
+  } catch (err) {
+    log("failed to load: " + url + " with exception " + err.message);
+    callback(false, '');
+  }
+};
+
+/**
+ * Recursively loads a file as a list. Each line is parsed for a relative
+ * path. If the file ends in .txt the contents of that file is inserted in
+ * the list.
+ *
+ * @param {string} url The url of the external file.
+ * @param {!function(bool, Array<string>): void} callback that is sent a bool
+ *     for success and the array of strings.
+ */
+var getFileListAsync = function(url, callback) {
+  var files = [];
+
+  var getFileListImpl = function(url, callback) {
+    var files = [];
+    if (url.substr(url.length - 4) == '.txt') {
+      loadTextFileAsync(url, function() {
+        return function(success, text) {
+          if (!success) {
+            callback(false, '');
+            return;
+          }
+          var lines = text.split('\n');
+          var prefix = '';
+          var lastSlash = url.lastIndexOf('/');
+          if (lastSlash >= 0) {
+            prefix = url.substr(0, lastSlash + 1);
+          }
+          var fail = false;
+          var count = 1;
+          var index = 0;
+          for (var ii = 0; ii < lines.length; ++ii) {
+            var str = lines[ii].replace(/^\s\s*/, '').replace(/\s\s*$/, '');
+            if (str.length > 4 &&
+                str[0] != '#' &&
+                str[0] != ";" &&
+                str.substr(0, 2) != "//") {
+              var names = str.split(/ +/);
+              var new_url = prefix + str;
+              if (names.length == 1) {
+                new_url = prefix + str;
+                ++count;
+                getFileListImpl(new_url, function(index) {
+                  return function(success, new_files) {
+                    log("got files: " + new_files.length);
+                    if (success) {
+                      files[index] = new_files;
+                    }
+                    finish(success);
+                  };
+                }(index++));
+              } else {
+                var s = "";
+                var p = "";
+                for (var jj = 0; jj < names.length; ++jj) {
+                  s += p + prefix + names[jj];
+                  p = " ";
+                }
+                files[index++] = s;
+              }
+            }
+          }
+          finish(true);
+
+          function finish(success) {
+            if (!success) {
+              fail = true;
+            }
+            --count;
+            log("count: " + count);
+            if (!count) {
+              callback(!fail, files);
+            }
+          }
+        }
+      }());
+
+    } else {
+      files.push(url);
+      callback(true, files);
+    }
+  };
+
+  getFileListImpl(url, function(success, files) {
+    // flatten
+    var flat = [];
+    flatten(files);
+    function flatten(files) {
+      for (var ii = 0; ii < files.length; ++ii) {
+        var value = files[ii];
+        if (typeof(value) == "string") {
+          flat.push(value);
+        } else {
+          flatten(value);
+        }
+      }
+    }
+    callback(success, flat);
+  });
+};
+
+/**
+ * Gets a file from a file/URL.
+ * @param {string} file the URL of the file to get.
+ * @return {string} The contents of the file.
+ */
+var readFile = function(file) {
+  var xhr = new XMLHttpRequest();
+  xhr.open("GET", file, false);
+  xhr.overrideMimeType("text/plain");
+  xhr.send();
+  return xhr.responseText.replace(/\r/g, "");
+};
+
+var readFileList = function(url) {
+  var files = [];
+  if (url.substr(url.length - 4) == '.txt') {
+    var lines = readFile(url).split('\n');
+    var prefix = '';
+    var lastSlash = url.lastIndexOf('/');
+    if (lastSlash >= 0) {
+      prefix = url.substr(0, lastSlash + 1);
+    }
+    for (var ii = 0; ii < lines.length; ++ii) {
+      var str = lines[ii].replace(/^\s\s*/, '').replace(/\s\s*$/, '');
+      if (str.length > 4 &&
+          str[0] != '#' &&
+          str[0] != ";" &&
+          str.substr(0, 2) != "//") {
+        var names = str.split(/ +/);
+        if (names.length == 1) {
+          var new_url = prefix + str;
+          files = files.concat(readFileList(new_url));
+        } else {
+          var s = "";
+          var p = "";
+          for (var jj = 0; jj < names.length; ++jj) {
+            s += p + prefix + names[jj];
+            p = " ";
+          }
+          files.push(s);
+        }
+      }
+    }
+  } else {
+    files.push(url);
+  }
+  return files;
+};
+
+/**
+ * Loads a shader.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} shaderSource The shader source.
+ * @param {number} shaderType The type of shader.
+ * @param {function(string): void} opt_errorCallback callback for errors.
+ * @param {boolean} opt_logShaders Whether to log shader source.
+ * @param {string} opt_shaderLabel Label that identifies the shader source in
+ *     the log.
+ * @param {string} opt_url URL from where the shader source was loaded from.
+ *     If opt_logShaders is set, then a link to the source file will also be
+ *     added.
+ * @param {boolean} Skip compilation status check. Default = false.
+ * @return {!WebGLShader} The created shader.
+ */
+var loadShader = function(
+    gl, shaderSource, shaderType, opt_errorCallback, opt_logShaders,
+    opt_shaderLabel, opt_url, opt_skipCompileStatus) {
+  var errFn = opt_errorCallback || error;
+  // Create the shader object
+  var shader = gl.createShader(shaderType);
+  if (shader == null) {
+    errFn("*** Error: unable to create shader '"+shaderSource+"'");
+    return null;
+  }
+
+  // Load the shader source
+  gl.shaderSource(shader, shaderSource);
+
+  // Compile the shader
+  gl.compileShader(shader);
+
+  if (opt_logShaders) {
+    var label = shaderType == gl.VERTEX_SHADER ? 'vertex shader' : 'fragment_shader';
+    if (opt_shaderLabel) {
+      label = opt_shaderLabel + ' ' + label;
+    }
+    addShaderSources(
+        gl, document.getElementById('console'), label, shader, shaderSource, opt_url);
+  }
+
+  // Check the compile status
+  if (!opt_skipCompileStatus) {
+    var compiled = gl.getShaderParameter(shader, gl.COMPILE_STATUS);
+    if (!compiled) {
+      // Something went wrong during compilation; get the error
+      lastError = gl.getShaderInfoLog(shader);
+      errFn("*** Error compiling " + glEnumToString(gl, shaderType) + " '" + shader + "':" + lastError);
+      gl.deleteShader(shader);
+      return null;
+    }
+  }
+
+  return shader;
+}
+
+/**
+ * Loads a shader from a URL.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {file} file The URL of the shader source.
+ * @param {number} type The type of shader.
+ * @param {function(string): void} opt_errorCallback callback for errors.
+ * @param {boolean} opt_logShaders Whether to log shader source.
+ * @param {boolean} Skip compilation status check. Default = false.
+ * @return {!WebGLShader} The created shader.
+ */
+var loadShaderFromFile = function(
+    gl, file, type, opt_errorCallback, opt_logShaders, opt_skipCompileStatus) {
+  var shaderSource = readFile(file);
+  return loadShader(gl, shaderSource, type, opt_errorCallback,
+      opt_logShaders, undefined, file, opt_skipCompileStatus);
+};
+
+var loadShaderFromFileAsync = function(
+    gl, file, type, opt_errorCallback, opt_logShaders, opt_skipCompileStatus, callback) {
+  loadTextFileAsync(file, function(gl, type, opt_errorCallback, opt_logShaders, file, opt_skipCompileStatus){
+      return function(success, shaderSource) {
+        if (success) {
+          var shader = loadShader(gl, shaderSource, type, opt_errorCallback,
+              opt_logShaders, undefined, file, opt_skipCompileStatus);
+          callback(true, shader);
+        } else {
+          callback(false, null);
+        }
+      }
+  }(gl, type, opt_errorCallback, opt_logShaders, file, opt_skipCompileStatus));
+};
+
+/**
+ * Gets the content of script.
+ * @param {string} scriptId The id of the script tag.
+ * @return {string} The content of the script.
+ */
+var getScript = function(scriptId) {
+  var shaderScript = document.getElementById(scriptId);
+  if (!shaderScript) {
+    throw("*** Error: unknown script element " + scriptId);
+  }
+  return shaderScript.text;
+};
+
+/**
+ * Loads a shader from a script tag.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} scriptId The id of the script tag.
+ * @param {number} opt_shaderType The type of shader. If not passed in it will
+ *     be derived from the type of the script tag.
+ * @param {function(string): void} opt_errorCallback callback for errors.
+ * @param {boolean} opt_logShaders Whether to log shader source.
+ * @param {boolean} Skip compilation status check. Default = false.
+ * @return {!WebGLShader} The created shader.
+ */
+var loadShaderFromScript = function(
+    gl, scriptId, opt_shaderType, opt_errorCallback, opt_logShaders, opt_skipCompileStatus) {
+  var shaderSource = "";
+  var shaderScript = document.getElementById(scriptId);
+  if (!shaderScript) {
+    throw("*** Error: unknown script element " + scriptId);
+  }
+  shaderSource = shaderScript.text.trim();
+
+  if (!opt_shaderType) {
+    if (shaderScript.type == "x-shader/x-vertex") {
+      opt_shaderType = gl.VERTEX_SHADER;
+    } else if (shaderScript.type == "x-shader/x-fragment") {
+      opt_shaderType = gl.FRAGMENT_SHADER;
+    } else {
+      throw("*** Error: unknown shader type");
+      return null;
+    }
+  }
+
+  return loadShader(gl, shaderSource, opt_shaderType, opt_errorCallback,
+      opt_logShaders, undefined, undefined, opt_skipCompileStatus);
+};
+
+var loadStandardProgram = function(gl) {
+  var program = gl.createProgram();
+  gl.attachShader(program, loadStandardVertexShader(gl));
+  gl.attachShader(program, loadStandardFragmentShader(gl));
+  gl.bindAttribLocation(program, 0, "a_vertex");
+  gl.bindAttribLocation(program, 1, "a_normal");
+  linkProgram(gl, program);
+  return program;
+};
+
+var loadStandardProgramAsync = function(gl, callback) {
+  loadStandardVertexShaderAsync(gl, function(gl) {
+    return function(success, vs) {
+      if (success) {
+        loadStandardFragmentShaderAsync(gl, function(vs) {
+          return function(success, fs) {
+            if (success) {
+              var program = gl.createProgram();
+              gl.attachShader(program, vs);
+              gl.attachShader(program, fs);
+              gl.bindAttribLocation(program, 0, "a_vertex");
+              gl.bindAttribLocation(program, 1, "a_normal");
+              linkProgram(gl, program);
+              callback(true, program);
+            } else {
+              callback(false, null);
+            }
+          };
+        }(vs));
+      } else {
+        callback(false, null);
+      }
+    };
+  }(gl));
+};
+
+/**
+ * Loads shaders from files, creates a program, attaches the shaders and links.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} vertexShaderPath The URL of the vertex shader.
+ * @param {string} fragmentShaderPath The URL of the fragment shader.
+ * @param {function(string): void} opt_errorCallback callback for errors.
+ * @return {!WebGLProgram} The created program.
+ */
+var loadProgramFromFile = function(
+    gl, vertexShaderPath, fragmentShaderPath, opt_errorCallback) {
+  var program = gl.createProgram();
+  var vs = loadShaderFromFile(
+      gl, vertexShaderPath, gl.VERTEX_SHADER, opt_errorCallback);
+  var fs = loadShaderFromFile(
+      gl, fragmentShaderPath, gl.FRAGMENT_SHADER, opt_errorCallback);
+  if (vs && fs) {
+    gl.attachShader(program, vs);
+    gl.attachShader(program, fs);
+    linkProgram(gl, program, opt_errorCallback);
+  }
+  if (vs) {
+    gl.deleteShader(vs);
+  }
+  if (fs) {
+    gl.deleteShader(fs);
+  }
+  return program;
+};
+
+/**
+ * Loads shaders from script tags, creates a program, attaches the shaders and
+ * links.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} vertexScriptId The id of the script tag that contains the
+ *        vertex shader.
+ * @param {string} fragmentScriptId The id of the script tag that contains the
+ *        fragment shader.
+ * @param {function(string): void} opt_errorCallback callback for errors.
+ * @return {!WebGLProgram} The created program.
+ */
+var loadProgramFromScript = function loadProgramFromScript(
+    gl, vertexScriptId, fragmentScriptId, opt_errorCallback) {
+  var program = gl.createProgram();
+  gl.attachShader(
+      program,
+      loadShaderFromScript(
+          gl, vertexScriptId, gl.VERTEX_SHADER, opt_errorCallback));
+  gl.attachShader(
+      program,
+      loadShaderFromScript(
+          gl, fragmentScriptId,  gl.FRAGMENT_SHADER, opt_errorCallback));
+  linkProgram(gl, program, opt_errorCallback);
+  return program;
+};
+
+/**
+ * Loads shaders from source, creates a program, attaches the shaders and
+ * links.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!WebGLShader} vertexShader The vertex shader.
+ * @param {!WebGLShader} fragmentShader The fragment shader.
+ * @param {function(string): void} opt_errorCallback callback for errors.
+ * @return {!WebGLProgram} The created program.
+ */
+var createProgram = function(gl, vertexShader, fragmentShader, opt_errorCallback) {
+  var program = gl.createProgram();
+  gl.attachShader(program, vertexShader);
+  gl.attachShader(program, fragmentShader);
+  linkProgram(gl, program, opt_errorCallback);
+  return program;
+};
+
+/**
+ * Loads shaders from source, creates a program, attaches the shaders and
+ * links.
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} vertexShader The vertex shader source.
+ * @param {string} fragmentShader The fragment shader source.
+ * @param {function(string): void} opt_errorCallback callback for errors.
+ * @param {boolean} opt_logShaders Whether to log shader source.
+ * @return {!WebGLProgram} The created program.
+ */
+var loadProgram = function(
+    gl, vertexShader, fragmentShader, opt_errorCallback, opt_logShaders) {
+  var program;
+  var vs = loadShader(
+      gl, vertexShader, gl.VERTEX_SHADER, opt_errorCallback, opt_logShaders);
+  var fs = loadShader(
+      gl, fragmentShader, gl.FRAGMENT_SHADER, opt_errorCallback, opt_logShaders);
+  if (vs && fs) {
+    program = createProgram(gl, vs, fs, opt_errorCallback)
+  }
+  if (vs) {
+    gl.deleteShader(vs);
+  }
+  if (fs) {
+    gl.deleteShader(fs);
+  }
+  return program;
+};
+
+/**
+ * Loads shaders from source, creates a program, attaches the shaders and
+ * links but expects error.
+ *
+ * GLSL 1.0.17 10.27 effectively says that compileShader can
+ * always succeed as long as linkProgram fails so we can't
+ * rely on compileShader failing. This function expects
+ * one of the shader to fail OR linking to fail.
+ *
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} vertexShaderScriptId The vertex shader.
+ * @param {string} fragmentShaderScriptId The fragment shader.
+ * @return {WebGLProgram} The created program.
+ */
+var loadProgramFromScriptExpectError = function(
+    gl, vertexShaderScriptId, fragmentShaderScriptId) {
+  var vertexShader = loadShaderFromScript(gl, vertexShaderScriptId);
+  if (!vertexShader) {
+    return null;
+  }
+  var fragmentShader = loadShaderFromScript(gl, fragmentShaderScriptId);
+  if (!fragmentShader) {
+    return null;
+  }
+  var linkSuccess = true;
+  var program = gl.createProgram();
+  gl.attachShader(program, vertexShader);
+  gl.attachShader(program, fragmentShader);
+  linkSuccess = true;
+  linkProgram(gl, program, function() {
+      linkSuccess = false;
+    });
+  return linkSuccess ? program : null;
+};
+
+
+var getActiveMap = function(gl, program, typeInfo) {
+  var numVariables = gl.getProgramParameter(program, gl[typeInfo.param]);
+  var variables = {};
+  for (var ii = 0; ii < numVariables; ++ii) {
+    var info = gl[typeInfo.activeFn](program, ii);
+    variables[info.name] = {
+      name: info.name,
+      size: info.size,
+      type: info.type,
+      location: gl[typeInfo.locFn](program, info.name)
+    };
+  }
+  return variables;
+};
+
+/**
+ * Returns a map of attrib names to info about those
+ * attribs.
+ *
+ * eg:
+ *    { "attrib1Name":
+ *      {
+ *        name: "attrib1Name",
+ *        size: 1,
+ *        type: gl.FLOAT_MAT2,
+ *        location: 0
+ *      },
+ *      "attrib2Name[0]":
+ *      {
+ *         name: "attrib2Name[0]",
+ *         size: 4,
+ *         type: gl.FLOAT,
+ *         location: 1
+ *      },
+ *    }
+ *
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {WebGLProgram} The program to query for attribs.
+ * @return the map.
+ */
+var getAttribMap = function(gl, program) {
+  return getActiveMap(gl, program, {
+      param: "ACTIVE_ATTRIBUTES",
+      activeFn: "getActiveAttrib",
+      locFn: "getAttribLocation"
+  });
+};
+
+/**
+ * Returns a map of uniform names to info about those uniforms.
+ *
+ * eg:
+ *    { "uniform1Name":
+ *      {
+ *        name: "uniform1Name",
+ *        size: 1,
+ *        type: gl.FLOAT_MAT2,
+ *        location: WebGLUniformLocation
+ *      },
+ *      "uniform2Name[0]":
+ *      {
+ *         name: "uniform2Name[0]",
+ *         size: 4,
+ *         type: gl.FLOAT,
+ *         location: WebGLUniformLocation
+ *      },
+ *    }
+ *
+ * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {WebGLProgram} The program to query for uniforms.
+ * @return the map.
+ */
+var getUniformMap = function(gl, program) {
+  return getActiveMap(gl, program, {
+      param: "ACTIVE_UNIFORMS",
+      activeFn: "getActiveUniform",
+      locFn: "getUniformLocation"
+  });
+};
+
+var basePath;
+var getResourcePath = function() {
+  if (!basePath) {
+    var expectedBase = "js/webgl-test-utils.js";
+    var scripts = document.getElementsByTagName('script');
+    for (var script, i = 0; script = scripts[i]; i++) {
+      var src = script.src;
+      var l = src.length;
+      if (src.substr(l - expectedBase.length) == expectedBase) {
+        basePath = src.substr(0, l - expectedBase.length);
+      }
+    }
+  }
+  return basePath + "resources/";
+};
+
+var loadStandardVertexShader = function(gl) {
+  return loadShaderFromFile(
+      gl, getResourcePath() + "vertexShader.vert", gl.VERTEX_SHADER);
+};
+var loadStandardVertexShaderAsync = function(gl, callback) {
+  loadShaderFromFileAsync(gl, getResourcePath() + "vertexShader.vert", gl.VERTEX_SHADER, undefined, undefined, undefined, callback);
+};
+
+var loadStandardFragmentShader = function(gl) {
+  return loadShaderFromFile(
+      gl, getResourcePath() + "fragmentShader.frag", gl.FRAGMENT_SHADER);
+};
+var loadStandardFragmentShaderAsync = function(gl, callback) {
+  loadShaderFromFileAsync(gl, getResourcePath() + "fragmentShader.frag", gl.FRAGMENT_SHADER, undefined, undefined, undefined, callback);
+};
+
+var loadUniformBlockProgram = function(gl) {
+  var program = gl.createProgram();
+  gl.attachShader(program, loadUniformBlockVertexShader(gl));
+  gl.attachShader(program, loadUniformBlockFragmentShader(gl));
+  gl.bindAttribLocation(program, 0, "a_vertex");
+  gl.bindAttribLocation(program, 1, "a_normal");
+  linkProgram(gl, program);
+  return program;
+};
+
+var loadUniformBlockVertexShader = function(gl) {
+  return loadShaderFromFile(
+      gl, getResourcePath() + "uniformBlockShader.vert", gl.VERTEX_SHADER);
+};
+
+var loadUniformBlockFragmentShader = function(gl) {
+  return loadShaderFromFile(
+      gl, getResourcePath() + "uniformBlockShader.frag", gl.FRAGMENT_SHADER);
+};
+
+/**
+ * Loads an image asynchronously.
+ * @param {string} url URL of image to load.
+ * @param {!function(!Element): void} callback Function to call
+ *     with loaded image.
+ */
+var loadImageAsync = function(url, callback) {
+  var img = document.createElement('img');
+  img.onload = function() {
+    callback(img);
+  };
+  img.src = url;
+};
+
+/**
+ * Loads an array of images.
+ * @param {!Array.<string>} urls URLs of images to load.
+ * @param {!function(!{string, img}): void} callback Callback
+ *     that gets passed map of urls to img tags.
+ */
+var loadImagesAsync = function(urls, callback) {
+  var count = 1;
+  var images = { };
+  function countDown() {
+    --count;
+    if (count == 0) {
+      log("loadImagesAsync: all images loaded");
+      callback(images);
+    }
+  }
+  function imageLoaded(url) {
+    return function(img) {
+      images[url] = img;
+      log("loadImagesAsync: loaded " + url);
+      countDown();
+    }
+  }
+  for (var ii = 0; ii < urls.length; ++ii) {
+    ++count;
+    loadImageAsync(urls[ii], imageLoaded(urls[ii]));
+  }
+  countDown();
+};
+
+/**
+ * Returns a map of key=value values from url.
+ * @return {!Object.<string, number>} map of keys to values.
+ */
+var getUrlArguments = function() {
+  var args = {};
+  try {
+    var s = window.location.href;
+    var q = s.indexOf("?");
+    var e = s.indexOf("#");
+    if (e < 0) {
+      e = s.length;
+    }
+    var query = s.substring(q + 1, e);
+    var pairs = query.split("&");
+    for (var ii = 0; ii < pairs.length; ++ii) {
+      var keyValue = pairs[ii].split("=");
+      var key = keyValue[0];
+      var value = decodeURIComponent(keyValue[1]);
+      args[key] = value;
+    }
+  } catch (e) {
+    throw "could not parse url";
+  }
+  return args;
+};
+
+/**
+ * Makes an image from a src.
+ * @param {string} src Image source URL.
+ * @param {function()} onload Callback to call when the image has finised loading.
+ * @param {function()} onerror Callback to call when an error occurs.
+ * @return {!Image} The created image.
+ */
+var makeImage = function(src, onload, onerror) {
+  var img = document.createElement('img');
+  if (onload) {
+    img.onload = onload;
+  }
+  if (onerror) {
+    img.onerror = onerror;
+  } else {
+    img.onerror = function() {
+      log("WARNING: creating image failed; src: " + this.src);
+    };
+  }
+  if (src) {
+    img.src = src;
+  }
+  return img;
+}
+
+/**
+ * Makes an image element from a canvas.
+ * @param {!HTMLCanvas} canvas Canvas to make image from.
+ * @param {function()} onload Callback to call when the image has finised loading.
+ * @param {string} imageFormat Image format to be passed to toDataUrl().
+ * @return {!Image} The created image.
+ */
+var makeImageFromCanvas = function(canvas, onload, imageFormat) {
+  return makeImage(canvas.toDataURL(imageFormat), onload);
+};
+
+/**
+ * Makes a video element from a src.
+ * @param {string} src Video source URL.
+ * @param {function()} onerror Callback to call when an error occurs.
+ * @return {!Video} The created video.
+ */
+var makeVideo = function(src, onerror) {
+  var vid = document.createElement('video');
+  vid.muted = true;
+  if (onerror) {
+    vid.onerror = onerror;
+  } else {
+    vid.onerror = function() {
+      log("WARNING: creating video failed; src: " + this.src);
+    };
+  }
+  if (src) {
+    vid.src = src;
+  }
+  return vid;
+}
+
+/**
+ * Inserts an image with a caption into 'element'.
+ * @param {!HTMLElement} element Element to append image to.
+ * @param {string} caption caption to associate with image.
+ * @param {!Image} img image to insert.
+ */
+var insertImage = function(element, caption, img) {
+  var div = document.createElement("div");
+  var label = document.createElement("div");
+  label.appendChild(document.createTextNode(caption));
+  div.appendChild(label);
+  div.appendChild(img);
+  element.appendChild(div);
+};
+
+/**
+ * Inserts a 'label' that when clicked expands to the pre formatted text
+ * supplied by 'source'.
+ * @param {!HTMLElement} element element to append label to.
+ * @param {string} label label for anchor.
+ * @param {string} source preformatted text to expand to.
+ * @param {string} opt_url URL of source. If provided a link to the source file
+ *     will also be added.
+ */
+var addShaderSource = function(element, label, source, opt_url) {
+  var div = document.createElement("div");
+  var s = document.createElement("pre");
+  s.className = "shader-source";
+  s.style.display = "none";
+  var ol = document.createElement("ol");
+  //s.appendChild(document.createTextNode(source));
+  var lines = source.split("\n");
+  for (var ii = 0; ii < lines.length; ++ii) {
+    var line = lines[ii];
+    var li = document.createElement("li");
+    li.appendChild(document.createTextNode(line));
+    ol.appendChild(li);
+  }
+  s.appendChild(ol);
+  var l = document.createElement("a");
+  l.href = "show-shader-source";
+  l.appendChild(document.createTextNode(label));
+  l.addEventListener('click', function(event) {
+      if (event.preventDefault) {
+        event.preventDefault();
+      }
+      s.style.display = (s.style.display == 'none') ? 'block' : 'none';
+      return false;
+    }, false);
+  div.appendChild(l);
+  if (opt_url) {
+    var u = document.createElement("a");
+    u.href = opt_url;
+    div.appendChild(document.createTextNode(" "));
+    u.appendChild(document.createTextNode("(" + opt_url + ")"));
+    div.appendChild(u);
+  }
+  div.appendChild(s);
+  element.appendChild(div);
+};
+
+/**
+ * Inserts labels that when clicked expand to show the original source of the
+ * shader and also translated source of the shader, if that is available.
+ * @param {WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {!HTMLElement} element element to append label to.
+ * @param {string} label label for anchor.
+ * @param {WebGLShader} shader Shader to show the sources for.
+ * @param {string} shaderSource Original shader source.
+ * @param {string} opt_url URL of source. If provided a link to the source file
+ *     will also be added.
+ */
+var addShaderSources = function(
+    gl, element, label, shader, shaderSource, opt_url) {
+  addShaderSource(element, label, shaderSource, opt_url);
+
+  var debugShaders = gl.getExtension('WEBGL_debug_shaders');
+  if (debugShaders && shader) {
+    var translatedSource = debugShaders.getTranslatedShaderSource(shader);
+    if (translatedSource != '') {
+      addShaderSource(element, label + ' translated for driver', translatedSource);
+    }
+  }
+};
+
+/**
+ * Sends shader information to the server to be dumped into text files
+ * when tests are run from within the test-runner harness.
+ * @param {WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} url URL of current.
+ * @param {string} passMsg Test description.
+ * @param {object} vInfo Object containing vertex shader information.
+ * @param {object} fInfo Object containing fragment shader information.
+ */
+var dumpShadersInfo = function(gl, url, passMsg, vInfo, fInfo) {
+  var shaderInfo = {};
+  shaderInfo.url = url;
+  shaderInfo.testDescription = passMsg;
+  shaderInfo.vLabel = vInfo.label;
+  shaderInfo.vShouldCompile = vInfo.shaderSuccess;
+  shaderInfo.vSource = vInfo.source;
+  shaderInfo.fLabel = fInfo.label;
+  shaderInfo.fShouldCompile = fInfo.shaderSuccess;
+  shaderInfo.fSource = fInfo.source;
+  shaderInfo.vTranslatedSource = null;
+  shaderInfo.fTranslatedSource = null;
+  var debugShaders = gl.getExtension('WEBGL_debug_shaders');
+  if (debugShaders) {
+    if (vInfo.shader)
+      shaderInfo.vTranslatedSource = debugShaders.getTranslatedShaderSource(vInfo.shader);
+    if (fInfo.shader)
+      shaderInfo.fTranslatedSource = debugShaders.getTranslatedShaderSource(fInfo.shader);
+  }
+
+  var dumpShaderInfoRequest = new XMLHttpRequest();
+  dumpShaderInfoRequest.open('POST', "/dumpShaderInfo", true);
+  dumpShaderInfoRequest.setRequestHeader("Content-Type", "text/plain");
+  dumpShaderInfoRequest.send(JSON.stringify(shaderInfo));
+};
+
+// Add your prefix here.
+var browserPrefixes = [
+  "",
+  "MOZ_",
+  "OP_",
+  "WEBKIT_"
+];
+
+/**
+ * Given an extension name like WEBGL_compressed_texture_s3tc
+ * returns the name of the supported version extension, like
+ * WEBKIT_WEBGL_compressed_teture_s3tc
+ * @param {string} name Name of extension to look for.
+ * @return {string} name of extension found or undefined if not
+ *     found.
+ */
+var getSupportedExtensionWithKnownPrefixes = function(gl, name) {
+  var supported = gl.getSupportedExtensions();
+  for (var ii = 0; ii < browserPrefixes.length; ++ii) {
+    var prefixedName = browserPrefixes[ii] + name;
+    if (supported.indexOf(prefixedName) >= 0) {
+      return prefixedName;
+    }
+  }
+};
+
+/**
+ * @param {WebGLRenderingContext} gl The WebGLRenderingContext to use.
+ * @param {string} name Name of extension to look for.
+ * @param {boolean} extensionEnabled True if the extension was enabled successfully via gl.getExtension().
+ */
+var runExtensionSupportedTest = function(gl, name, extensionEnabled) {
+  var prefixedName = getSupportedExtensionWithKnownPrefixes(gl, name);
+  if (prefixedName !== undefined) {
+      if (extensionEnabled) {
+          testPassed(name + " listed as supported and getExtension succeeded");
+      } else {
+          testFailed(name + " listed as supported but getExtension failed");
+      }
+  } else {
+      if (extensionEnabled) {
+          testFailed(name + " not listed as supported but getExtension succeeded");
+      } else {
+          testPassed(name + " not listed as supported and getExtension failed -- this is legal");
+      }
+  }
+}
+
+/**
+ * Given an extension name like WEBGL_compressed_texture_s3tc
+ * returns the supported version extension, like
+ * WEBKIT_WEBGL_compressed_teture_s3tc
+ * @param {string} name Name of extension to look for.
+ * @return {WebGLExtension} The extension or undefined if not
+ *     found.
+ */
+var getExtensionWithKnownPrefixes = function(gl, name) {
+  for (var ii = 0; ii < browserPrefixes.length; ++ii) {
+    var prefixedName = browserPrefixes[ii] + name;
+    var ext = gl.getExtension(prefixedName);
+    if (ext) {
+      return ext;
+    }
+  }
+};
+
+/**
+ * Returns possible prefixed versions of an extension's name.
+ * @param {string} name Name of extension. May already include a prefix.
+ * @return {Array.<string>} Variations of the extension name with known
+ *     browser prefixes.
+ */
+var getExtensionPrefixedNames = function(name) {
+  var unprefix = function(name) {
+    for (var ii = 0; ii < browserPrefixes.length; ++ii) {
+      if (browserPrefixes[ii].length > 0 &&
+          name.substring(0, browserPrefixes[ii].length).toLowerCase() ===
+          browserPrefixes[ii].toLowerCase()) {
+        return name.substring(browserPrefixes[ii].length);
+      }
+    }
+    return name;
+  }
+
+  var unprefixed = unprefix(name);
+
+  var variations = [];
+  for (var ii = 0; ii < browserPrefixes.length; ++ii) {
+    variations.push(browserPrefixes[ii] + unprefixed);
+  }
+
+  return variations;
+};
+
+var replaceRE = /\$\((\w+)\)/g;
+
+/**
+ * Replaces strings with property values.
+ * Given a string like "hello $(first) $(last)" and an object
+ * like {first:"John", last:"Smith"} will return
+ * "hello John Smith".
+ * @param {string} str String to do replacements in.
+ * @param {...} 1 or more objects containing properties.
+ */
+var replaceParams = function(str) {
+  var args = arguments;
+  return str.replace(replaceRE, function(str, p1, offset, s) {
+    for (var ii = 1; ii < args.length; ++ii) {
+      if (args[ii][p1] !== undefined) {
+        return args[ii][p1];
+      }
+    }
+    throw "unknown string param '" + p1 + "'";
+  });
+};
+
+var upperCaseFirstLetter = function(str) {
+  return str.substring(0, 1).toUpperCase() + str.substring(1);
+};
+
+/**
+ * Gets a prefixed property. For example,
+ *
+ *     var fn = getPrefixedProperty(
+ *        window,
+ *        "requestAnimationFrame");
+ *
+ * Will return either:
+ *    "window.requestAnimationFrame",
+ *    "window.oRequestAnimationFrame",
+ *    "window.msRequestAnimationFrame",
+ *    "window.mozRequestAnimationFrame",
+ *    "window.webKitRequestAnimationFrame",
+ *    undefined
+ *
+ * the non-prefixed function is tried first.
+ */
+var propertyPrefixes = ["", "moz", "ms", "o", "webkit"];
+var getPrefixedProperty = function(obj, propertyName) {
+  for (var ii = 0; ii < propertyPrefixes.length; ++ii) {
+    var prefix = propertyPrefixes[ii];
+    var name = prefix + propertyName;
+    log(name);
+    var property = obj[name];
+    if (property) {
+      return property;
+    }
+    if (ii == 0) {
+      propertyName = upperCaseFirstLetter(propertyName);
+    }
+  }
+  return undefined;
+};
+
+var _requestAnimFrame;
+
+/**
+ * Provides requestAnimationFrame in a cross browser way.
+ */
+var requestAnimFrame = function(callback) {
+  if (!_requestAnimFrame) {
+    _requestAnimFrame = getPrefixedProperty(window, "requestAnimationFrame") ||
+      function(callback, element) {
+        return window.setTimeout(callback, 1000 / 70);
+      };
+  }
+  _requestAnimFrame.call(window, callback);
+};
+
+var _cancelAnimFrame;
+
+/**
+ * Provides cancelAnimationFrame in a cross browser way.
+ */
+var cancelAnimFrame = function(request) {
+  if (!_cancelAnimFrame) {
+    _cancelAnimFrame = getPrefixedProperty(window, "cancelAnimationFrame") ||
+      window.clearTimeout;
+  }
+  _cancelAnimFrame.call(window, request);
+};
+
+/**
+ * Provides requestFullScreen in a cross browser way.
+ */
+var requestFullScreen = function(element) {
+  var fn = getPrefixedProperty(element, "requestFullScreen");
+  if (fn) {
+    fn.call(element);
+  }
+};
+
+/**
+ * Provides cancelFullScreen in a cross browser way.
+ */
+var cancelFullScreen = function() {
+  var fn = getPrefixedProperty(document, "cancelFullScreen");
+  if (fn) {
+    fn.call(document);
+  }
+};
+
+var fullScreenStateName;
+(function() {
+  var fullScreenStateNames = [
+    "isFullScreen",
+    "fullScreen"
+  ];
+  for (var ii = 0; ii < fullScreenStateNames.length; ++ii) {
+    var propertyName = fullScreenStateNames[ii];
+    for (var jj = 0; jj < propertyPrefixes.length; ++jj) {
+      var prefix = propertyPrefixes[jj];
+      if (prefix.length) {
+        propertyName = upperCaseFirstLetter(propertyName);
+        fullScreenStateName = prefix + propertyName;
+        if (document[fullScreenStateName] !== undefined) {
+          return;
+        }
+      }
+    }
+    fullScreenStateName = undefined;
+  }
+}());
+
+/**
+ * @return {boolean} True if fullscreen mode is active.
+ */
+var getFullScreenState = function() {
+  log("fullscreenstatename:" + fullScreenStateName);
+  log(document[fullScreenStateName]);
+  return document[fullScreenStateName];
+};
+
+/**
+ * @param {!HTMLElement} element The element to go fullscreen.
+ * @param {!function(boolean)} callback A function that will be called
+ *        when entering/exiting fullscreen. It is passed true if
+ *        entering fullscreen, false if exiting.
+ */
+var onFullScreenChange = function(element, callback) {
+  propertyPrefixes.forEach(function(prefix) {
+    var eventName = prefix + "fullscreenchange";
+    log("addevent: " + eventName);
+    document.addEventListener(eventName, function(event) {
+      log("event: " + eventName);
+      callback(getFullScreenState());
+    });
+  });
+};
+
+/**
+ * @param {!string} buttonId The id of the button that will toggle fullscreen
+ *        mode.
+ * @param {!string} fullscreenId The id of the element to go fullscreen.
+ * @param {!function(boolean)} callback A function that will be called
+ *        when entering/exiting fullscreen. It is passed true if
+ *        entering fullscreen, false if exiting.
+ * @return {boolean} True if fullscreen mode is supported.
+ */
+var setupFullscreen = function(buttonId, fullscreenId, callback) {
+  if (!fullScreenStateName) {
+    return false;
+  }
+
+  var fullscreenElement = document.getElementById(fullscreenId);
+  onFullScreenChange(fullscreenElement, callback);
+
+  var toggleFullScreen = function(event) {
+    if (getFullScreenState()) {
+      cancelFullScreen(fullscreenElement);
+    } else {
+      requestFullScreen(fullscreenElement);
+    }
+    event.preventDefault();
+    return false;
+  };
+
+  var buttonElement = document.getElementById(buttonId);
+  buttonElement.addEventListener('click', toggleFullScreen);
+
+  return true;
+};
+
+/**
+ * Waits for the browser to composite the web page.
+ * @param {function()} callback A function to call after compositing has taken
+ *        place.
+ */
+var waitForComposite = function(callback) {
+  var frames = 5;
+  var countDown = function() {
+    if (frames == 0) {
+      // TODO(kbr): unify with js-test-pre.js and enable these with
+      // verbose logging.
+      // log("waitForComposite: callback");
+      callback();
+    } else {
+      // log("waitForComposite: countdown(" + frames + ")");
+      --frames;
+      requestAnimFrame.call(window, countDown);
+    }
+  };
+  countDown();
+};
+
+var setZeroTimeout = (function() {
+  // See https://dbaron.org/log/20100309-faster-timeouts
+
+  var timeouts = [];
+  var messageName = "zero-timeout-message";
+
+  // Like setTimeout, but only takes a function argument.  There's
+  // no time argument (always zero) and no arguments (you have to
+  // use a closure).
+  function setZeroTimeout(fn) {
+      timeouts.push(fn);
+      window.postMessage(messageName, "*");
+  }
+
+  function handleMessage(event) {
+      if (event.source == window && event.data == messageName) {
+          event.stopPropagation();
+          if (timeouts.length > 0) {
+              var fn = timeouts.shift();
+              fn();
+          }
+      }
+  }
+
+  window.addEventListener("message", handleMessage, true);
+
+  return setZeroTimeout;
+})();
+
+function dispatchPromise(fn) {
+  return new Promise((fn_resolve, fn_reject) => {
+    setZeroTimeout(() => {
+      let val;
+      if (fn) {
+        val = fn();
+      }
+      fn_resolve(val);
+    });
+  });
+}
+
+/**
+ * Runs an array of functions, yielding to the browser between each step.
+ * If you want to know when all the steps are finished add a last step.
+ * @param {!Array.<function(): void>} steps Array of functions.
+ */
+var runSteps = function(steps) {
+  if (!steps.length) {
+    return;
+  }
+
+  // copy steps so they can't be modifed.
+  var stepsToRun = steps.slice();
+  var currentStep = 0;
+  var runNextStep = function() {
+    stepsToRun[currentStep++]();
+    if (currentStep < stepsToRun.length) {
+      setTimeout(runNextStep, 1);
+    }
+  };
+  runNextStep();
+};
+
+/**
+ * Starts playing a video and waits for it to be consumable.
+ * @param {!HTMLVideoElement} video An HTML5 Video element.
+ * @param {!function(!HTMLVideoElement): void} callback Function to call when
+ *        video is ready.
+ */
+async function startPlayingAndWaitForVideo(video, callback) {
+  if (video.error) {
+    testFailed('Video failed to load: ' + video.error);
+    return;
+  }
+
+  video.loop = true;
+  video.muted = true;
+  // See whether setting the preload flag de-flakes video-related tests.
+  video.preload = 'auto';
+
+  try {
+    await video.play();
+  } catch (e) {
+    testFailed('video.play failed: ' + e);
+    return;
+  }
+
+  if (video.requestVideoFrameCallback) {
+    await new Promise(go => video.requestVideoFrameCallback(go));
+  }
+
+  callback(video);
+}
+
+var getHost = function(url) {
+  url = url.replace("\\", "/");
+  var pos = url.indexOf("://");
+  if (pos >= 0) {
+    url = url.substr(pos + 3);
+  }
+  var parts = url.split('/');
+  return parts[0];
+}
+
+// This function returns the last 2 words of the domain of a URL
+// This is probably not the correct check but it will do for now.
+var getBaseDomain = function(host) {
+  var parts = host.split(":");
+  var hostname = parts[0];
+  var port = parts[1] || "80";
+  parts = hostname.split(".");
+  if(parts.length < 2)
+    return hostname + ":" + port;
+  var tld = parts[parts.length-1];
+  var domain = parts[parts.length-2];
+  return domain + "." + tld + ":" + port;
+}
+
+var runningOnLocalhost = function() {
+  let hostname = window.location.hostname;
+  return hostname == "localhost" ||
+    hostname == "127.0.0.1" ||
+    hostname == "::1";
+}
+
+var getLocalCrossOrigin = function() {
+  var domain;
+  if (window.location.host.indexOf("localhost") != -1) {
+    // TODO(kbr): figure out whether to use an IPv6 loopback address.
+    domain = "127.0.0.1";
+  } else {
+    domain = "localhost";
+  }
+
+  var port = window.location.port || "80";
+  return window.location.protocol + "//" + domain + ":" + port
+}
+
+var getRelativePath = function(path) {
+  var relparts = window.location.pathname.split("/");
+  relparts.pop(); // Pop off filename
+  var pathparts = path.split("/");
+
+  var i;
+  for (i = 0; i < pathparts.length; ++i) {
+    switch (pathparts[i]) {
+      case "": break;
+      case ".": break;
+      case "..":
+        relparts.pop();
+        break;
+      default:
+        relparts.push(pathparts[i]);
+        break;
+    }
+  }
+
+  return relparts.join("/");
+}
+
+async function loadCrossOriginImage(img, webUrl, localUrl) {
+  if (runningOnLocalhost()) {
+    img.src = getLocalCrossOrigin() + getRelativePath(localUrl);
+    console.log('[loadCrossOriginImage]', '  trying', img.src);
+    await img.decode();
+    return;
+  }
+
+  try {
+    img.src = getUrlOptions().imgUrl || webUrl;
+    console.log('[loadCrossOriginImage]', 'trying', img.src);
+    await img.decode();
+    return;
+  } catch {}
+
+  throw 'createCrossOriginImage failed';
+}
+
+/**
+ * Convert sRGB color to linear color.
+ * @param {!Array.<number>} color The color to be converted.
+ *        The array has 4 elements, for example [R, G, B, A].
+ *        where each element is in the range 0 to 255.
+ * @return {!Array.<number>} color The color to be converted.
+ *        The array has 4 elements, for example [R, G, B, A].
+ *        where each element is in the range 0 to 255.
+ */
+var sRGBToLinear = function(color) {
+    return [sRGBChannelToLinear(color[0]),
+            sRGBChannelToLinear(color[1]),
+            sRGBChannelToLinear(color[2]),
+            color[3]]
+}
+
+/**
+ * Convert linear color to sRGB color.
+ * @param {!Array.<number>} color The color to be converted.
+ *        The array has 4 elements, for example [R, G, B, A].
+ *        where each element is in the range 0 to 255.
+ * @return {!Array.<number>} color The color to be converted.
+ *        The array has 4 elements, for example [R, G, B, A].
+ *        where each element is in the range 0 to 255.
+ */
+var linearToSRGB = function(color) {
+    return [linearChannelToSRGB(color[0]),
+            linearChannelToSRGB(color[1]),
+            linearChannelToSRGB(color[2]),
+            color[3]]
+}
+
+function sRGBChannelToLinear(value) {
+    value = value / 255;
+    if (value <= 0.04045)
+        value = value / 12.92;
+    else
+        value = Math.pow((value + 0.055) / 1.055, 2.4);
+    return Math.trunc(value * 255 + 0.5);
+}
+
+function linearChannelToSRGB(value) {
+    value = value / 255;
+    if (value <= 0.0) {
+        value = 0.0;
+    } else if (value < 0.0031308) {
+        value = value * 12.92;
+    } else if (value < 1) {
+        value = Math.pow(value, 0.41666) * 1.055 - 0.055;
+    } else {
+        value = 1.0;
+    }
+    return Math.trunc(value * 255 + 0.5);
+}
+
+function comparePixels(cmp, ref, tolerance, diff) {
+    if (cmp.length != ref.length) {
+        testFailed("invalid pixel size.");
+    }
+
+    var count = 0;
+    for (var i = 0; i < cmp.length; i++) {
+        if (diff) {
+            diff[i * 4] = 0;
+            diff[i * 4 + 1] = 255;
+            diff[i * 4 + 2] = 0;
+            diff[i * 4 + 3] = 255;
+        }
+        if (Math.abs(cmp[i * 4] - ref[i * 4]) > tolerance ||
+            Math.abs(cmp[i * 4 + 1] - ref[i * 4 + 1]) > tolerance ||
+            Math.abs(cmp[i * 4 + 2] - ref[i * 4 + 2]) > tolerance ||
+            Math.abs(cmp[i * 4 + 3] - ref[i * 4 + 3]) > tolerance) {
+            if (count < 10) {
+                testFailed("Pixel " + i + ": expected (" +
+                [ref[i * 4], ref[i * 4 + 1], ref[i * 4 + 2], ref[i * 4 + 3]] + "), got (" +
+                [cmp[i * 4], cmp[i * 4 + 1], cmp[i * 4 + 2], cmp[i * 4 + 3]] + ")");
+            }
+            count++;
+            if (diff) {
+                diff[i * 4] = 255;
+                diff[i * 4 + 1] = 0;
+            }
+        }
+    }
+
+    return count;
+}
+
+function destroyContext(gl) {
+  const ext = gl.getExtension('WEBGL_lose_context');
+  if (ext) {
+    ext.loseContext();
+  }
+  gl.canvas.width = 1;
+  gl.canvas.height = 1;
+}
+
+function destroyAllContexts() {
+  if (!window._wtu_contexts)
+    return;
+  for (const x of window._wtu_contexts) {
+    destroyContext(x);
+  }
+  window._wtu_contexts = [];
+}
+
+function displayImageDiff(cmp, ref, diff, width, height) {
+    var div = document.createElement("div");
+
+    var cmpImg = createImageFromPixel(cmp, width, height);
+    var refImg = createImageFromPixel(ref, width, height);
+    var diffImg = createImageFromPixel(diff, width, height);
+    wtu.insertImage(div, "Reference", refImg);
+    wtu.insertImage(div, "Result", cmpImg);
+    wtu.insertImage(div, "Difference", diffImg);
+
+    var console = document.getElementById("console");
+    console.appendChild(div);
+}
+
+function createImageFromPixel(buf, width, height) {
+    var canvas = document.createElement("canvas");
+    canvas.width = width;
+    canvas.height = height;
+    var ctx = canvas.getContext("2d");
+    var imgData = ctx.getImageData(0, 0, width, height);
+
+    for (var i = 0; i < buf.length; i++)
+        imgData.data[i] = buf[i];
+    ctx.putImageData(imgData, 0, 0);
+    var img = wtu.makeImageFromCanvas(canvas);
+    return img;
+}
+
+async function awaitTimeout(ms) {
+  await new Promise(res => {
+    setTimeout(() => {
+      res();
+    }, ms);
+  });
+}
+
+async function awaitOrTimeout(promise, opt_timeout_ms) {
+  async function throwOnTimeout(ms) {
+    await awaitTimeout(ms);
+    throw 'timeout';
+  }
+
+  let timeout_ms = opt_timeout_ms;
+  if (timeout_ms === undefined)
+    timeout_ms = 5000;
+
+  await Promise.race([promise, throwOnTimeout(timeout_ms)]);
+}
+
+var API = {
+  addShaderSource: addShaderSource,
+  addShaderSources: addShaderSources,
+  cancelAnimFrame: cancelAnimFrame,
+  create3DContext: create3DContext,
+  GLErrorException: GLErrorException,
+  create3DContextWithWrapperThatThrowsOnGLError: create3DContextWithWrapperThatThrowsOnGLError,
+  checkAreaInAndOut: checkAreaInAndOut,
+  checkCanvas: checkCanvas,
+  checkCanvasRect: checkCanvasRect,
+  checkCanvasRectColor: checkCanvasRectColor,
+  checkCanvasRects: checkCanvasRects,
+  checkFloatBuffer: checkFloatBuffer,
+  checkTextureSize: checkTextureSize,
+  clipToRange: clipToRange,
+  createColoredTexture: createColoredTexture,
+  createProgram: createProgram,
+  clearAndDrawUnitQuad: clearAndDrawUnitQuad,
+  clearAndDrawIndexedQuad: clearAndDrawIndexedQuad,
+  comparePixels: comparePixels,
+  destroyAllContexts: destroyAllContexts,
+  destroyContext: destroyContext,
+  dispatchPromise: dispatchPromise,
+  displayImageDiff: displayImageDiff,
+  drawUnitQuad: drawUnitQuad,
+  drawIndexedQuad: drawIndexedQuad,
+  drawUByteColorQuad: drawUByteColorQuad,
+  drawFloatColorQuad: drawFloatColorQuad,
+  dummySetProgramAndDrawNothing: dummySetProgramAndDrawNothing,
+  dumpShadersInfo: dumpShadersInfo,
+  endsWith: endsWith,
+  failIfGLError: failIfGLError,
+  fillTexture: fillTexture,
+  framebufferStatusShouldBe: framebufferStatusShouldBe,
+  getBytesPerComponent: getBytesPerComponent,
+  getDefault3DContextVersion: getDefault3DContextVersion,
+  getExtensionPrefixedNames: getExtensionPrefixedNames,
+  getExtensionWithKnownPrefixes: getExtensionWithKnownPrefixes,
+  getFileListAsync: getFileListAsync,
+  getLastError: getLastError,
+  getPrefixedProperty: getPrefixedProperty,
+  getScript: getScript,
+  getSupportedExtensionWithKnownPrefixes: getSupportedExtensionWithKnownPrefixes,
+  getTypedArrayElementsPerPixel: getTypedArrayElementsPerPixel,
+  getUrlArguments: getUrlArguments,
+  getUrlOptions: getUrlOptions,
+  getAttribMap: getAttribMap,
+  getUniformMap: getUniformMap,
+  glEnumToString: glEnumToString,
+  glErrorAssert: glErrorAssert,
+  glErrorShouldBe: glErrorShouldBe,
+  glTypeToTypedArrayType: glTypeToTypedArrayType,
+  hasAttributeCaseInsensitive: hasAttributeCaseInsensitive,
+  insertImage: insertImage,
+  isWebGL2: isWebGL2,
+  linkProgram: linkProgram,
+  loadCrossOriginImage: loadCrossOriginImage,
+  loadImageAsync: loadImageAsync,
+  loadImagesAsync: loadImagesAsync,
+  loadProgram: loadProgram,
+  loadProgramFromFile: loadProgramFromFile,
+  loadProgramFromScript: loadProgramFromScript,
+  loadProgramFromScriptExpectError: loadProgramFromScriptExpectError,
+  loadShader: loadShader,
+  loadShaderFromFile: loadShaderFromFile,
+  loadShaderFromScript: loadShaderFromScript,
+  loadStandardProgram: loadStandardProgram,
+  loadStandardProgramAsync: loadStandardProgramAsync,
+  loadStandardVertexShader: loadStandardVertexShader,
+  loadStandardVertexShaderAsync: loadStandardVertexShaderAsync,
+  loadStandardFragmentShader: loadStandardFragmentShader,
+  loadStandardFragmentShaderAsync: loadStandardFragmentShaderAsync,
+  loadUniformBlockProgram: loadUniformBlockProgram,
+  loadUniformBlockVertexShader: loadUniformBlockVertexShader,
+  loadUniformBlockFragmentShader: loadUniformBlockFragmentShader,
+  loadTextFileAsync: loadTextFileAsync,
+  loadTexture: loadTexture,
+  log: log,
+  loggingOff: loggingOff,
+  makeCheckRect: makeCheckRect,
+  makeImage: makeImage,
+  makeImageFromCanvas: makeImageFromCanvas,
+  makeVideo: makeVideo,
+  error: error,
+  runExtensionSupportedTest: runExtensionSupportedTest,
+  shallowCopyObject: shallowCopyObject,
+  setDefault3DContextVersion: setDefault3DContextVersion,
+  setupColorQuad: setupColorQuad,
+  setupProgram: setupProgram,
+  setupTransformFeedbackProgram: setupTransformFeedbackProgram,
+  setupQuad: setupQuad,
+  setupQuadWithTexCoords: setupQuadWithTexCoords,
+  setupIndexedQuad: setupIndexedQuad,
+  setupIndexedQuadWithOptions: setupIndexedQuadWithOptions,
+  setupSimpleColorProgram: setupSimpleColorProgram,
+  setupSimpleTextureProgram: setupSimpleTextureProgram,
+  setupSimpleTextureProgramESSL300: setupSimpleTextureProgramESSL300,
+  setupSimpleCubeMapTextureProgram: setupSimpleCubeMapTextureProgram,
+  setupSimpleVertexColorProgram: setupSimpleVertexColorProgram,
+  setupNoTexCoordTextureProgram: setupNoTexCoordTextureProgram,
+  setupTexturedQuad: setupTexturedQuad,
+  setupTexturedQuadWithTexCoords: setupTexturedQuadWithTexCoords,
+  setupTexturedQuadWithCubeMap: setupTexturedQuadWithCubeMap,
+  setupUnitQuad: setupUnitQuad,
+  setFloatDrawColor: setFloatDrawColor,
+  setUByteDrawColor: setUByteDrawColor,
+  startPlayingAndWaitForVideo: startPlayingAndWaitForVideo,
+  startsWith: startsWith,
+  shouldGenerateGLError: shouldGenerateGLError,
+  shouldThrow: shouldThrow,
+  readFile: readFile,
+  readFileList: readFileList,
+  replaceParams: replaceParams,
+  requestAnimFrame: requestAnimFrame,
+  runSteps: runSteps,
+  waitForComposite: waitForComposite,
+
+  // fullscreen api
+  setupFullscreen: setupFullscreen,
+
+  // sRGB converter api
+  sRGBToLinear: sRGBToLinear,
+  linearToSRGB: linearToSRGB,
+
+  getHost: getHost,
+  getBaseDomain: getBaseDomain,
+  runningOnLocalhost: runningOnLocalhost,
+  getLocalCrossOrigin: getLocalCrossOrigin,
+  getRelativePath: getRelativePath,
+  awaitOrTimeout: awaitOrTimeout,
+  awaitTimeout: awaitTimeout,
+
+  none: false
+};
+
+Object.defineProperties(API, {
+  noTexCoordTextureVertexShader: { value: noTexCoordTextureVertexShader, writable: false },
+  simpleTextureVertexShader: { value: simpleTextureVertexShader, writable: false },
+  simpleTextureVertexShaderESSL300: { value: simpleTextureVertexShaderESSL300, writable: false },
+  simpleColorFragmentShader: { value: simpleColorFragmentShader, writable: false },
+  simpleColorFragmentShaderESSL300: { value: simpleColorFragmentShaderESSL300, writable: false },
+  simpleVertexShader: { value: simpleVertexShader, writable: false },
+  simpleVertexShaderESSL300: { value: simpleVertexShaderESSL300, writable: false },
+  simpleTextureFragmentShader: { value: simpleTextureFragmentShader, writable: false },
+  simpleTextureFragmentShaderESSL300: { value: simpleTextureFragmentShaderESSL300, writable: false },
+  simpleHighPrecisionTextureFragmentShader: { value: simpleHighPrecisionTextureFragmentShader, writable: false },
+  simpleCubeMapTextureFragmentShader: { value: simpleCubeMapTextureFragmentShader, writable: false },
+  simpleVertexColorFragmentShader: { value: simpleVertexColorFragmentShader, writable: false },
+  simpleVertexColorVertexShader: { value: simpleVertexColorVertexShader, writable: false }
+});
+
+return API;
+
+}());
diff --git a/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/js-test-style.css b/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/js-test-style.css
new file mode 100644
index 0000000..5f6839b
--- /dev/null
+++ b/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/js-test-style.css
@@ -0,0 +1,20 @@
+.pass {
+    font-weight: bold;
+    color: green;
+}
+.fail {
+    font-weight: bold;
+    color: red;
+}
+.warn {
+    font-weight: bold;
+    color: yellow;
+    text-shadow: 1px 1px #ff0000
+}
+#console {
+    white-space: pre-wrap;
+    font-family: monospace;
+}
+body {
+    background-color: #ffffff;
+}
diff --git a/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/opengl_logo.jpg b/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/opengl_logo.jpg
new file mode 100644
index 0000000..e3b70be
--- /dev/null
+++ b/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/opengl_logo.jpg
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/thunderbird-logo-64x64.png b/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/thunderbird-logo-64x64.png
new file mode 100644
index 0000000..e2326f5
--- /dev/null
+++ b/LayoutTests/http/tests/webgl/resources/webgl_test_files/resources/thunderbird-logo-64x64.png
Binary files differ
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webkit-webgl-test-harness.js b/LayoutTests/http/tests/webgl/resources/webkit-webgl-test-harness.js
similarity index 60%
rename from LayoutTests/http/tests/webgl/1.0.2/resources/webkit-webgl-test-harness.js
rename to LayoutTests/http/tests/webgl/resources/webkit-webgl-test-harness.js
index 08c91c2..c8615be 100644
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webkit-webgl-test-harness.js
+++ b/LayoutTests/http/tests/webgl/resources/webkit-webgl-test-harness.js
@@ -1,6 +1,8 @@
 "use strict";
 (function() {
   var numFailures = 0;
+  var resultsList = null;
+  var resultNum = 1;
 
   if (window.testRunner && !window.layoutTestController) {
     window.layoutTestController = window.testRunner;
@@ -21,6 +23,21 @@
     window.internals.settings.setWebGLErrorsToConsoleEnabled(false);
   }
 
+  var list = function(msg, color) {
+    if (!resultsList) {
+      resultsList = document.createElement("ul");
+      document.getElementById("result").appendChild(resultsList);
+    }
+
+    var item = document.createElement("li");
+    item.appendChild(document.createTextNode(msg));
+    if (color) {
+      item.style.color = color;
+    }
+
+    resultsList.appendChild(item);
+  }
+
   var log = function(msg, color) {
     var div = document.createElement("div");
     div.appendChild(document.createTextNode(msg));
@@ -32,18 +49,24 @@
 
   window.webglTestHarness = {
     reportResults: function(url, success, msg) {
-      if (!success) {
+      if (success) {
+        list(`[ ${resultNum}: PASS ] ${msg}`, "green");
+      } else {
+        list(`[ ${resultNum}: FAIL ] ${msg}`, "red");
         ++numFailures;
       }
+
+      ++resultNum;
     },
 
     notifyFinished: function(url) {
       var iframe = document.getElementById("iframe");
-      iframe.innerHTML = "";
       if (numFailures > 0) {
-        log("FAIL", "red");
+        log(`[ FAIL ] ${numFailures} failures reported`, "red");
       } else {
-        log("PASS", "green");
+        resultsList.innerHTML = "";
+        iframe.innerHTML = "";
+        log("[ PASS ] All tests passed", "green");
       }
 
       if (window.layoutTestController) {
@@ -52,4 +75,3 @@
     },
   }
 }());
-
diff --git a/LayoutTests/platform/gtk/TestExpectations b/LayoutTests/platform/gtk/TestExpectations
index a16c6fc..ecac365 100644
--- a/LayoutTests/platform/gtk/TestExpectations
+++ b/LayoutTests/platform/gtk/TestExpectations
@@ -514,6 +514,7 @@
 webkit.org/b/166536 webgl/2.0.0/ [ Skip ]
 webkit.org/b/166536 webgl/2.0.y/ [ Skip ]
 webkit.org/b/166536 webgl/pending/conformance2/ [ Skip ]
+webkit.org/b/166536 http/tests/webgl/2.0.y/ [ Skip ]
 
 # These tests reference specific fonts on Mac port.
 Bug(GTK) fast/text/font-weights.html [ WontFix ]
diff --git a/LayoutTests/platform/wincairo/TestExpectations b/LayoutTests/platform/wincairo/TestExpectations
index b124e48..e44e56c 100644
--- a/LayoutTests/platform/wincairo/TestExpectations
+++ b/LayoutTests/platform/wincairo/TestExpectations
@@ -2041,8 +2041,6 @@
 http/tests/misc/webtiming-one-redirect.py [ Failure ]
 http/tests/misc/webtiming-two-redirects.py [ Failure ]
 http/tests/performance/paint-timing/performance-paint-timing-fcp-after-visually-non-empty-for-style.html [ Timeout ]
-http/tests/webgl/1.0.2/origin-clean-conformance.html [ Failure ]
-http/tests/webgl/1.0.2/readPixelsBadArgs.html [ Failure ]
 http/tests/websocket/web-socket-loads-captured-in-per-page-domains.html [ Skip ] # Crash by assertion failure
 http/tests/xmlhttprequest/access-control-basic-allow-list-request-headers.html [ Failure ]
 http/tests/xmlhttprequest/chunked-progress-event-expectedLength.html [ Failure Timeout ]
diff --git a/LayoutTests/webgl/1.0.x/conformance/canvas/to-data-url-after-composite-expected.txt b/LayoutTests/webgl/1.0.x/conformance/canvas/to-data-url-after-composite-expected.txt
new file mode 100644
index 0000000..5e87343
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/canvas/to-data-url-after-composite-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/canvas/to-data-url-after-composite.html b/LayoutTests/webgl/1.0.x/conformance/canvas/to-data-url-after-composite.html
new file mode 100644
index 0000000..87302d3
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/canvas/to-data-url-after-composite.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for to-data-url-after-composite.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html">../../../resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008-expected.txt
new file mode 100644
index 0000000..31f4c01
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008.html
new file mode 100644
index 0000000..0e13d67
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_001_to_008.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_001_to_008.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016-expected.txt
new file mode 100644
index 0000000..2bd9903
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016.html
new file mode 100644
index 0000000..add903e
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_009_to_016.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_009_to_016.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024-expected.txt
new file mode 100644
index 0000000..f50f139
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024.html
new file mode 100644
index 0000000..d203ef8
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_017_to_024.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_017_to_024.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032-expected.txt
new file mode 100644
index 0000000..cdea737
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032.html
new file mode 100644
index 0000000..ad80255
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_025_to_032.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_025_to_032.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040-expected.txt
new file mode 100644
index 0000000..2ab9e92
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040.html
new file mode 100644
index 0000000..335d65a
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_033_to_040.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_033_to_040.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048-expected.txt
new file mode 100644
index 0000000..bdf2434
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048.html
new file mode 100644
index 0000000..d169e9d
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_041_to_048.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_041_to_048.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056-expected.txt
new file mode 100644
index 0000000..1608556
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056.html
new file mode 100644
index 0000000..0f97837
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_049_to_056.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_049_to_056.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064-expected.txt
new file mode 100644
index 0000000..8419aa1
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064.html
new file mode 100644
index 0000000..76ad1e6
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_057_to_064.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_057_to_064.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072-expected.txt
new file mode 100644
index 0000000..8956366
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072.html
new file mode 100644
index 0000000..e40fcb7
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_065_to_072.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_065_to_072.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080-expected.txt
new file mode 100644
index 0000000..7af2b7e
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080.html
new file mode 100644
index 0000000..6027737
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_073_to_080.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_073_to_080.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088-expected.txt
new file mode 100644
index 0000000..d84396f
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088.html
new file mode 100644
index 0000000..cb9abac
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_081_to_088.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_081_to_088.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096-expected.txt
new file mode 100644
index 0000000..c2687f0
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096.html
new file mode 100644
index 0000000..62e52a8
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_089_to_096.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_089_to_096.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104-expected.txt
new file mode 100644
index 0000000..51ddb25
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104.html
new file mode 100644
index 0000000..b07e4c1
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_097_to_104.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_097_to_104.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112-expected.txt
new file mode 100644
index 0000000..e45ceec
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112.html
new file mode 100644
index 0000000..ad14163
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_105_to_112.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_105_to_112.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120-expected.txt
new file mode 100644
index 0000000..5fcde16
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120.html
new file mode 100644
index 0000000..44b5246
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_113_to_120.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_113_to_120.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128-expected.txt
new file mode 100644
index 0000000..0725ff2
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128.html
new file mode 100644
index 0000000..b50e91a
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_121_to_128.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_121_to_128.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136-expected.txt
new file mode 100644
index 0000000..d423d6b
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136.html
new file mode 100644
index 0000000..1b9af7e
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_129_to_136.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_129_to_136.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144-expected.txt
new file mode 100644
index 0000000..bcde66a
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144.html
new file mode 100644
index 0000000..803a201
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_137_to_144.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_137_to_144.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152-expected.txt
new file mode 100644
index 0000000..294da61
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152.html
new file mode 100644
index 0000000..f36f9ab
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_145_to_152.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_145_to_152.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160-expected.txt
new file mode 100644
index 0000000..22d0d5b
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160.html
new file mode 100644
index 0000000..97aea8a
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_153_to_160.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_153_to_160.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168-expected.txt
new file mode 100644
index 0000000..938c9ff
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168.html
new file mode 100644
index 0000000..6f3f84b
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_161_to_168.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_161_to_168.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176-expected.txt
new file mode 100644
index 0000000..5db35f1
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176.html
new file mode 100644
index 0000000..4ba3155
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_169_to_176.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_169_to_176.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178-expected.txt b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178-expected.txt
new file mode 100644
index 0000000..a08d9a0
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178.html b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178.html
new file mode 100644
index 0000000..55d1668
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/ogles/GL/build/build_177_to_178.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_177_to_178.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt b/LayoutTests/webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt
new file mode 100644
index 0000000..ab2f862
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test.html b/LayoutTests/webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test.html
new file mode 100644
index 0000000..31ccab0
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/rendering/clear-default-framebuffer-with-scissor-test.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for clear-default-framebuffer-with-scissor-test.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html">../../../resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt b/LayoutTests/webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt
new file mode 100644
index 0000000..b54917e
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html b/LayoutTests/webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html
new file mode 100644
index 0000000..2917693
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for color-mask-should-not-affect-antialiased-framebuffer-resolution.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html">../../../resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt b/LayoutTests/webgl/1.0.x/conformance/textures/misc/format-filterable-renderable-expected.txt
similarity index 80%
copy from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
copy to LayoutTests/webgl/1.0.x/conformance/textures/misc/format-filterable-renderable-expected.txt
index 29cb42a..24c778a 100644
--- a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
+++ b/LayoutTests/webgl/1.0.x/conformance/textures/misc/format-filterable-renderable-expected.txt
@@ -1,4 +1,4 @@
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
-Test: ../../../../resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html
+Test: ../../../../resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html
 [ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/format-filterable-renderable.html b/LayoutTests/webgl/1.0.x/conformance/textures/misc/format-filterable-renderable.html
new file mode 100644
index 0000000..6a899eb
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/textures/misc/format-filterable-renderable.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for format-filterable-renderable.html</title>
+<script type="text/javascript" src="../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html">../../../../resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html</a>
+<div id="iframe">
+<iframe src="../../../../resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt b/LayoutTests/webgl/1.0.x/conformance/textures/misc/png-image-types-expected.txt
similarity index 82%
copy from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
copy to LayoutTests/webgl/1.0.x/conformance/textures/misc/png-image-types-expected.txt
index 29cb42a..3fae0d9 100644
--- a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
+++ b/LayoutTests/webgl/1.0.x/conformance/textures/misc/png-image-types-expected.txt
@@ -1,4 +1,4 @@
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
-Test: ../../../../resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html
+Test: ../../../../resources/webgl_test_files/conformance/textures/misc/png-image-types.html
 [ PASS ] All tests passed
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/png-image-types.html b/LayoutTests/webgl/1.0.x/conformance/textures/misc/png-image-types.html
new file mode 100644
index 0000000..12559be
--- /dev/null
+++ b/LayoutTests/webgl/1.0.x/conformance/textures/misc/png-image-types.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for png-image-types.html</title>
+<script type="text/javascript" src="../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../resources/webgl_test_files/conformance/textures/misc/png-image-types.html">../../../../resources/webgl_test_files/conformance/textures/misc/png-image-types.html</a>
+<div id="iframe">
+<iframe src="../../../../resources/webgl_test_files/conformance/textures/misc/png-image-types.html" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/canvas/to-data-url-after-composite-expected.txt b/LayoutTests/webgl/2.0.y/conformance/canvas/to-data-url-after-composite-expected.txt
new file mode 100644
index 0000000..0d8e86b
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/canvas/to-data-url-after-composite-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/canvas/to-data-url-after-composite.html b/LayoutTests/webgl/2.0.y/conformance/canvas/to-data-url-after-composite.html
new file mode 100644
index 0000000..af25a41
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/canvas/to-data-url-after-composite.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for to-data-url-after-composite.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html?webglVersion=2">../../../resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008-expected.txt
new file mode 100644
index 0000000..77c9a55
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008.html
new file mode 100644
index 0000000..a326390
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_001_to_008.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_001_to_008.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016-expected.txt
new file mode 100644
index 0000000..2125961
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016.html
new file mode 100644
index 0000000..377a749
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_009_to_016.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_009_to_016.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024-expected.txt
new file mode 100644
index 0000000..cde8568
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024.html
new file mode 100644
index 0000000..b2b7a95
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_017_to_024.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_017_to_024.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032-expected.txt
new file mode 100644
index 0000000..4b1b82a
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032.html
new file mode 100644
index 0000000..f4537b5
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_025_to_032.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_025_to_032.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040-expected.txt
new file mode 100644
index 0000000..cdd44e5
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040.html
new file mode 100644
index 0000000..9903ee2
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_033_to_040.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_033_to_040.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048-expected.txt
new file mode 100644
index 0000000..40a199a
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048.html
new file mode 100644
index 0000000..39ab554
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_041_to_048.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_041_to_048.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056-expected.txt
new file mode 100644
index 0000000..adf9557
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056.html
new file mode 100644
index 0000000..75bd700
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_049_to_056.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_049_to_056.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064-expected.txt
new file mode 100644
index 0000000..f93a8bc
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064.html
new file mode 100644
index 0000000..30beacd
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_057_to_064.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_057_to_064.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072-expected.txt
new file mode 100644
index 0000000..0f875f2
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072.html
new file mode 100644
index 0000000..1c68d06
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_065_to_072.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_065_to_072.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080-expected.txt
new file mode 100644
index 0000000..2597087
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080.html
new file mode 100644
index 0000000..28a8fed
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_073_to_080.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_073_to_080.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088-expected.txt
new file mode 100644
index 0000000..2e2f651
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088.html
new file mode 100644
index 0000000..db6ca57
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_081_to_088.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_081_to_088.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096-expected.txt
new file mode 100644
index 0000000..d38283a
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096.html
new file mode 100644
index 0000000..aebfb1b
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_089_to_096.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_089_to_096.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104-expected.txt
new file mode 100644
index 0000000..e8abbd4
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104.html
new file mode 100644
index 0000000..8ea374a8
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_097_to_104.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_097_to_104.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112-expected.txt
new file mode 100644
index 0000000..6b45359
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112.html
new file mode 100644
index 0000000..e3aaef7
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_105_to_112.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_105_to_112.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120-expected.txt
new file mode 100644
index 0000000..c155143
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120.html
new file mode 100644
index 0000000..4b84c84
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_113_to_120.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_113_to_120.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128-expected.txt
new file mode 100644
index 0000000..1700285
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128.html
new file mode 100644
index 0000000..1db8fec
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_121_to_128.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_121_to_128.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136-expected.txt
new file mode 100644
index 0000000..722d3bf
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136.html
new file mode 100644
index 0000000..c301c69
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_129_to_136.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_129_to_136.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144-expected.txt
new file mode 100644
index 0000000..559e76b
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144.html
new file mode 100644
index 0000000..f173266
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_137_to_144.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_137_to_144.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152-expected.txt
new file mode 100644
index 0000000..8a64a48
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152.html
new file mode 100644
index 0000000..53e105c
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_145_to_152.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_145_to_152.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160-expected.txt
new file mode 100644
index 0000000..7619b42
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160.html
new file mode 100644
index 0000000..0e4ecfd
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_153_to_160.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_153_to_160.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168-expected.txt
new file mode 100644
index 0000000..bf76d02
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168.html
new file mode 100644
index 0000000..2248dfe
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_161_to_168.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_161_to_168.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176-expected.txt
new file mode 100644
index 0000000..f318488
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176.html
new file mode 100644
index 0000000..9002d5e
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_169_to_176.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_169_to_176.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178-expected.txt b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178-expected.txt
new file mode 100644
index 0000000..3ba675b
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178.html b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178.html
new file mode 100644
index 0000000..bc7851e
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/ogles/GL/build/build_177_to_178.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for build_177_to_178.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html?webglVersion=2">../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt b/LayoutTests/webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt
new file mode 100644
index 0000000..51c30ce
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test.html b/LayoutTests/webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test.html
new file mode 100644
index 0000000..916bc18
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/rendering/clear-default-framebuffer-with-scissor-test.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for clear-default-framebuffer-with-scissor-test.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html?webglVersion=2">../../../resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt b/LayoutTests/webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt
new file mode 100644
index 0000000..841f3fb
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html b/LayoutTests/webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html
new file mode 100644
index 0000000..3bf0eb1
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for color-mask-should-not-affect-antialiased-framebuffer-resolution.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html?webglVersion=2">../../../resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt b/LayoutTests/webgl/2.0.y/conformance/textures/misc/format-filterable-renderable-expected.txt
similarity index 75%
copy from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
copy to LayoutTests/webgl/2.0.y/conformance/textures/misc/format-filterable-renderable-expected.txt
index a04d796..57b85fb 100644
--- a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-offscreencanvas-expected.txt
+++ b/LayoutTests/webgl/2.0.y/conformance/textures/misc/format-filterable-renderable-expected.txt
@@ -1,4 +1,4 @@
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
-Test: ../../../../resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance-offscreencanvas.html
+Test: ../../../../resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html?webglVersion=2
 [ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/textures/misc/format-filterable-renderable.html b/LayoutTests/webgl/2.0.y/conformance/textures/misc/format-filterable-renderable.html
new file mode 100644
index 0000000..981ea26
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/textures/misc/format-filterable-renderable.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for format-filterable-renderable.html</title>
+<script type="text/javascript" src="../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html?webglVersion=2">../../../../resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt b/LayoutTests/webgl/2.0.y/conformance/textures/misc/png-image-types-expected.txt
similarity index 79%
copy from LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
copy to LayoutTests/webgl/2.0.y/conformance/textures/misc/png-image-types-expected.txt
index 29cb42a..b17f215f 100644
--- a/LayoutTests/webgl/1.0.x/conformance/textures/misc/origin-clean-conformance-expected.txt
+++ b/LayoutTests/webgl/2.0.y/conformance/textures/misc/png-image-types-expected.txt
@@ -1,4 +1,4 @@
 This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
 
-Test: ../../../../resources/webgl_test_files/conformance/textures/misc/origin-clean-conformance.html
+Test: ../../../../resources/webgl_test_files/conformance/textures/misc/png-image-types.html?webglVersion=2
 [ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance/textures/misc/png-image-types.html b/LayoutTests/webgl/2.0.y/conformance/textures/misc/png-image-types.html
new file mode 100644
index 0000000..c06d63f
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance/textures/misc/png-image-types.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for png-image-types.html</title>
+<script type="text/javascript" src="../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../resources/webgl_test_files/conformance/textures/misc/png-image-types.html?webglVersion=2">../../../../resources/webgl_test_files/conformance/textures/misc/png-image-types.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../resources/webgl_test_files/conformance/textures/misc/png-image-types.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance2/extensions/required-extensions-expected.txt b/LayoutTests/webgl/2.0.y/conformance2/extensions/required-extensions-expected.txt
new file mode 100644
index 0000000..fed21da
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/extensions/required-extensions-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance2/extensions/required-extensions.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance2/extensions/required-extensions.html b/LayoutTests/webgl/2.0.y/conformance2/extensions/required-extensions.html
new file mode 100644
index 0000000..554b755
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/extensions/required-extensions.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for required-extensions.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance2/extensions/required-extensions.html?webglVersion=2">../../../resources/webgl_test_files/conformance2/extensions/required-extensions.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance2/extensions/required-extensions.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash-expected.txt b/LayoutTests/webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash-expected.txt
new file mode 100644
index 0000000..9b4d122
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash.html b/LayoutTests/webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash.html
new file mode 100644
index 0000000..059a7ff
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/glsl3/fragment-shader-loop-crash.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for fragment-shader-loop-crash.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html?webglVersion=2">../../../resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash-expected.txt b/LayoutTests/webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash-expected.txt
new file mode 100644
index 0000000..ced88ff
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html b/LayoutTests/webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html
new file mode 100644
index 0000000..c1e0e0e
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for reciprocal-sqrt-of-sum-of-squares-crash.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html?webglVersion=2">../../../resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance2/misc/blend-integer-expected.txt b/LayoutTests/webgl/2.0.y/conformance2/misc/blend-integer-expected.txt
new file mode 100644
index 0000000..171ae70
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/misc/blend-integer-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance2/misc/blend-integer.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance2/misc/blend-integer.html b/LayoutTests/webgl/2.0.y/conformance2/misc/blend-integer.html
new file mode 100644
index 0000000..f16b62f
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/misc/blend-integer.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for blend-integer.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance2/misc/blend-integer.html?webglVersion=2">../../../resources/webgl_test_files/conformance2/misc/blend-integer.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance2/misc/blend-integer.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask-expected.txt b/LayoutTests/webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask-expected.txt
new file mode 100644
index 0000000..cfe7561
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html b/LayoutTests/webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html
new file mode 100644
index 0000000..b93d9ac
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for blitframebuffer-unaffected-by-colormask.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html?webglVersion=2">../../../resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations-expected.txt b/LayoutTests/webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations-expected.txt
new file mode 100644
index 0000000..e48c818
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations.html b/LayoutTests/webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations.html
new file mode 100644
index 0000000..9262120
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/conformance2/rendering/draw-buffers-sparse-output-locations.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for draw-buffers-sparse-output-locations.html</title>
+<script type="text/javascript" src="../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html?webglVersion=2">../../../resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample-expected.txt b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample-expected.txt
deleted file mode 100644
index 5d9491b..0000000
--- a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample-expected.txt
+++ /dev/null
@@ -1,4 +0,0 @@
-This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
-
-Test: ../../../../resources/webgl_test_files/deqp/functional/gles3/multisample.html?webglVersion=2
-[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample.html b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample.html
deleted file mode 100644
index a23c05e..0000000
--- a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample.html
+++ /dev/null
@@ -1,18 +0,0 @@
-<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL Conformance Test Wrapper for multisample.html</title>
-<script type="text/javascript" src="../../../../resources/js-test-pre.js"></script>
-<script type="text/javascript" src="../../../../resources/webkit-webgl-test-harness.js"></script>
-</head>
-<body>
-<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
-Test: <a href="../../../../resources/webgl_test_files/deqp/functional/gles3/multisample.html?webglVersion=2">../../../../resources/webgl_test_files/deqp/functional/gles3/multisample.html?webglVersion=2</a>
-<div id="iframe">
-<iframe src="../../../../resources/webgl_test_files/deqp/functional/gles3/multisample.html?webglVersion=2" width="800" height="600"></iframe>
-</div>
-<div id="result"></div>
-</body>
-</html>
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo-expected.txt b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo-expected.txt
new file mode 100644
index 0000000..d5922d6
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo.html b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo.html
new file mode 100644
index 0000000..402e67b
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/default_fbo.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for default_fbo.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html?webglVersion=2">../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples-expected.txt b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples-expected.txt
new file mode 100644
index 0000000..e840214
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples.html b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples.html
new file mode 100644
index 0000000..ff5fc75
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_4_samples.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for fbo_4_samples.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html?webglVersion=2">../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples-expected.txt b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples-expected.txt
new file mode 100644
index 0000000..dbd5437
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples.html b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples.html
new file mode 100644
index 0000000..5e60d44
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_8_samples.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for fbo_8_samples.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html?webglVersion=2">../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples-expected.txt b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples-expected.txt
new file mode 100644
index 0000000..4032cf5
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples-expected.txt
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html?webglVersion=2
+[ PASS ] All tests passed
diff --git a/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples.html b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples.html
new file mode 100644
index 0000000..bd865cd
--- /dev/null
+++ b/LayoutTests/webgl/2.0.y/deqp/functional/gles3/multisample/fbo_max_samples.html
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for fbo_max_samples.html</title>
+<script type="text/javascript" src="../../../../../resources/js-test-pre.js"></script>
+<script type="text/javascript" src="../../../../../resources/webkit-webgl-test-harness.js"></script>
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href="../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html?webglVersion=2">../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html?webglVersion=2</a>
+<div id="iframe">
+<iframe src="../../../../../resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html?webglVersion=2" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
diff --git a/LayoutTests/webgl/draw-webgl-to-context2d-memory-test-expected.txt b/LayoutTests/webgl/draw-webgl-to-context2d-memory-test-expected.txt
index cb7593c..c5889b1 100644
--- a/LayoutTests/webgl/draw-webgl-to-context2d-memory-test-expected.txt
+++ b/LayoutTests/webgl/draw-webgl-to-context2d-memory-test-expected.txt
@@ -2,6 +2,8 @@
 
 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
 
+TEST COMPLETE: 27 PASS, 0 FAIL
+
 PASS drawImage: Should be [64, 128, 192, 255]
 PASS drawImage: Should be [64, 128, 192, 255]
 PASS drawImage: Should be [64, 128, 192, 255]
diff --git a/LayoutTests/webgl/resources/pending_webgl_test_files/conformance/textures/misc/tex-image-video-repeated.html b/LayoutTests/webgl/resources/pending_webgl_test_files/conformance/textures/misc/tex-image-video-repeated.html
index 52c1676..910afba 100644
--- a/LayoutTests/webgl/resources/pending_webgl_test_files/conformance/textures/misc/tex-image-video-repeated.html
+++ b/LayoutTests/webgl/resources/pending_webgl_test_files/conformance/textures/misc/tex-image-video-repeated.html
@@ -16,7 +16,7 @@
 var gl = null;
 var textureLoc = null;
 var successfullyParsed = false;
-var blue = [0, 0, 248];
+var blue = [0, 0, 255];
 var yellow = [255, 255, 0];
 var black = [0, 0, 0];
 initTestingHarness();
@@ -50,9 +50,9 @@
     const rightColor = yellow;
     const tolerance = 5;
     debug("Checking mid left border");
-    wtu.checkCanvasRect(gl, 4, 20, 2, 2, leftColor, "shouldBe " + leftColor, tolerance);
+    wtu.checkCanvasRect(gl, 4, 17, 2, 2, leftColor, "shouldBe " + leftColor, tolerance);
     debug("Checking mid right border");
-    wtu.checkCanvasRect(gl, gl.canvas.width - 4, gl.canvas.height - 20, 2, 2, rightColor, "shouldBe " + rightColor, tolerance);
+    wtu.checkCanvasRect(gl, 60, 28, 2, 2, rightColor, "shouldBe " + rightColor, tolerance);
 }
 
 function testTwoTexturesBug1(video1, video2)
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/attribs/gl-vertexattribpointer.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/attribs/gl-vertexattribpointer.html
index 52d4117..1276cec 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/attribs/gl-vertexattribpointer.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/attribs/gl-vertexattribpointer.html
@@ -152,7 +152,7 @@
               gl, size < info.minSize ? gl.INVALID_OPERATION : gl.NO_ERROR, "at stride limit",
               size, info.type, false, stride, offset);
           checkVertexAttribPointer(
-              gl, size < info.minSize ? gl.INVALID_OPERATION : gl.INVALID_VALUE, "over stride limit",
+              gl, size < info.minSize ? [gl.INVALID_OPERATION, gl.INVALID_VALUE] : gl.INVALID_VALUE, "over stride limit",
               size, info.type, false,
               stride + info.bytesPerComponent, offset);
         }
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html
new file mode 100644
index 0000000..668b9c7
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/canvas/to-data-url-after-composite.html
@@ -0,0 +1,51 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL toDataURL after composite test</title>
+<link rel="stylesheet" href="../../resources/js-test-style.css"/>
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"> </script>
+</head>
+<body>
+<canvas width="20" height="20" style="border: 1px solid black; width: 128px; height: 128px" id="c3d"></canvas>
+<canvas width="20" height="20" style="border: 1px solid black; width: 128px; height: 128px" id="c2d"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+<script type="application/javascript">
+const wtu = WebGLTestUtils;
+let gl;
+let ctx;
+
+function main() {
+  description();
+  const c2d = document.getElementById("c2d");
+  ctx = c2d.getContext("2d");
+  gl = wtu.create3DContext("c3d", { preserveDrawingBuffer: true });
+
+  // Clear to green
+  gl.clearColor(0.0, 1.0, 0.0, 1.0);
+  gl.clear(gl.COLOR_BUFFER_BIT);
+
+  wtu.waitForComposite(() => {
+    // Performs gl.canvas.toDataURL() internally
+    let img = wtu.makeImageFromCanvas(gl.canvas, function() {
+      ctx.drawImage(img, 0, 0);
+      wtu.checkCanvas(ctx, [0, 255, 0], "toDataURL loaded into image, drawn into 2D context, should be green", 5);
+      finishTest();
+    });
+  });
+
+};
+
+main();
+var successfullyParsed = true;
+</script>
+</body>
+</html>
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/context/context-attributes-alpha-depth-stencil-antialias.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/context/context-attributes-alpha-depth-stencil-antialias.html
index ac79698..40f46a7 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/context/context-attributes-alpha-depth-stencil-antialias.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/context/context-attributes-alpha-depth-stencil-antialias.html
@@ -47,6 +47,7 @@
 var fbHasColor;
 var fbHasDepth;
 var fbHasStencil;
+var contextVersion = wtu.getDefault3DContextVersion();
 
 function init()
 {
@@ -55,6 +56,23 @@
     runTest();
 }
 
+var vertices = new Float32Array([
+    1.0, 1.0, 0.0,
+    -1.0, 1.0, 0.0,
+    -1.0, -1.0, 0.0,
+    1.0, 1.0, 0.0,
+    -1.0, -1.0, 0.0,
+    1.0, -1.0, 0.0]);
+
+var colors = new Uint8Array([
+    255, 0, 0, 255,
+    255, 0, 0, 255,
+    255, 0, 0, 255,
+    255, 0, 0, 255,
+    255, 0, 0, 255,
+    255, 0, 0, 255]);
+
+
 function getWebGL(canvasWidth, canvasHeight, contextAttribs, clearColor, clearDepth, clearStencil)
 {
     var canvas = document.createElement("canvas");
@@ -63,7 +81,7 @@
     canvas.width = canvasWidth;
     canvas.height = canvasHeight;
 
-    gl = wtu.create3DContext(canvas, contextAttribs);
+    gl = wtu.create3DContext(canvas, contextAttribs, contextVersion);
     if (!gl)
         return null;
 
@@ -102,27 +120,75 @@
       }
     }
     gl.bindFramebuffer(gl.FRAMEBUFFER, null);
-    wtu.glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
 
-    return gl;
-}
-
-function drawAndReadPixel(gl, vertices, colors)
-{
     var colorOffset = vertices.byteLength;
-
     var vbo = gl.createBuffer();
     gl.bindBuffer(gl.ARRAY_BUFFER, vbo);
     gl.bufferData(gl.ARRAY_BUFFER, colorOffset + colors.byteLength, gl.STATIC_DRAW);
     gl.bufferSubData(gl.ARRAY_BUFFER, 0, vertices);
     gl.bufferSubData(gl.ARRAY_BUFFER, colorOffset, colors);
-
     gl.vertexAttribPointer(0, 3, gl.FLOAT, false, 0, 0);
     gl.enableVertexAttribArray(0);
     gl.vertexAttribPointer(1, 4, gl.UNSIGNED_BYTE, true, 0, colorOffset);
     gl.enableVertexAttribArray(1);
 
-    gl.drawArrays(gl.TRIANGLES, 0, vertices.length / 3);
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR, "should be no errors");
+    return gl;
+}
+
+function draw(gl, verticesCount)
+{
+    verticesCount = verticesCount || vertices.length / 3;
+    gl.drawArrays(gl.TRIANGLES, 0, verticesCount);
+}
+
+function checkDraw(hasAlpha, hasStencil, hasDepth, hasAntialias)
+{
+    let red = [255, 0, 0, 255 ];
+    let black = [0, 0, 0, hasAlpha ? 0 : 255 ];
+    debug(`Testing that stencil ${ hasStencil ? 'affects': 'does not affect'} the rendering.`);
+    gl.stencilFunc(gl.NEVER, 1, 1);
+    gl.stencilOp(gl.KEEP, gl.KEEP, gl.KEEP);
+    draw(gl);
+    correctColor = hasStencil ? black : red;
+    wtu.checkCanvas(gl, correctColor)
+    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT | gl.STENCIL_BUFFER_BIT);
+    wtu.checkCanvas(gl, black);
+    gl.stencilFunc(gl.ALWAYS, 1, 1);
+
+    debug(`Testing that depth ${ hasDepth ? 'affects': 'does not affect'} the rendering.`);
+    gl.depthFunc(gl.NEVER);
+    draw(gl);
+    correctColor = hasDepth ? black : red;
+    wtu.checkCanvas(gl, correctColor);
+    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT | gl.STENCIL_BUFFER_BIT);
+    wtu.checkCanvas(gl, black);
+    gl.depthFunc(gl.ALWAYS);
+
+    debug(`Testing that rendering is ${hasAntialias ? 'antialiased' : 'aliased'}.`);
+    draw(gl, 3);
+    let N = 2;
+    let buf = new Uint8Array(N * N * 4);
+    gl.readPixels(0, 0, N, N, gl.RGBA, gl.UNSIGNED_BYTE, buf);
+    redChannels[0] = buf[4 * (N + 1)]; // (1, 1)
+    redChannels[1] = buf[4 * N * (N - 1)]; // left top
+    redChannels[2] = buf[4 * (N - 1)]; // right bottom
+    shouldBe("redChannels[1]", "255");
+    shouldBe("redChannels[2]", "0");
+    if (hasAntialias) {
+        shouldNotBe("redChannels[0]", "255");
+        shouldNotBe("redChannels[0]", "0");
+    } else {
+        shouldBeTrue("redChannels[0] == 255 || redChannels[0] == 0");
+    }
+    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT | gl.STENCIL_BUFFER_BIT);
+    wtu.checkCanvas(gl, black);
+
+    debug("Testing that rendering works.");
+    draw(gl);
+    wtu.checkCanvas(gl, red);
+    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT | gl.STENCIL_BUFFER_BIT);
+    wtu.checkCanvas(gl, black);
 }
 
 function testDefault()
@@ -130,199 +196,82 @@
     debug("Testing default attributes: { stencil:false }");
     shouldBeNonNull("gl = getWebGL(1, 1, null, [ 0, 0, 0, 0 ], 1, 0)");
     shouldBeFalse("gl.getContextAttributes().stencil");
-    shouldBeTrue("gl.getParameter(gl.STENCIL_BITS) == 0");
+    shouldBe("gl.getParameter(gl.STENCIL_BITS)", "0");
 }
 
-function testAlpha(alpha)
+function testAttributesAffectContext(alpha, stencil, depth, antialias)
 {
-    debug("Testing alpha = " + alpha);
-    if (alpha) {
-        shouldBeNonNull("gl = getWebGL(1, 1, { alpha: true, depth: false, stencil: false, antialias: false }, [ 0, 0, 0, 0 ], 1, 0)");
-        shouldBeTrue("gl.getParameter(gl.ALPHA_BITS) >= 8");
-    } else {
-        shouldBeNonNull("gl = getWebGL(1, 1, { alpha: false, depth: false, stencil: false, antialias: false }, [ 0, 0, 0, 0 ], 1, 0)");
-        shouldBeTrue("gl.getParameter(gl.ALPHA_BITS) == 0");
-    }
-    shouldBeTrue("gl.getParameter(gl.RED_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.GREEN_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.BLUE_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.DEPTH_BITS) == 0");
-    shouldBeTrue("gl.getParameter(gl.STENCIL_BITS) == 0");
-
+    shouldBeNonNull(`gl = getWebGL(2, 2, { depth: ${depth}, stencil: ${stencil}, antialias: ${antialias}, alpha: ${alpha} }, [ 0, 0, 0, 0 ], 1, 0)`);
     shouldBeNonNull("contextAttribs = gl.getContextAttributes()");
-    shouldBeTrue("contextAttribs.alpha == " + alpha);
 
-    var correctColor = (contextAttribs.alpha ? [0, 0, 0, 0] : [0, 0, 0, 255]);
-    wtu.checkCanvasRect(gl, 0, 0, 1, 1, correctColor);
+    shouldBeGreaterThanOrEqual("gl.getParameter(gl.RED_BITS)", "8");
+    shouldBeGreaterThanOrEqual("gl.getParameter(gl.GREEN_BITS)", "8");
+    shouldBeGreaterThanOrEqual("gl.getParameter(gl.BLUE_BITS)", "8");
+
+    shouldBe("contextAttribs.alpha", "" + alpha);
+    if (contextVersion < 2) {
+        if (!stencil)
+            shouldBeFalse("contextAttribs.stencil");
+        else
+            stencil = contextAttribs.stencil;
+        if (!depth)
+            shouldBeFalse("contextAttribs.depth");
+        else
+            depth = contextAttribs.depth;
+        if (!antialias)
+            shouldBeFalse("contextAttribs.antialias");
+        else
+            antialias = contextAttribs.antialias;
+    } else {
+        shouldBe("contextAttribs.stencil", "" + stencil);
+        shouldBe("contextAttribs.depth", "" + depth);
+        shouldBe("contextAttribs.antialias", "" + antialias);
+    }
+
+    if (alpha)
+        shouldBeGreaterThanOrEqual("gl.getParameter(gl.ALPHA_BITS)", "8");
+    else
+        shouldBe("gl.getParameter(gl.ALPHA_BITS)", "0");
+    if (stencil)
+        shouldBeGreaterThanOrEqual("gl.getParameter(gl.STENCIL_BITS)", "8");
+    else
+        shouldBe("gl.getParameter(gl.STENCIL_BITS)", "0");
+    if (depth)
+        shouldBeGreaterThanOrEqual("gl.getParameter(gl.DEPTH_BITS)", "16");
+    else
+        shouldBe("gl.getParameter(gl.DEPTH_BITS)", "0");
+
+    var correctColor = alpha ? [0, 0, 0, 0] : [0, 0, 0, 255];
+    wtu.checkCanvas(gl, correctColor);
+
+    debug("Testing default framebuffer.");
+    checkDraw(alpha, stencil, depth, antialias);
 
     if (fbHasColor) {
-      gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);
-      gl.clearColor(0.5, 0.5, 0.5, 0.5);
-      gl.clear(gl.COLOR_BUFFER_BIT);
-      wtu.checkCanvasRect(gl, 0, 0, 1, 1, [127, 127, 127, 127], undefined, 1);
-      gl.bindFramebuffer(gl.FRAMEBUFFER, null);
+        debug("Testing bound framebuffer object.");
+        gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);
+        gl.clearColor(0, 0, 0, 0);
+        gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT | gl.STENCIL_BUFFER_BIT);
+        checkDraw(true, fbHasStencil, fbHasDepth, false);
+        gl.bindFramebuffer(gl.FRAMEBUFFER, null);
     }
 }
 
-function testDepth(depth)
-{
-    debug("Testing depth = " + depth);
-    if (depth) {
-        shouldBeNonNull("gl = getWebGL(1, 1, { stencil: false, antialias: false }, [ 0, 0, 0, 1 ], 1, 0)");
-        shouldBeTrue("gl.getParameter(gl.DEPTH_BITS) >= 16");
-    } else {
-        shouldBeNonNull("gl = getWebGL(1, 1, { depth: false, stencil: false, antialias: false }, [ 0, 0, 0, 1 ], 1, 0)");
-        shouldBeTrue("gl.getParameter(gl.DEPTH_BITS) == 0");
-    }
-    shouldBeTrue("gl.getParameter(gl.RED_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.GREEN_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.BLUE_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.ALPHA_BITS) >= 8");
-
-    shouldBeNonNull("contextAttribs = gl.getContextAttributes()");
-
-    gl.depthFunc(gl.NEVER);
-
-    var vertices = new Float32Array([
-         1.0,  1.0, 0.0,
-        -1.0,  1.0, 0.0,
-        -1.0, -1.0, 0.0,
-         1.0,  1.0, 0.0,
-        -1.0, -1.0, 0.0,
-         1.0, -1.0, 0.0]);
-    var colors = new Uint8Array([
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255]);
-
-    drawAndReadPixel(gl, vertices, colors, 0, 0);
-    correctColor = (contextAttribs.depth ? [0, 0, 0, 255] : [255, 0, 0, 255]);
-    wtu.checkCanvasRect(gl, 0, 0, 1, 1, correctColor);
-
-    if (fbHasDepth) {
-      gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);
-      gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-      drawAndReadPixel(gl, vertices, colors, 0, 0);
-      wtu.checkCanvasRect(gl, 0, 0, 1, 1, [0, 0, 0, 255]);
-      gl.bindFramebuffer(gl.FRAMEBUFFER, null);
-    }
-}
-
-function testStencilAndDepth(stencil, depth)
-{
-    debug("Testing stencil = " + stencil + ", depth = " + depth);
-    var creationString =
-        "gl = getWebGL(1, 1, { depth: " + depth + ", stencil: " + stencil + ", antialias: false }, [ 0, 0, 0, 1 ], 1, 0)";
-    shouldBeNonNull(creationString);
-
-    shouldBeTrue("gl.getParameter(gl.RED_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.GREEN_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.BLUE_BITS) >= 8");
-    shouldBeTrue("gl.getParameter(gl.ALPHA_BITS) >= 8");
-    if (depth)
-        shouldBeTrue("gl.getParameter(gl.DEPTH_BITS) >= 16");
-    else
-        shouldBeTrue("gl.getParameter(gl.DEPTH_BITS) == 0");
-
-    if (stencil)
-        shouldBeTrue("gl.getParameter(gl.STENCIL_BITS) >= 8");
-    else
-        shouldBeTrue("gl.getParameter(gl.STENCIL_BITS) == 0");
-
-    shouldBeNonNull("contextAttribs = gl.getContextAttributes()");
-    if (!depth && contextAttribs.depth) {
-        testFailed("WebGL implementation provided a depth buffer when it should not have");
-    }
-    if (!contextAttribs.depth)
-        depth = false;
-    if (!stencil && contextAttribs.stencil) {
-        testFailed("WebGL implementation provided a stencil buffer when it should not have");
-    }
-    if (!contextAttribs.stencil)
-        stencil = false;
-
-    gl.depthFunc(gl.ALWAYS);
-
-    gl.stencilFunc(gl.NEVER, 1, 1);
-    gl.stencilOp(gl.KEEP, gl.KEEP, gl.KEEP);
-
-    var vertices = new Float32Array([
-         1.0, 1.0, 0.0,
-        -1.0, 1.0, 0.0,
-        -1.0, -1.0, 0.0,
-         1.0, 1.0, 0.0,
-        -1.0, -1.0, 0.0,
-         1.0, -1.0, 0.0]);
-    var colors = new Uint8Array([
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255]);
-
-    drawAndReadPixel(gl, vertices, colors, 0, 0);
-    correctColor = (stencil ? [0, 0, 0, 255] : [255, 0, 0, 255]);
-    wtu.checkCanvasRect(gl, 0, 0, 1, 1, correctColor)
-
-    if (fbHasStencil) {
-      gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);
-      gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-      drawAndReadPixel(gl, vertices, colors, 0, 0);
-      wtu.checkCanvasRect(gl, 0, 0, 1, 1, [0, 0, 0, 255]);
-      gl.bindFramebuffer(gl.FRAMEBUFFER, null);
-    }
-}
-
-function testAntialias(antialias)
-{
-    debug("Testing antialias = " + antialias);
-    // Both the width and height of canvas are N.
-    var N = 2;
-    if (antialias)
-        shouldBeNonNull("gl = getWebGL(" + N + ", " + N + ", { depth: false, stencil: false, alpha: false, antialias: true }, [ 0, 0, 0, 1 ], 1, 0)");
-    else
-        shouldBeNonNull("gl = getWebGL(" + N + ", " + N + ", { depth: false, stencil: false, alpha: false, antialias: false }, [ 0, 0, 0, 1 ], 1, 0)");
-    shouldBeNonNull("contextAttribs = gl.getContextAttributes()");
-
-    var vertices = new Float32Array([
-         1.0, 1.0, 0.0,
-        -1.0, 1.0, 0.0,
-        -1.0, -1.0, 0.0]);
-    var colors = new Uint8Array([
-        255, 0, 0, 255,
-        255, 0, 0, 255,
-        255, 0, 0, 255]);
-    drawAndReadPixel(gl, vertices, colors, 0, 0);
-    var buf = new Uint8Array(N * N * 4);
-    gl.readPixels(0, 0, N, N, gl.RGBA, gl.UNSIGNED_BYTE, buf);
-    redChannels[0] = buf[4 * (N + 1)]; // (1, 1)
-    redChannels[1] = buf[4 * N * (N - 1)]; // left top
-    redChannels[2] = buf[4 * (N - 1)]; // right bottom
-    shouldBeTrue("redChannels[1] == 255 && redChannels[2] == 0");
-    shouldBe("redChannels[0] != 255 && redChannels[0] != 0", "contextAttribs.antialias");
-}
-
 function runTest()
 {
     testDefault();
-    testAlpha(true);
-    testAlpha(false);
-    testDepth(true);
-    testDepth(false);
-    testStencilAndDepth(true, false);
-    testStencilAndDepth(false, false);
-    testStencilAndDepth(true, true);
-    testStencilAndDepth(false, true);
-    testAntialias(true);
-    testAntialias(false);
-
+    let cases = [false, true];
+    for (let alpha of cases) {
+        for (let stencil of cases) {
+            for (let depth of cases) {
+                for (let antialias of cases) {
+                    testAttributesAffectContext(alpha, stencil, depth, antialias);
+                }
+            }
+        }
+    }
     finishTest();
 }
-
 </script>
 </head>
 <body onload="init()">
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/context/methods.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/context/methods.html
index e5274fb..d1e47f3 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/context/methods.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/context/methods.html
@@ -11,6 +11,7 @@
 <link rel="stylesheet" href="../../resources/js-test-style.css"/>
 <script src="../../js/js-test-pre.js"></script>
 <script src="../../js/webgl-test-utils.js"></script>
+<script src="../../js/tests/context-methods.js"></script>
 </head>
 <body>
 <div id="description"></div>
@@ -20,7 +21,7 @@
 "use strict";
 description("This test ensures that the WebGL context has all the methods in the specification.");
 
-var methods = [
+const methods = [
   "getContextAttributes",
   "activeTexture",
   "attachShader",
@@ -159,55 +160,14 @@
   "viewport"
 ];
 
-// Properties to be ignored because they were added in versions of the
-// spec that are backward-compatible with this version
-var ignoredMethods = [
-  // There is no official spec for the commit API yet, the proposal link is:
-  // https://wiki.whatwg.org/wiki/OffscreenCanvas
-  "commit"
-];
-
-function assertFunction(v, f) {
-  try {
-    if (typeof v[f] != "function") {
-      testFailed("Property either does not exist or is not a function: " + f);
-      return false;
-    } else {
-      return true;
-    }
-  } catch(e) {
-    testFailed("Trying to access the property '" + f + "' threw an error: "+e.toString());
-  }
-}
-
 debug("");
 debug("Canvas.getContext");
 
-var wtu = WebGLTestUtils;
-var canvas = document.getElementById("canvas");
-var gl = wtu.create3DContext(canvas);
-var passed = true;
-for (var i=0; i<methods.length; i++) {
-  var r = assertFunction(gl, methods[i]);
-  passed = passed && r;
-}
-if (passed) {
-  testPassed("All WebGL methods found.");
-}
-var extended = false;
-for (var i in gl) {
-  if (typeof gl[i] == "function" && methods.indexOf(i) == -1 && ignoredMethods.indexOf(i) == -1) {
-    if (!extended) {
-      extended = true;
-      testFailed("Also found the following extra methods:");
-    }
-    testFailed(i);
-  }
-}
+const wtu = WebGLTestUtils;
+const canvas = document.getElementById("canvas");
+const gl = wtu.create3DContext(canvas);
 
-if (!extended) {
-  testPassed("No extra methods found on WebGL context.");
-}
+testContextMethods(gl, methods);
 
 debug("");
 var successfullyParsed = true;
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-bptc.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-bptc.html
index 1fed9d9..0bce737 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-bptc.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-bptc.html
@@ -60,7 +60,7 @@
   // * <height> is not a multiple of four, and <height> plus <yoffset> is
   //           not equal to TEXTURE_HEIGHT; or
   // * <xoffset> or <yoffset> is not a multiple of four.
-  ctu.testTexSubImageDimensions(gl, validFormats, expectedByteLength, getBlockDimensions,
+  ctu.testTexSubImageDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
     16, 16, [
       { xoffset: 0, yoffset: 0, width: 4, height: 3,
         expectation: gl.INVALID_OPERATION, message: "height is not a multiple of 4" },
@@ -77,7 +77,17 @@
   // Test TexImage validation on level dimensions combinations.
   // When level equals 0, width and height must be a multiple of 4.
   // When level is larger than 0, this constraint doesn't apply.
-  ctu.testTexImageLevelDimensions(gl, validFormats, expectedByteLength, getBlockDimensions,
+
+  let npotExpectation, npotMessage;
+  if (contextVersion >= 2) {
+    npotExpectation = gl.NO_ERROR;
+    npotMessage = "valid";
+  } else {
+    npotExpectation = gl.INVALID_VALUE;
+    npotMessage = "invalid";
+  }
+
+  ctu.testTexImageLevelDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
     [
       { level: 0, width: 4, height: 3,
         expectation: gl.INVALID_OPERATION, message: "level is 0, height is not a multiple of 4" },
@@ -87,10 +97,16 @@
         expectation: gl.INVALID_OPERATION, message: "level is 0, width is not a multiple of 4" },
       { level: 0, width: 4, height: 4,
         expectation: gl.NO_ERROR, message: "is valid" },
+      { level: 1, width: 1, height: 1,
+        expectation: gl.INVALID_OPERATION, message: "implied base mip 2x2 is invalid" },
+      { level: 1, width: 1, height: 2,
+        expectation: gl.INVALID_OPERATION, message: "implied base mip 2x4 is invalid" },
+      { level: 1, width: 2, height: 1,
+        expectation: gl.INVALID_OPERATION, message: "implied base mip 4x2 is invalid" },
       { level: 1, width: 2, height: 2,
-        expectation: gl.NO_ERROR, message: "level > 0, is valid" },
-      { level: 2, width: 1, height: 1,
-        expectation: gl.NO_ERROR, message: "level > 0, is valid" },
+        expectation: gl.NO_ERROR, message: "implied base mip 4x4 is valid" },
+      { level: 2, width: 1, height: 3,
+        expectation: npotExpectation, message: "implied base mip 4x12 is " + npotMessage },
   ]);
 
   // Test that BPTC enums are not accepted by texImage2D
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-rgtc.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-rgtc.html
index c2a2d41..70dcf9b 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-rgtc.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/ext-texture-compression-rgtc.html
@@ -65,7 +65,7 @@
   // * <height> is not a multiple of four, and <height> plus <yoffset> is
   //           not equal to TEXTURE_HEIGHT; or
   // * <xoffset> or <yoffset> is not a multiple of four.
-  ctu.testTexSubImageDimensions(gl, validFormats, expectedByteLength, getBlockDimensions,
+  ctu.testTexSubImageDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
     16, 16, [
       { xoffset: 0, yoffset: 0, width: 4, height: 3,
         expectation: gl.INVALID_OPERATION, message: "height is not a multiple of 4" },
@@ -82,7 +82,17 @@
   // Test TexImage validation on level dimensions combinations.
   // When level equals 0, width and height must be a multiple of 4.
   // When level is larger than 0, this constraint doesn't apply.
-  ctu.testTexImageLevelDimensions(gl, validFormats, expectedByteLength, getBlockDimensions,
+
+  let npotExpectation, npotMessage;
+  if (contextVersion >= 2) {
+    npotExpectation = gl.NO_ERROR;
+    npotMessage = "valid";
+  } else {
+    npotExpectation = gl.INVALID_VALUE;
+    npotMessage = "invalid";
+  }
+
+  ctu.testTexImageLevelDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
     [
       { level: 0, width: 4, height: 3,
         expectation: gl.INVALID_OPERATION, message: "level is 0, height is not a multiple of 4" },
@@ -92,10 +102,16 @@
         expectation: gl.INVALID_OPERATION, message: "level is 0, width is not a multiple of 4" },
       { level: 0, width: 4, height: 4,
         expectation: gl.NO_ERROR, message: "is valid" },
+      { level: 1, width: 1, height: 1,
+        expectation: gl.INVALID_OPERATION, message: "implied base mip 2x2 is invalid" },
+      { level: 1, width: 1, height: 2,
+        expectation: gl.INVALID_OPERATION, message: "implied base mip 2x4 is invalid" },
+      { level: 1, width: 2, height: 1,
+        expectation: gl.INVALID_OPERATION, message: "implied base mip 4x2 is invalid" },
       { level: 1, width: 2, height: 2,
-        expectation: gl.NO_ERROR, message: "level > 0, is valid" },
-      { level: 2, width: 1, height: 1,
-        expectation: gl.NO_ERROR, message: "level > 0, is valid" },
+        expectation: gl.NO_ERROR, message: "implied base mip 4x4 is valid" },
+      { level: 2, width: 1, height: 3,
+        expectation: npotExpectation, message: "implied base mip 4x12 is " + npotMessage },
   ]);
 
   // Test that RGTC enums are not accepted by texImage2D
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/s3tc-and-rgtc.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/s3tc-and-rgtc.html
index addde54..3b725ffe 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/s3tc-and-rgtc.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/s3tc-and-rgtc.html
@@ -39,6 +39,11 @@
 
 debug("");
 
+// Acceptable interpolation error depends on endpoints:
+// 1.0 / 255.0 + 0.03 * max(abs(endpoint0 - endpoint1), abs(endpoint0_p - endpoint1_p))
+// For simplicity, assume the worst case (e0 is 0.0, e1 is 1.0). After conversion to unorm8, it is 9.
+const DEFAULT_COLOR_ERROR = 9;
+
 /*
 BC1 (DXT1) block
 e0 = [  0, 255, 0]
@@ -267,6 +272,87 @@
     if (contextVersion >= 2) {
         testDXT5_RGBA_PBO();
     }
+
+    // Test TexImage validation on level dimensions combinations.
+    debug("");
+    debug("When level equals 0, width and height must be a multiple of 4.");
+    debug("When level is larger than 0, this constraint doesn't apply.");
+    ctu.testTexImageLevelDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
+      [
+        { level: 0, width: 4, height: 3, expectation: gl.INVALID_OPERATION, message: "0: 4x3" },
+        { level: 0, width: 3, height: 4, expectation: gl.INVALID_OPERATION, message: "0: 3x4" },
+        { level: 0, width: 2, height: 2, expectation: gl.INVALID_OPERATION, message: "0: 2x2" },
+        { level: 0, width: 4, height: 4, expectation: gl.NO_ERROR, message: "0: 4x4" },
+        { level: 1, width: 2, height: 2, expectation: gl.NO_ERROR, message: "1: 2x2" },
+        { level: 2, width: 1, height: 1, expectation: gl.NO_ERROR, message: "2: 1x1" },
+    ]);
+
+    ctu.testTexSubImageDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions, 16, 16,
+      [
+        { xoffset: 0, yoffset: 0, width: 4, height: 3,
+          expectation: gl.INVALID_OPERATION, message: "height is not a multiple of 4" },
+        { xoffset: 0, yoffset: 0, width: 3, height: 4,
+          expectation: gl.INVALID_OPERATION, message: "width is not a multiple of 4" },
+        { xoffset: 1, yoffset: 0, width: 4, height: 4,
+          expectation: gl.INVALID_OPERATION, message: "xoffset is not a multiple of 4" },
+        { xoffset: 0, yoffset: 1, width: 4, height: 4,
+          expectation: gl.INVALID_OPERATION, message: "yoffset is not a multiple of 4" },
+        { xoffset: 12, yoffset: 12, width: 4, height: 4,
+          expectation: gl.NO_ERROR, message: "is valid" },
+    ]);
+
+    if (contextVersion >= 2) {
+        debug("");
+        debug("Testing NPOT textures");
+        ctu.testTexImageLevelDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
+          [
+            { level: 0, width: 0, height: 0, expectation: gl.NO_ERROR, message: "0: 0x0 is valid" },
+            { level: 0, width: 1, height: 1, expectation: gl.INVALID_OPERATION, message: "0: 1x1 is invalid" },
+            { level: 0, width: 2, height: 2, expectation: gl.INVALID_OPERATION, message: "0: 2x2 is invalid" },
+            { level: 0, width: 3, height: 3, expectation: gl.INVALID_OPERATION, message: "0: 3x3 is invalid" },
+            { level: 0, width: 10, height: 10, expectation: gl.INVALID_OPERATION, message: "0: 10x10 is invalid" },
+            { level: 0, width: 11, height: 11, expectation: gl.INVALID_OPERATION, message: "0: 11x11 is invalid" },
+            { level: 0, width: 11, height: 12, expectation: gl.INVALID_OPERATION, message: "0: 11x12 is invalid" },
+            { level: 0, width: 12, height: 11, expectation: gl.INVALID_OPERATION, message: "0: 12x11 is invalid" },
+            { level: 0, width: 12, height: 12, expectation: gl.NO_ERROR, message: "0: 12x12 is valid" },
+            { level: 1, width:  0, height:  0, expectation: gl.NO_ERROR, message: "1: 0x0, is valid" },
+            { level: 1, width:  3, height:  3, expectation: gl.INVALID_OPERATION, message: "1: 3x3, is invalid" },
+            { level: 1, width:  5, height:  5, expectation: gl.INVALID_OPERATION, message: "1: 5x5, is invalid" },
+            { level: 1, width:  5, height:  6, expectation: gl.INVALID_OPERATION, message: "1: 5x6, is invalid" },
+            { level: 1, width:  6, height:  5, expectation: gl.INVALID_OPERATION, message: "1: 6x5, is invalid" },
+            { level: 1, width:  6, height:  6, expectation: gl.NO_ERROR, message: "1: 6x6, is valid" },
+            { level: 2, width:  0, height:  0, expectation: gl.NO_ERROR, message: "2: 0x0, is valid" },
+            { level: 2, width:  3, height:  3, expectation: gl.NO_ERROR, message: "2: 3x3, is valid" },
+            { level: 3, width:  1, height:  3, expectation: gl.NO_ERROR, message: "3: 1x3, is valid" },
+            { level: 3, width:  1, height:  1, expectation: gl.NO_ERROR, message: "3: 1x1, is valid" },
+        ]);
+
+        debug("");
+        debug("Testing partial updates");
+        ctu.testTexSubImageDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions, 12, 12,
+        [
+          { xoffset: 0, yoffset: 0, width: 4, height: 3,
+            expectation: gl.INVALID_OPERATION, message: "height is not a multiple of 4" },
+          { xoffset: 0, yoffset: 0, width: 3, height: 4,
+            expectation: gl.INVALID_OPERATION, message: "width is not a multiple of 4" },
+          { xoffset: 1, yoffset: 0, width: 4, height: 4,
+            expectation: gl.INVALID_OPERATION, message: "xoffset is not a multiple of 4" },
+          { xoffset: 0, yoffset: 1, width: 4, height: 4,
+            expectation: gl.INVALID_OPERATION, message: "yoffset is not a multiple of 4" },
+          { xoffset: 8, yoffset: 8, width: 4, height: 4,
+            expectation: gl.NO_ERROR, message: "is valid" },
+        ]);
+
+        debug("");
+        debug("Testing immutable NPOT textures");
+        ctu.testTexStorageLevelDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
+          [
+            { width: 12, height: 12, expectation: gl.NO_ERROR, message: "0: 12x12 is valid" },
+            { width:  6, height:  6, expectation: gl.NO_ERROR, message: "1: 6x6, is valid" },
+            { width:  3, height:  3, expectation: gl.NO_ERROR, message: "2: 3x3, is valid" },
+            { width:  1, height:  1, expectation: gl.NO_ERROR, message: "3: 1x1, is valid" },
+        ]);
+    }
 }
 
 function runTestRGTC() {
@@ -298,6 +384,8 @@
             data: img_4x4_signed_rg_bc5,
             format: ext_rgtc.COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT,
             hasAlpha: false,
+            error: 18, // Signed, so twice the normal error.
+                       // Experimentally needed by e.g. RTX 3070.
         },
         {   width: 8,
             height: 8,
@@ -474,10 +562,13 @@
          format == ext_rgtc.COMPRESSED_RED_GREEN_RGTC2_EXT ||
          format == ext_rgtc.COMPRESSED_SIGNED_RED_RGTC1_EXT ||
          format == ext_rgtc.COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT);
+    let colorOffset = srcOffset;
     if (!isBC45) {
         var isDXT1 = format == ext.COMPRESSED_RGB_S3TC_DXT1_EXT ||
                      format == ext.COMPRESSED_RGBA_S3TC_DXT1_EXT;
-        var colorOffset = srcOffset + (isDXT1 ? 0 : 8);
+        if (!isDXT1) {
+            colorOffset += 8;
+        }
         var color0 = make565(src, colorOffset + 0);
         var color1 = make565(src, colorOffset + 2);
         var c0gtc1 = color0 > color1 || !isDXT1;
@@ -658,6 +749,8 @@
 }
 
 function testDXTTexture(test, useTexStorage) {
+    test.error = test.error || DEFAULT_COLOR_ERROR;
+
     var data = new Uint8Array(test.data);
     var width = test.width;
     var height = test.height;
@@ -696,7 +789,7 @@
 
             wtu.clearAndDrawUnitQuad(gl);
             wtu.glErrorShouldBe(gl, gl.NO_ERROR, "drawing unit quad 1");
-            compareRect(width, height, test.channels, uncompressedDataSub, "NEAREST");
+            compareRect(width, height, test.channels, uncompressedDataSub, "NEAREST", test.error);
 
             // Clean up and recover
             gl.deleteTexture(tex1);
@@ -720,13 +813,13 @@
     wtu.glErrorShouldBe(gl, gl.NO_ERROR, "after clearing generateMipmap error");
     wtu.clearAndDrawUnitQuad(gl);
     wtu.glErrorShouldBe(gl, gl.NO_ERROR, "drawing unit quad 1");
-    compareRect(width, height, test.channels, uncompressedData, "NEAREST");
+    compareRect(width, height, test.channels, uncompressedData, "NEAREST", test.error);
     // Test again with linear filtering.
     gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
     gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
     wtu.clearAndDrawUnitQuad(gl);
     wtu.glErrorShouldBe(gl, gl.NO_ERROR, "drawing unit quad 2");
-    compareRect(width, height, test.channels, uncompressedData, "LINEAR");
+    compareRect(width, height, test.channels, uncompressedData, "LINEAR", test.error);
 
     if (!useTexStorage) {
         // It's not allowed to redefine textures defined via texStorage2D.
@@ -752,12 +845,14 @@
         wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
 
         if (width == 4) {
+            // The width/height of the implied base level must be a multiple of the block size.
             gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, 1, height, 0, data);
             wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions for level > 0");
             gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, 2, height, 0, data);
             wtu.glErrorShouldBe(gl, gl.NO_ERROR, "valid dimensions for level > 0");
         }
         if (height == 4) {
+            // The width/height of the implied base level must be a multiple of the block size.
             gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, width, 1, 0, data);
             wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions for level > 0");
             gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, width, 2, 0, data);
@@ -835,14 +930,14 @@
             gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
             gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
             wtu.clearAndDrawUnitQuad(gl);
-            compareRect(width, height, test.channels, uncompressedData, "NEAREST");
+            compareRect(width, height, test.channels, uncompressedData, "NEAREST", test.error);
             wtu.glErrorShouldBe(gl, gl.NO_ERROR, "drawing unit quad");
             // Next test LINEAR filtering.
             gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
             gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
             wtu.clearAndDrawUnitQuad(gl);
             wtu.glErrorShouldBe(gl, gl.NO_ERROR, "drawing unit quad");
-            compareRect(width, height, test.channels, uncompressedData, "LINEAR");
+            compareRect(width, height, test.channels, uncompressedData, "LINEAR", test.error);
         }
     }
 }
@@ -873,7 +968,7 @@
     gl.bindBuffer(gl.PIXEL_UNPACK_BUFFER, null);
     wtu.clearAndDrawUnitQuad(gl);
     wtu.glErrorShouldBe(gl, gl.NO_ERROR, "drawing unit quad");
-    compareRect(width, height, channels, uncompressedData, "NEAREST");
+    compareRect(width, height, channels, uncompressedData, "NEAREST", DEFAULT_COLOR_ERROR);
 
     // Clear the texture before the next test
     gl.bindBuffer(gl.PIXEL_UNPACK_BUFFER, null);
@@ -890,10 +985,10 @@
     gl.bindBuffer(gl.PIXEL_UNPACK_BUFFER, null);
     wtu.clearAndDrawUnitQuad(gl);
     wtu.glErrorShouldBe(gl, gl.NO_ERROR, "drawing unit quad");
-    compareRect(width, height, channels, uncompressedData, "NEAREST");
+    compareRect(width, height, channels, uncompressedData, "NEAREST", DEFAULT_COLOR_ERROR);
 }
 
-function compareRect(width, height, channels, expectedData, filteringMode) {
+function compareRect(width, height, channels, expectedData, filteringMode, colorError) {
     var actual = new Uint8Array(width * height * 4);
     gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, actual);
     wtu.glErrorShouldBe(gl, gl.NO_ERROR, "reading back pixels");
@@ -910,19 +1005,15 @@
         for (var xx = 0; xx < width; ++xx) {
             var offset = (yy * width + xx) * 4;
             var expected = expectedData.slice(offset, offset + 4);
+            const was = actual.slice(offset, offset + 4);
+
             // Compare RGB values
             for (var jj = 0; jj < 3; ++jj) {
-                // Acceptable interpolation error depends on endpoints:
-                // 1.0 / 255.0 + 0.03 * max(abs(endpoint0 - endpoint1), abs(endpoint0_p - endpoint1_p))
-                // For simplicity, assume the worst case (e0 is 0.0, e1 is 1.0). After conversion to unorm8, it is 9.
-                if (Math.abs(actual[offset + jj] - expected[jj]) > 9) {
-                    var was = actual[offset + 0].toString();
-                    for (var j = 1; j < 3; ++j) {
-                        was += "," + actual[offset + j];
-                    }
+                if (Math.abs(was[jj] - expected[jj]) > colorError) {
                     failed = true;
-                    testFailed('RGB at (' + xx + ', ' + yy +
-                                        ') expected: ' + expected + ' ± 9 was ' + was);
+                    testFailed(`RGB at (${xx}, ${yy}) expected: ${expected}` +
+                               ` +/- ${colorError}, was ${was}`);
+                    break;
                 }
             }
 
@@ -937,15 +1028,15 @@
                     // Check RGB values. Notice, that the condition here
                     // is more permissive than needed since we don't have
                     // compressed data at this point.
-                    if (actual[offset] == 0 &&
-                        actual[offset + 1] == 0 &&
-                        actual[offset + 2] == 0 &&
-                        actual[offset + 3] == 0) {
+                    if (was[0] == 0 &&
+                        was[1] == 0 &&
+                        was[2] == 0 &&
+                        was[3] == 0) {
                             debug("<b>DXT1 RGB is mapped to DXT1 RGBA</b>");
                     } else {
                         failed = true;
                         testFailed('Alpha at (' + xx + ', ' + yy +
-                                              ') expected: ' + expected[3] + ' was ' + actual[offset + 3]);
+                                              ') expected: ' + expected[3] + ' was ' + was);
                     }
                 }
             } else {
@@ -953,11 +1044,10 @@
                 // Acceptable interpolation error depends on endpoints:
                 // 1.0 / 65535.0 + 0.03 * max(abs(endpoint0 - endpoint1), abs(endpoint0_p - endpoint1_p))
                 // For simplicity, assume the worst case (e0 is 0.0, e1 is 1.0). After conversion to unorm8, it is 8.
-                if (Math.abs(actual[offset + 3] - expected[3]) > 8) {
-                    var was = actual[offset + 3].toString();
+                if (Math.abs(was[3] - expected[3]) > 8) {
                     failed = true;
                     testFailed('Alpha at (' + xx + ', ' + yy +
-                                          ') expected: ' + expected + ' ± 8 was ' + was);
+                                          ') expected: ' + expected + ' +/- 8 was ' + was);
                 }
             }
         }
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/webgl-compressed-texture-s3tc-srgb.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/webgl-compressed-texture-s3tc-srgb.html
index a1a21ab..91fc3f0 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/webgl-compressed-texture-s3tc-srgb.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/webgl-compressed-texture-s3tc-srgb.html
@@ -226,6 +226,72 @@
     if (contextVersion >= 2) {
         testDXT5_SRGB_ALPHA_PBO();
     }
+
+    // Test TexImage validation on level dimensions combinations.
+    debug("");
+    debug("When level equals 0, width and height must be a multiple of 4.");
+    debug("When level is larger than 0, this constraint doesn't apply.");
+    ctu.testTexImageLevelDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
+      [
+        { level: 0, width: 4, height: 3, expectation: gl.INVALID_OPERATION, message: "0: 4x3" },
+        { level: 0, width: 3, height: 4, expectation: gl.INVALID_OPERATION, message: "0: 3x4" },
+        { level: 0, width: 2, height: 2, expectation: gl.INVALID_OPERATION, message: "0: 2x2" },
+        { level: 0, width: 4, height: 4, expectation: gl.NO_ERROR, message: "0: 4x4" },
+        { level: 1, width: 2, height: 2, expectation: gl.NO_ERROR, message: "1: 2x2" },
+        { level: 2, width: 1, height: 1, expectation: gl.NO_ERROR, message: "2: 1x1" },
+    ]);
+
+    ctu.testTexSubImageDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions, 16, 16,
+      [
+        { xoffset: 0, yoffset: 0, width: 4, height: 3,
+          expectation: gl.INVALID_OPERATION, message: "height is not a multiple of 4" },
+        { xoffset: 0, yoffset: 0, width: 3, height: 4,
+          expectation: gl.INVALID_OPERATION, message: "width is not a multiple of 4" },
+        { xoffset: 1, yoffset: 0, width: 4, height: 4,
+          expectation: gl.INVALID_OPERATION, message: "xoffset is not a multiple of 4" },
+        { xoffset: 0, yoffset: 1, width: 4, height: 4,
+          expectation: gl.INVALID_OPERATION, message: "yoffset is not a multiple of 4" },
+        { xoffset: 12, yoffset: 12, width: 4, height: 4,
+          expectation: gl.NO_ERROR, message: "is valid" },
+    ]);
+
+    if (contextVersion >= 2) {
+        debug("");
+        debug("Testing NPOT textures");
+        ctu.testTexImageLevelDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
+          [
+            { level: 0, width: 12, height: 12, expectation: gl.NO_ERROR, message: "0: 12x12 is valid" },
+            { level: 1, width:  6, height:  6, expectation: gl.NO_ERROR, message: "1: 6x6, is valid" },
+            { level: 2, width:  3, height:  3, expectation: gl.NO_ERROR, message: "2: 3x3, is valid" },
+            { level: 3, width:  1, height:  1, expectation: gl.NO_ERROR, message: "3: 1x1, is valid" },
+        ]);
+
+        debug("");
+        debug("Testing partial updates");
+        ctu.testTexSubImageDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions, 12, 12,
+        [
+          { xoffset: 0, yoffset: 0, width: 4, height: 3,
+            expectation: gl.INVALID_OPERATION, message: "height is not a multiple of 4" },
+          { xoffset: 0, yoffset: 0, width: 3, height: 4,
+            expectation: gl.INVALID_OPERATION, message: "width is not a multiple of 4" },
+          { xoffset: 1, yoffset: 0, width: 4, height: 4,
+            expectation: gl.INVALID_OPERATION, message: "xoffset is not a multiple of 4" },
+          { xoffset: 0, yoffset: 1, width: 4, height: 4,
+            expectation: gl.INVALID_OPERATION, message: "yoffset is not a multiple of 4" },
+          { xoffset: 8, yoffset: 8, width: 4, height: 4,
+            expectation: gl.NO_ERROR, message: "is valid" },
+        ]);
+
+        debug("");
+        debug("Testing immutable NPOT textures");
+        ctu.testTexStorageLevelDimensions(gl, ext, validFormats, expectedByteLength, getBlockDimensions,
+          [
+            { width: 12, height: 12, expectation: gl.NO_ERROR, message: "0: 12x12 is valid" },
+            { width:  6, height:  6, expectation: gl.NO_ERROR, message: "1: 6x6, is valid" },
+            { width:  3, height:  3, expectation: gl.NO_ERROR, message: "2: 3x3, is valid" },
+            { width:  1, height:  1, expectation: gl.NO_ERROR, message: "3: 1x1, is valid" },
+        ]);
+    }
 }
 
 function testDXT1_SRGB() {
@@ -617,12 +683,14 @@
         wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
 
         if (width == 4) {
+            // The width/height of the implied base level must be a multiple of the block size.
             gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, 1, height, 0, data);
             wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions for level > 0");
             gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, 2, height, 0, data);
             wtu.glErrorShouldBe(gl, gl.NO_ERROR, "valid dimensions for level > 0");
         }
         if (height == 4) {
+            // The width/height of the implied base level must be a multiple of the block size.
             gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, width, 1, 0, data);
             wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions for level > 0");
             gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, width, 2, 0, data);
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/webgl-multi-draw.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/webgl-multi-draw.html
index adeab31..426e463 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/webgl-multi-draw.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/extensions/webgl-multi-draw.html
@@ -371,7 +371,7 @@
     wtu.checkCanvas(gl, [0, 255, 0, 255], "gl_DrawID is 0 for non-Multi* draw calls", 0);
   }
 
-  function runPixelTests(bufferUsage) {
+  function runPixelTests(bufferUsage, useSharedArrayBuffer) {
     // An array of quads is tiled across the screen.
     // gl_DrawID is checked by using it to select the color of the draw.
     // Instanced entrypoints are tested here scaling and then instancing the
@@ -506,10 +506,18 @@
       wtu.checkCanvasRects(gl, rects);
     }
 
-    const firsts = new Uint32Array(tri_count);
-    const counts = new Uint32Array(tri_count);
-    const offsets = new Uint32Array(tri_count);
-    const instances = new Uint32Array(tri_count);
+    function newIntArray(count) {
+      if (!useSharedArrayBuffer) {
+        return new Int32Array(count);
+      }
+      let sab = new SharedArrayBuffer(count * Int32Array.BYTES_PER_ELEMENT);
+      return new Int32Array(sab);
+    }
+
+    const firsts = newIntArray(tri_count);
+    const counts = newIntArray(tri_count);
+    const offsets = newIntArray(tri_count);
+    const instances = newIntArray(tri_count);
 
     for (let i = 0; i < firsts.length; ++i) firsts[i] = i * 3;
     counts.fill(3);
@@ -521,7 +529,7 @@
     const offsetsOffset = countsOffset + counts.length;
     const instancesOffset = offsetsOffset + instances.length;
 
-    const buffer = new Uint32Array(firstsOffset + firsts.length + counts.length + offsets.length + instances.length);
+    const buffer = newIntArray(firstsOffset + firsts.length + counts.length + offsets.length + instances.length);
     buffer.set(firsts, firstsOffset);
     buffer.set(counts, countsOffset);
     buffer.set(offsets, offsetsOffset);
@@ -664,6 +672,8 @@
         config.instanced ? ' instanced' : ''
       ) + (
         config.drawID ? ' with gl_DrawID' : ''
+      ) + (
+        useSharedArrayBuffer ? ' and SharedArrayBuffer' : ''
       ));
 
       gl.disableVertexAttribArray(0);
@@ -827,7 +837,12 @@
     debug("Testing with BufferUsage = " + bufferUsage);
     runValidationTests(bufferUsage);
     runShaderTests(bufferUsage);
-    runPixelTests(bufferUsage);
+    runPixelTests(bufferUsage, false);
+  }
+
+  // Run a subset of the pixel tests with SharedArrayBuffer if supported.
+  if (window.SharedArrayBuffer) {
+    runPixelTests(bufferUsageSet[0], true);
   }
 }
 
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/glsl/bugs/character-set.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/glsl/bugs/character-set.html
index 1ba8546..6d6fca5 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/glsl/bugs/character-set.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/glsl/bugs/character-set.html
@@ -111,7 +111,5 @@
 var successfullyParsed = true;
 
 </script>
-<script src="../../../js/js-test-post.js"></script>
-
 </body>
 </html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/glsl/constructors/glsl-construct-vec-mat-index.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/glsl/constructors/glsl-construct-vec-mat-index.html
index 8a9fbeb..084d532 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/glsl/constructors/glsl-construct-vec-mat-index.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/glsl/constructors/glsl-construct-vec-mat-index.html
@@ -49,6 +49,5 @@
 GLSLConformanceTester.runRenderTest();
 var successfullyParsed = true;
 </script>
-<script src="../../../js/js-test-post.js"></script>
 </body>
 </html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Data_Types_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Data_Types_frag.frag
new file mode 100644
index 0000000..4f31090
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Data_Types_frag.frag
@@ -0,0 +1,28 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+	half h1; // Not a basic type.
+	half2 h2; // Not a basic type.
+	half3 h3; // Not a basic type.
+	half4 h4; // Not a basic type.
+	float2 f2; // Not a basic type.
+	float3 f3; // Not a basic type.
+	float4 f4; // Not a basic type.
+	fixed fx1; // Not a basic type.
+	fixed2 fx2; // Not a basic type.
+	fixed3 fx3; // Not a basic type.
+	fixed4 fx4; // Not a basic type.
+	float3x3 f3x3; // Not a basic type.
+	float2x4 f2x4; // Not a basic type.
+	half4x4 h4x4; // Not a basic type.
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Standard_Library_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Standard_Library_frag.frag
new file mode 100644
index 0000000..392680e
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CG_Standard_Library_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+	int i = round(1.3); // round is not a built-in function.
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectBuiltInOveride_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectBuiltInOveride_frag.frag
new file mode 100644
index 0000000..07ba3ef
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectBuiltInOveride_frag.frag
@@ -0,0 +1,22 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump int;
+#endif
+
+int radians(int f)
+{
+    return f;
+}
+
+void main()
+{
+    int f = 45;
+    f = radians(f);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectComma_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectComma_frag.frag
new file mode 100644
index 0000000..8b671d7
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectComma_frag.frag
@@ -0,0 +1,22 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    float f;
+    vec3 v;
+};
+
+void main()
+{
+    const vec4 v = (vec4(1,2,3,4), vec4(5,6,7,8));  // 5,6,7,8
+    const s s1 = (s(9.0, vec3(10,11,12)), s(13.0, vec3(14,15,16))); // 13,14,15,16
+    gl_FragColor = v + vec4(s1.f, s1.v);  // 18, 20, 22, 24
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding1_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding1_vert.vert
new file mode 100644
index 0000000..89a3bc5
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding1_vert.vert
@@ -0,0 +1,36 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+
+   const struct s2 {
+       int i;
+       vec3 v3;
+       bvec4 bv4;
+   } s22  = s2(8, vec3(9, 10, 11), bvec4(true, false, true, false));
+
+   struct s4 {
+       int ii;
+       vec4 v4;
+      };
+
+   const struct s1 {
+      s2 ss;
+      int i;
+      float f;
+      mat4 m;
+ 	s4 s44;
+   } s11 = s1(s22, 2, 4.0, mat4(5), s4(6, vec4(7, 8, 9, 10))) ;
+
+  const int field3 = s11.i * s11.ss.i;  // constant folding (int * int)
+  const vec4 field4 = s11.s44.v4 * s11.s44.v4; // constant folding (vec4 * vec4)
+ // 49, 64, 81, 100
+  const vec4 v4 = vec4(s11.ss.v3.y, s11.m[3][3], field3, field4[2]);  // 10.0, 5.0, 16.0, 81.0
+  gl_Position = v4;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding2_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding2_vert.vert
new file mode 100644
index 0000000..55c1367
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstFolding2_vert.vert
@@ -0,0 +1,421 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    struct s5 {
+    float k;
+    };
+    const struct s {
+        int i;
+    	float j;
+      s5 s55;
+    } ss = s(4,1.0, s5(1.0));
+
+
+   const struct s2 {
+       int i;
+       vec3 v3;
+       bvec4 bv4;
+   } s22  = s2(8, vec3(9, 10, 11), bvec4(true, false, true, false));
+
+  struct s4 {
+          int ii;
+          vec4 v4;
+      };
+
+   const struct s1 {
+      s2 ss;
+      int i;
+      float f;
+      mat4 m;
+      s4 s44;
+     } s11 = s1(s22, 2, 4.0, mat4(5), s4(6, vec4(7, 8, 9, 10))) ;
+
+
+   const struct s7 {
+       int i;
+       mat3 m3;
+   } s77 = s7(12, mat3(15));
+
+  vec2       v21 = vec2(1);  // Not a constant
+  const vec2 v22 = vec2(11); // 11.0, 11.0
+  const vec4 v41 = vec4(2);  // 2.0, 2.0, 2.0, 2.0
+  const vec4 v43 = vec4(4,4,4,4); // 4.0, 4.0, 4.0, 4.0
+  const vec4 v44 = vec4(5.0, 5.0, 5.0, 5.0); // 5.0, 5.0, 5.0, 5.0
+  const vec4 v45 = vec4(v22, v22);  // 11.0, 11.0, 11.0, 11.0
+  const vec4 v46 = vec4(vec2(20, 21), vec2(22, 23));  // 20.0, 21.0, 22.0, 23.0
+
+  const vec3 v31 = vec3(s22.v3);  // 9.0, 10.0, 11.0
+  const vec3 v32 = vec3(s77.m3);  // 15.0, 0, 0
+  const vec3 v33 = vec3(s77.m3[2]); // 0, 0, 15.0
+  const vec3 v34 = vec3(s77.m3[2][0]);  // 0,0,0
+
+
+  const mat4 m41 = mat4(1);  // 1,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1
+  const mat4 m42 = mat4(v44, v44, v44, v44);  // all 5s
+  const mat4 m43 = mat4( v43.x);  // 4,0,0,0,0,4,0,0,0,0,0,4,0,0,0,0,0,4
+
+  const vec4 v47 = vec4(m41[0][0]);  // 1.0,1.0,1.0,1.0
+
+  const mat4 m45 = mat4(s22.v3, v44, v45, v32, 50, 52);  //9,10,11,5,5,5,5,11,11,11,11,15.0, 0,0, 50.0, 52.0
+  //const mat3 m31 = mat3(1, mat2(1), 2.0, vec3(1));  // 1.0, 1,0,0,1,2,1,1,1
+  const vec4 v48 = vec4(v31[0], v22[1], v41[0], v43[3]);  //9, 11, 2, 4
+  const vec4 v49 = vec4(s22.v3.xy, s22.v3.zx); // 9,10,11,9
+  const vec4 v410 = vec4(v44.xy, v43.zx);  //5,5,4,4
+
+  const vec4 v411 = vec4(m42[3]);  // 5,5,5,5
+  const vec4 v412 = vec4(m43[2]);  // 0,0,4,0
+
+  const vec2 v23 = vec2(m41);  // 1,0
+
+  const vec2 v24 = vec2(33, s11.i);  // 33, 2
+
+  const vec4 v413 = vec4(vec2(1.0,2.0),ivec2(3.0,4.0));  // 1,2,3,4
+  const ivec4 i41 = ivec4(1.0, 2.0, 3.0, 4.0);  // 1,2,3,4
+
+  const ivec4 i42 = ivec4(6);  // 6,6,6,6
+  const ivec4 i43 = ivec4(v45);  //11,11,11,11
+
+  const ivec4 i44 = ivec4(v44[0]);  // 5,5,5,5
+  const ivec4 i45 = ivec4(vec2(20, 21), vec2(22, 23));  // 20, 21, 22, 23
+  const vec4 v414 = vec4(ivec2(29, 30), ivec2(31, 32)); // 29.0, 30.0, 31.0, 32.0
+  const ivec4 i46 = ivec4(ivec2(2.0,3.0), ivec3(4.0,5.0,6.0));
+  const ivec4 i47 = ivec4(i46);  // 2,3,4,5
+  const ivec4 i48 = ivec4(v414.x);  // 29,29,29,29
+
+  const ivec4 i49 = ivec4(vec4(1)); // 1,1,1,1
+  const ivec4 i414 = ivec4(mat4(14)); // 14, 0,0,0,
+  const ivec4 i410 = ivec4(m43);  // 4,0,0,0
+  const ivec4 i411 = ivec4(m43[1]);  // 0, 4, 0, 0
+  const ivec4 i412 = ivec4(s77.i); // 12, 12, 12, 12
+  const ivec4 i416 = ivec4(s22.v3.zyx, 12);  // 11, 10, 9, 12
+
+  const vec4 v415 = vec4(ivec2(35), ivec2(36)); // 35.0, 35.0 ,36.0 , 36.0
+
+  const bvec4 b41 = bvec4(1.0, 2.0, 3.0, 4.0);  // true,true,true,true
+
+  const bvec4 b42 = bvec4(6);  // true,true,true,true
+  const bvec4 b43 = bvec4(v45);  //true,true,true,true
+
+  const bvec4 b44 = bvec4(v44[0]);  // true,true,true,true
+  const bvec4 b45 = bvec4(vec2(0, 21), vec2(0, 1));  // false, true, false, true
+  const bvec4 b46 = bvec4(ivec2(0.0,3.0), ivec3(0,5.0,6.0)); // false, true, false, true
+  const bvec4 b47 = bvec4(i46);  // true,true,true,true
+  const bvec4 b48 = bvec4(v414.x);  // true,true,true,true
+
+  const bvec4 b49 = bvec4(vec4(0)); // false,false,false,false
+  const bvec4 b414 = bvec4(mat4(14)); // true, false,false,false,
+  const bvec4 b410 = bvec4(m43);  // true,false,false,false
+  const bvec4 b411 = bvec4(m43[1]);  // false, true, false, false
+  const bvec4 b412 = bvec4(s77.i) ; // true, true, true, true
+
+  const vec3 v35 = vec3(s11.s44.v4);  // 7.0,8.0,9.0
+
+
+  struct s10 {
+     int k;
+  };
+  struct s9 {
+       float f;
+      s10 s101;
+   };
+  const struct s8 {
+      int i;
+      s9 s99;
+  } s88 = s8(1, s9(2.0, s10(5)));
+
+   struct st4 {
+       int m;
+       vec3 v3;
+   };
+   struct st3 {
+      int k;
+      int l;
+      st4 st44;
+     };
+   struct st2 {
+       float f;
+       st3 st33;
+  };
+  const struct st1 {
+      int i;
+      st2 st22;
+  } st11 = st1(1, st2(2.0, st3(5, 6, st4(7, v35))));
+
+  const vec4 v416 = vec4(s88.s99.s101.k); // all 5s
+  const vec4 v417 = vec4(st11.st22.st33.st44.v3, s88.s99.s101.k);  // 7.0, 8.0, 9.0, 5.0
+  const vec3 v36 = vec3(s11.ss.v3);  // 9, 10, 11
+
+  vec4 v418 = v416;  // all 5s
+  const float f1 = v416[0];  // 5.0
+  vec4 v419;
+  v419.xyz = st11.st22.st33.st44.v3;
+  mat4 m47;
+
+  struct struct2 {
+      int k;
+  } struct22 = struct2(4);
+
+  const struct struct1 {
+       struct2 sst2;
+  } struct11 = struct1(struct2(2));
+
+  const vec4 v420 = v417;  // 7.0, 8.0, 9.0 , 5.0
+
+  vec4 v421 = vec4(s11.m);  // 5, 0, 0, 0
+  vec4 v422 = v420;  // 7.0, 8.0, 9.0 , 5.0
+
+  vec4 v423 = s11.s44.v4;   // 7, 8, 9, 10
+
+  int int1 = ss.i * ss.i;  // 16
+  int int2 = ss.i * 2;  // 8
+
+  const vec4 v425 = v420 * v420;  // 49, 64, 81, 25
+  const vec4 v426 = s11.m * s11.s44.v4; // 35, 40, 45, 50
+  const vec4 v427 = s11.s44.v4 * s11.m; // 35, 40, 45, 50
+
+  float ff = 2.0;
+  const float ffConst = 2.0;
+
+  vec4 v428 = ff + v425;  // ordinary assignment with binary node
+  vec3 v39 = vec3(5);
+
+  vec3 v310 = s22.v3 + v39;  //14, 15, 16
+
+  const vec4 v429 = v420 + v420; // 14, 16, 18, 10
+  const vec4 v430 = v420 + ffConst;  // 9, 10, 11,7
+  const vec4 v432 =  v429 + s11.f;  // 18, 20, 22, 14
+
+  const vec4 v433 = vec4(s11.f + s11.f);  // all 8s
+  const vec4 v434 = v432 + vec4(3);  // 21, 23, 25, 17
+  const mat4 m48 = s11.m + ffConst;  // diagonal 7s and others 2s
+  const mat4 m49 = mat4(ffConst + s11.f);  // diagonal 6s
+  const mat4 m410 = m48 + s11.f;  // diagonal 11, others - 6s
+
+  const mat4 m413 = m48 + m48 ; // diagonal 14, others 4
+  const mat4 m414 = m413 + ffConst ; // diagonal 16, others 6
+
+  const vec4 v435 = ffConst + v420;  // 9, 10, 11,7
+  const vec4 v436 =  s11.f + v429;  // 18, 20, 22, 14
+  const mat4 m415 = ffConst + s11.m;  // diagonal 7s and others 2s
+  const mat4 m416 = s11.f + m48 ;  // diagonal 11, others - 6s
+  const mat4 m417 = ffConst + m413 ; // diagonal 16, others 6
+
+  const vec4 v437 = v420 - v420; // 0, 0, 0, 0
+  const vec4 v438 = v420 - ffConst;  // 5, 6, 7,3
+  const vec4 v440 =  v429 - s11.f;  // 10, 12, 14, 6
+
+  const vec4 v441 = vec4(s11.f - s11.f);  // all 0s
+  const vec4 v442 = v432 - vec4(3);  // 15, 17, 19, 11
+  const mat4 m418 = s11.m - ffConst;  // diagonal 3s and others -2s
+  const mat4 m419 = mat4(ffConst - s11.f);  // diagonal -> -2s
+  const mat4 m420 = m48 - s11.f;  // diagonal 3, others -> -2
+
+  const mat4 m423 = m48 - m48 ; // All 0s
+  const mat4 m424 = m413 - ffConst ; // diagonal 12, others 2
+
+  const vec4 v443 = ffConst - v420;  // -5, -6, -7,-3
+  const vec4 v444 =  s11.f - v429;  // -10, -12, -14, -6
+  const mat4 m425 = ffConst - s11.m;  // diagonal -3s and others 2s
+  const mat4 m426 = s11.f - m48 ;  // diagonal -3, others  2s
+  const mat4 m427 = ffConst - m413 ; // diagonal -12, others -2
+
+  const vec4 v445 = v420 * v420; // 49, 64, 81, 25
+  const vec4 v446 = v420 * ffConst;  // 14, 16, 18,10
+  const vec4 v448 =  v429 * s11.f;  // 56, 46, 72, 40
+
+  const vec4 v449 = vec4(s11.f * s11.f);  // all 16
+  const vec4 v450 = v432 * vec4(3);  // 54, 60, 66, 42
+  const mat4 m428 = s11.m * ffConst;  // diagonal 10 and others 0s
+  const mat4 m429 = mat4(ffConst * s11.f);  // diagonal 8
+  const mat4 m430 = m48 * s11.f;  // diagonal 28, others 8
+
+  const mat4 m433 = m48 * m48 ; // diagonal 61, others 36
+  const mat4 m434 = m413 * ffConst ; // diagonal 28, others 8
+
+  const vec4 v451 = ffConst * v420;  // 14, 16, 18,10
+  const vec4 v452 =  s11.f * v429;  // 56, 64, 72, 40
+  const mat4 m435 = ffConst * s11.m;  //  diagonal 10 and others 0s
+  const mat4 m436 = s11.f * m48 ;  // diagonal 28, others - 8s
+  const mat4 m437 = ffConst * m413 ; // diagonal 28, others 8
+
+  const vec4 v453 = v420 / v420; // 1, 1, 1, 1
+  const vec4 v454 = v420 / ffConst;  // 3.5, 4, 4.5,2.5
+
+  const vec4 v457 = vec4(s11.f / s11.f);  // all 1s
+  const vec4 v458 = v432 / vec4(3);  // 6, 6.6666, 7.333, 4.6666
+  const mat4 m438 = s11.m / ffConst;  // diagonal 2.5 and others 0s
+  const mat4 m439 = mat4(ffConst / s11.f);  // diagonal 0.5s
+  const mat4 m440 = m48 / s11.f;  // diagonal 1.75, others 0.5s
+
+  const mat4 m443 = m48 / m48 ; // All 1s
+  const mat4 m444 = m413 / ffConst ; // diagonal 7, others 2
+
+  const vec4 v459 = ffConst / v420;  // .2857 , .25, .22, .4
+  const vec4 v460 =  s11.f / v429;  // .2857, .25, .22, .4
+  //const mat4 m445 = ffConst / s11.m;  // divide by zero error
+  const mat4 m446 = s11.f / m48 ;  // diagonal .571,  others 2
+  const mat4 m447 = ffConst / m413 ; // diagonal .1428, others 0.5
+
+  const vec4 v461 = v453 * m428; // 10, 10, 10, 10
+  const vec4 v462 = v453 * m437; // 52, 52, 52, 52
+  const vec4 v463 = m428 * v451; // 140, 160, 180, 100
+  const vec4 v464 = m437 * v451; // 744, 784, 824, 664
+
+  int ii = 2;
+  const int iiConst = 2;
+
+  const ivec4 i420 = ivec4( 7,8,9,5);  // 7, 8, 9, 5
+
+  const ivec4 i429 = i420 + i420; // 14, 16, 18, 10
+  const ivec4 i430 = i420 + iiConst;  // 9, 10, 11,7
+  const ivec4 i432 =  i429 + ss.i;  // 18, 20, 22, 14
+
+  const ivec4 i433 = ivec4(ss.i + ss.i);  // all 8s
+
+  const ivec4 i435 = iiConst + i420;  // 9, 10, 11,7
+  const ivec4 i436 =  ss.i + i429;  // 18, 20, 22, 14
+
+  const ivec4 i437 = i420 - i420; // 0, 0, 0, 0
+  const ivec4 i438 = i420 - iiConst;  // 5, 6, 7,3
+  const ivec4 i440 =  i429 - ss.i;  // 10, 12, 14, 6
+
+  const ivec4 i441 = ivec4(ss.i - ss.i);  // all 0s
+
+  const ivec4 i443 = iiConst - i420;  // -5, -6, -7,-3
+  const ivec4 i444 =  ss.i - i429;  // -10, -12, -14, -6
+
+  const ivec4 i445 = i420 * i420; // 49, 64, 81, 25
+  const ivec4 i446 = i420 * iiConst;  // 14, 16, 18,10
+  const ivec4 i448 =  i429 * ss.i;  // 56, 64, 72, 40
+
+  const ivec4 i449 = ivec4(ss.i * ss.i);  // all 16
+
+  const ivec4 i451 = iiConst * i420;  // 14, 16, 18,10
+  const ivec4 i452 =  ss.i * i429;  // 56, 64, 72, 40
+
+  const ivec4 i453 = i420 / i420; // 1, 1, 1, 1
+  const ivec4 i454 = i420 / iiConst;  // 3, 4, 4,2
+  const ivec4 i456 =  i429 / ss.i;  // 3, 4, 4, 2
+
+  const ivec4 i457 = ivec4(ss.i / ss.i);  // all 1s
+
+  const ivec4 i459 = iiConst / i420;  // 0 , 0, 0,0
+  const ivec4 i460 =  ss.i / i429;  // 0, 0, 0,0
+
+  const bvec4 b424 = bvec4(s22.bv4);
+
+  const bool b1 = s22.bv4 == b424;  // true
+  const bool b2 = i420 == i420;  // true
+  const bool b3 = i420 == i445;  // false
+  const bool b4 = v420 == v420;  // true
+  const bool b5 = m430 == m434; // true
+
+  const vec4 v465 = -v420; // -7, -8, -9, -5
+  const mat4 m448 = -m447 ; // diagonal -.1428, others -0.5
+  const ivec4 i465 = -i456 ;  // -3, -4, -4,-2
+
+  const bool b7 = s22 == s22;
+
+  const vec4 v466 = v432 + vec4(3,4,5,6);  // 21, 24, 27, 20
+  const vec4 v467 = v432 + vec4(vec2(3,4),5,6);  // 21, 24, 27, 20
+  const vec4 v468 = v432 + vec4(3, vec2(4, 5),vec2(6,7));  // 21, 24, 27, 20
+  const vec4 v469 = vec4(v468) + vec4(3) + v468 + vec4(s77.m3[2][0]); // 45, 51, 57, 43
+
+  const bool b8 = ss == ss;  // true
+
+  struct st6 {
+       vec3 v;
+  };
+
+  struct st5 {
+      int i;
+      float f;
+      st6  st66;
+  } st55;
+
+  const st5 st551 = st5(2, 4.0, st6(vec3(7)));
+  const st5 st552 = st5(2, 4.0, st6(vec3(7)));
+
+  const bool b10 = st551 == st552;  // true
+
+  const bool b11 = st551.st66 == st552.st66;  // true
+
+  const st5 st553 = st5(2, 4.0, st6(vec3(8)));
+
+  const bool b12 = st551.st66 == st553.st66;  // false
+  const bool b13 = st551 == st553;  // false
+
+  const bool b14 = st551 != st552;  // false
+  const bool b15 = st551.st66 != st552.st66;  // false
+  const bool b16 = st551.st66 != st553.st66;  // true
+  const bool b17 = st551 != st553;  // true
+
+  const bool b18 = s22.bv4 != b424;  // false
+  const bool b19 = i420 != i420;  // false
+  const bool b20 = i420 != i445;  // true
+  const bool b21 = v420 != v420;  // false
+  const bool b22 = m430 != m434; // false
+
+  const int int10 = i420.xy.y;  // 8
+
+  //float f = v470.x;
+
+
+
+  const int int13 = -ss.i;
+
+  const vec4 v474 = -vec4(0.5);
+
+  int int14 = ii++;
+  int array[3];
+  array[2];
+
+  const vec4 v478 = v466 * 2.0; // 42, 48, 54, 40
+
+  const vec4 v479 = iiConst > 1 ? v466 : v478; // 21, 24, 27, 20
+
+  const struct st7 {
+       int i;
+       bool b;
+  } st77 = st7(ss.i, true);
+
+  const vec4 v481 = vec4(st77.i);
+
+  const struct st8 {
+      int i;
+  } ;
+
+
+  const struct st9 {
+      s2 ss;
+  } st99 = st9(s22);
+
+  const vec3 v312 = st99.ss.v3;   // 9, 10, 11
+  const vec4 v482 = mat4(1)[0];  // 1, 0, 0 , 0
+
+  const mat4 m450 = mat4(ss.i);  // mat4(4)
+  const mat4 m451 = mat4(b20);   // mat4(1)
+  const mat4 m452 = mat4(st77.b); // mat4(1)
+
+  const vec4 v483 = vec4(vec4(3).x);  // 3,3,3,3
+  const mat4 m453 = mat4(vec4(5).x);  // mat5(5)
+
+  const vec4 v484 = vec4(mat4(6)[1]);  // 0,6,0,0
+  const mat4 m454 = mat4(mat4(6)[1][1]);  // mat4(6)
+
+  const vec4 v485 = vec4(st7(8, true).b);  // 1,1,1,1
+
+  const vec4 v487 = vec4(vec4(12, 13, 14, 15).ab, 12, 14);
+
+  int i20 = ss.i;
+  const vec4 v489 = -vec4(7,8,9,5); // -7, -8, -9, -5
+
+  gl_Position = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstruct_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstruct_vert.vert
new file mode 100644
index 0000000..e8d9b37
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectConstruct_vert.vert
@@ -0,0 +1,37 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+struct s {
+    float f;
+} s1 = s(1.0);
+
+struct s3 {
+   int i;
+} s3Inst;
+
+struct s2 {
+    float f;
+    s3 s3Inst;
+} s2Inst = s2(1.0, s3(1));
+
+void main()
+{
+    vec3 i = vec3(5.0, 4.0, ivec2(2.0, 1.0));
+    ivec4 v2 = ivec4(1.0);
+    vec4 v4 = vec4(v2);
+    bvec4 v5 = bvec4(v2);
+    vec3 v6 = vec3(v5);
+    vec3 v = vec3(2, 2.0, 1);
+    vec3 v1 = vec3(1.2, v);
+
+    mat3 m1 = mat3(v,v,v);
+    mat2 m2 = mat2(v, v6.x);
+
+    gl_Position = vec4(1.0);
+}
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension10_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension10_V100_frag.frag
new file mode 100644
index 0000000..9f7eb6a0
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension10_V100_frag.frag
@@ -0,0 +1,26 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#version 100
+#extension extensionfoo : enable  // warning extension not supported
+#extension extensionfoo : disable  // warning extension not supported
+#extension extensionfoo : warn  // warning extension not supported
+
+#extension all : disable // no error in the program
+#extension all : warn // no error in the program
+
+#extension extensionfoo : enable  // warning extension not supported
+#extension extensionfoo : disable  // warning extension not supported
+#extension extensionfoo : warn  // warning extension not supported
+#ifdef GL_ES
+precision mediump float;
+#endif
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension1_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension1_V100_frag.frag
new file mode 100644
index 0000000..34d497d
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension1_V100_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#extension all : disable // no error in the program
+#extension all : warn // no error in the program
+#ifdef GL_ES
+precision mediump float;
+#endif
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension4_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension4_V100_frag.frag
new file mode 100644
index 0000000..e013e85
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectExtension4_V100_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#extension extensionfoo : enable  // warning extension not supported
+#extension extensionfoo : disable  // warning extension not supported
+#extension extensionfoo : warn  // warning extension not supported
+#ifdef GL_ES
+precision mediump float;
+#endif
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFull_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFull_vert.vert
new file mode 100644
index 0000000..30f14ad
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFull_vert.vert
@@ -0,0 +1,654 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+struct gtf_MaterialParameters
+{
+vec4 emission;
+vec4 ambient;
+vec4 diffuse;
+vec4 specular;
+float shininess;
+};
+struct gtf_LightSourceParameters
+{
+vec4 ambient;
+vec4 diffuse;
+vec4 specular;
+vec4 position;
+vec4 halfVector;
+vec3 spotDirection;
+float spotExponent;
+float spotCutoff;
+float spotCosCutoff;
+float constantAttenuation;
+float linearAttenuation;
+float quadraticAttenuation;
+};
+struct gtf_PointParameters {
+float size;
+float sizeMin;
+float sizeMax;
+float fadeThresholdSize;
+float distanceConstantAttenuation;
+float distanceLinearAttenuation;
+float distanceQuadraticAttenuation;
+};
+struct gtf_DepthRangeParameters {
+float near;
+float far;
+float diff;
+};
+struct gtf_LightModelParameters {
+vec4 ambient;
+};
+struct gtf_LightModelProducts {
+vec4 sceneColor;
+};
+struct gtf_LightProducts {
+vec4 ambient;
+vec4 diffuse;
+vec4 specular;
+};
+struct gtf_FogParameters {
+vec4 color;
+float density;
+float start;
+float end;
+float scale;
+};
+uniform int gtf_MaxFragmentUniformComponents;
+uniform int gtf_MaxVertexUniformComponents;
+uniform int gtf_MaxVertexTextureImageUnits;
+uniform int gtf_MaxLights;
+uniform int gtf_MaxClipPlanes;
+uniform int gtf_MaxCombinedTextureImageUnits;
+uniform int gtf_MaxTextureCoords;
+uniform int gtf_MaxVertexAttribs;
+uniform int gtf_MaxVaryingFloats;
+uniform int gtf_MaxTextureUnits;
+uniform int gtf_MaxDrawBuffers;
+uniform int gtf_MaxTextureImageUnits;
+uniform gtf_LightProducts gtf_FrontLightProduct[8];
+uniform gtf_LightModelProducts gtf_FrontLightModelProduct;
+uniform gtf_DepthRangeParameters gtf_DepthRange;
+uniform gtf_FogParameters gtf_Fog;
+uniform gtf_PointParameters gtf_Point;
+uniform gtf_LightModelParameters gtf_LightModel;
+varying vec4 gtf_FogFragCoord;
+varying vec4 gtf_BackColor;
+varying vec4 gtf_BackSecondaryColor;
+varying vec4 gtf_FrontSecondaryColor;
+varying vec4 gtf_TexCoord[2];
+varying vec4 gtf_FrontColor;
+uniform gtf_MaterialParameters gtf_FrontMaterial;
+uniform gtf_LightSourceParameters gtf_LightSource[8];
+attribute vec4 gtf_MultiTexCoord1;
+attribute vec4 gtf_MultiTexCoord2;
+attribute vec4 gtf_SecondaryColor;
+attribute vec4 gtf_Color;
+attribute vec4 gtf_MultiTexCoord3;
+attribute vec4 gtf_MultiTexCoord0;
+attribute vec4 gtf_Normal;
+attribute vec4 gtf_Vertex;
+uniform mat4 gtf_NormalMatrix;
+uniform mat4 gtf_ProjectionMatrix;
+uniform mat4 gtf_TextureMatrix[8];
+uniform mat4 gtf_ModelViewMatrix;
+uniform mat4 gtf_ModelViewProjectionMatrix;
+void test_function(const in int in_int, inout int out_int);
+int test_function1(in int in_int1, inout int in_out_int);
+
+uniform float array_float[2];
+
+struct nested
+{
+   int a;
+   float f;
+};
+
+struct light1
+{
+   float intensity;
+   vec3 position;
+   int test_int[2];
+   nested light2;
+} lightVar;
+light1 ll2;
+
+void Assign (out light1 out1, in light1 in1)
+{
+    out1.intensity = in1.intensity;
+     out1.position = in1.position;
+  out1.test_int[0] = in1.test_int[0];
+  out1.test_int[1] = in1.test_int[1];
+       out1.light2 = in1.light2;
+}
+
+struct light3 {
+    float i;
+};
+
+struct light4 {
+    float i;
+};
+
+struct light5 {
+    float i ;
+    float a[2];
+} light5_inst;
+
+uniform light3 uniformLight3;
+
+struct light6 {
+    float i;
+};
+uniform light6 uniformLight6;
+
+struct slight10{
+     float f;
+     };
+struct slight9{
+     slight10 light10;
+     };
+struct slight8{
+     slight9 light9;
+     };
+struct light7 {
+  slight8 light8;
+} ;
+
+
+light3 struct_var = light3(5.0);
+
+// Attribtue variables can only be Global
+attribute float flt_attrib;
+attribute vec2 vec2_attrib;
+attribute vec3 vec3_attrib;
+attribute vec4 vec4_attrib;
+attribute mat2 mat2_attrib;
+attribute mat3 mat3_attrib;
+attribute mat4 mat4_attrib;
+
+uniform float flt_uniform;
+uniform vec3 uniform_vec3;
+uniform mat3 uniform_mat3;
+
+uniform sampler2D samp[3];
+uniform sampler2D samp1;
+
+const struct light12 {
+    int a;
+} uniform_struct = light12(2);
+
+varying vec3 varying_vec3;
+varying vec2 varying_vec2;
+varying vec4 varying_vec4;
+varying mat4 varying_mat4;
+varying mat2 varying_mat2;
+varying mat3 varying_mat3;
+varying float varying_flt;
+
+float frequencies[2];
+
+void test_function2(int func_int)
+{
+}
+
+void test_function3(light3);
+void test_function4(light5 ll20);
+void test_function5(light1);
+light6 test_function6(int a);
+
+const float FloatConst1 = 3.0 * 8.0, floatConst2 = 4.0;
+const bool BoolConst1 = true && true || false;
+const bool BoolConst2 = false || !false && false;
+
+void main(void)
+{
+
+    int test_int1 = 2;
+    const int const_test_int1 = 2;
+
+    struct structMain {
+        float i;
+    } testStruct;
+
+    struct {
+        structMain a;
+    } aStruct;
+
+    testStruct.i = 5.0 ;
+    struct_var.i = 5.0;
+
+    structMain newStruct, newStruct1;
+    testStruct = newStruct;
+    newStruct = newStruct1;
+
+    lightVar.light2.f = 1.1;
+
+    light1 ll1;
+    ll1.light2.a = 1;
+
+     const struct const_struct {
+        float i;
+    } const_struct_inst = const_struct(1.0);
+
+    //ll1 = ll2;
+    Assign (ll1, ll2);
+    ll1.light2 = ll2.light2;
+    ll1.light2 = ll1.light2;
+    ll1.light2.f = ll2.light2.f;
+    ll1.light2.f = ll1.light2.f;
+
+    //    lightVar = ll2;
+    //    ll2 = lightVar;
+    Assign (lightVar, ll2);
+    Assign (ll2, lightVar);
+
+    light5 ll10;
+
+    light7 ll7[4];
+    structMain newStruct2[2];
+    newStruct2[0].i = 1.1;
+
+    ll7[0].light8.light9.light10.f = 1.1;
+
+
+    bool test_bool4 = false ;
+
+    bool test_bool5 = 1.2 > 3.0 ;
+
+    int test_int2 =  047;
+    int test_int4 =  0xa8;  // testing for hexadecimal numbers
+
+    float test_float1 = 1.5;
+    float test_float2 = .01;
+    float test_float3 = 10.;
+    float test_float4 = 10.01;
+    float test_float5 = 23e+2;
+    float test_float6 = 23E-3;
+    float test_float8 = 23E2;
+    bool test_bool6 = BoolConst1 && ! (test_int1 != 0) && ! BoolConst1  && ! (FloatConst1 != 0.0) && (FloatConst1 != 0.0) && (test_float1 != 0.0);
+
+    vec4 color = vec4(0.0, 1.0, 0.0, 1.0);
+    vec4 color2 = vec4(0.0);
+
+    vec3 color4 = vec3(test_float8);
+
+    ivec4 test_int_vect1 = ivec4(1.0,1.0,1.0,1.0);
+    ivec3 test_int_vec3 = ivec3(1, 1, 1) ;
+
+    bvec4 test_bool_vect1 = bvec4(1., 1., 1. , 1. );
+
+    vec2 test_vec2 = vec2(1., 1.);
+    vec2 test_vec3 = vec2(1., 1);
+    vec4 test_vec4 = vec4(test_int_vect1);
+
+    vec2 test_vec5 = vec2(color4);
+    vec3 test_vec7 = vec3(color);
+    vec3 test_vec8 = vec3(test_vec2, test_float4);
+    vec3 test_vec9 = vec3(test_float4, test_vec2);
+
+    vec4 test_vec10 = vec4(test_vec9, 0.01);
+    vec4 test_vec11 = vec4(0.01, test_vec9);
+
+    vec4 test_vec12 = vec4(test_vec2, test_vec2);
+
+    mat2 test_mat2 = mat2(test_float3);
+    mat3 test_mat3 = mat3(test_float3);
+    mat4 test_mat4 = mat4(test_float3);
+
+    mat2 test_mat7 = mat2(test_vec2, test_vec2);
+    mat2 test_mat8 = mat2(01.01, 2.01, 3.01, 4.01);
+
+    mat3 test_mat9 = mat3(test_vec7, test_vec7, test_vec7);
+    mat4 test_mat10 = mat4(test_vec10, test_vec10, test_vec10, test_vec10);
+    test_mat10[1] = test_vec10;
+
+
+    mat2 test_mat12 = mat2(test_vec2, 0.01, 0.01);
+    mat2 test_mat13 = mat2(0.01, 5., test_vec2);
+    mat2 test_mat15 = mat2(0.1, 5., test_vec2 );
+
+    //mat2 test_mat16 = mat2(test_mat9);
+    //mat2 test_mat17 = mat2(test_mat10);
+
+    float freq1[2];
+    float freq2[25];
+
+    for (int i=0; i<100; i++)
+    {
+      if (test_float1 < 1.0)
+      {
+
+      }
+      else
+      {
+        break;
+      }
+    }
+
+    freq2[1] = 1.9 ;
+    const int array_index = 2;
+    freq2[const_test_int1] = 1.9 ;
+    freq2[array_index] = 1.8;
+
+    const int const_int = 5;
+
+    test_float1 = varying_flt;
+
+    int out_int;
+    int intArray[6];
+    test_function(test_int1, test_int1);
+    test_function(test_int1, intArray[2]);
+
+    vec3 vv = vec3(test_function1(test_int1, out_int));
+    bool bool_var = true;
+    int test_int6 = int(bool_var);
+    test_float1 = float(bool_var);
+    test_float1 = float(test_int6);
+    test_int6 = int(test_float1);
+    bool_var = bool(test_int6);
+    bool_var = bool(test_float1);
+    test_float1 = float(test_vec9);
+
+    test_vec2.x = 1.2;
+    test_vec2.y = 1.4;
+    test_vec2.xy;
+
+
+    color.zy = test_vec2;
+
+   test_vec2[1] = 1.1;
+
+     test_mat2[0][0] = 1.1;
+
+    test_float1 += 1.0;
+    test_float1 -= 1.0;
+    test_float1 *= 1.0;
+    test_float1 /= 1.0;
+
+    test_mat12 *= test_mat13 ;
+    test_mat12  *= test_float1;
+    test_vec2 *= test_float1;
+    test_vec2 *= test_mat12;
+    test_float1++;
+    test_float1--;
+    --test_float1;
+    ++test_float1;
+    test_float1;
+    test_int1++;
+    test_int1--;
+
+    test_vec2 = test_vec2 + test_float1;
+    test_vec2 = test_float1 + test_vec2;
+
+    test_mat12 = test_mat12 * test_mat13;
+    test_vec2 = test_vec2 * test_vec5;
+
+    test_vec2++;
+    test_mat2++;
+
+    bool test_bool2 = test_float2 > test_float3;
+
+    bool test_bool3 = test_int1 > test_int6 ;
+
+    test_bool3 = test_vec2 == test_vec5;
+
+    test_bool2 = test_bool3 && test_bool4;
+    test_bool2 = test_bool3 || test_bool4;
+    test_bool2 = test_bool3 ^^ test_bool4;
+
+    test_bool2 = !test_bool3;
+
+    test_bool3 = !(test_int1 > test_int6) ;
+
+    test_float1 = test_int1 > test_int6 ? test_float2 : test_float3;
+    test_vec2 = test_int1 > test_int6 ? test_vec2 : test_vec5;
+    if(test_bool2)
+        test_float1++;
+    else
+	test_float1--;
+
+    if(test_float1 > test_float2)
+        test_float1++;
+
+    if( test_bool2 )
+    {
+        int if_int;
+        test_float1++;
+    }
+
+    if(test_bool2)
+       if(test_bool3)
+           if(test_bool3)
+	      test_float1++;
+
+   for(int for_int=0; for_int < 5; for_int++)
+   {
+       // do nothing as such
+   }
+
+
+   for(int x1=0; x1 < 10; x1++)
+   {
+     if (!test_bool2)
+       break;
+
+     int for_int;
+   }
+
+   for(int x2=-10; x2 < 100; x2++)
+   {
+     test_bool2 = (test_float1 > test_float2);
+     if (!test_bool2)
+       break;
+   }
+
+   for(int for_int1 = 0; for_int1 < 100; for_int1++)
+   {
+     if (!test_bool2)
+       break;
+
+     int for_int;
+   }
+
+   for(int for_int1 = 0; for_int1 < 100; for_int1++)
+   {
+     if (!test_bool2)
+       continue;
+
+     int for_int;
+   }
+
+
+   for(int i=0; i<100; i++)
+   {
+     if (!(test_float1 > test_float2))
+     {
+       break;
+     }
+
+     break;
+     continue;
+   }
+
+   for(int i=0; i<100; i++)
+   {
+     if (!test_bool2)
+       break;
+
+     break;
+   }
+
+   for (int i=0; i<100; i++)
+   {
+     int dowhile_int;
+     dowhile_int = 3;
+
+     if (!test_bool2)
+       break;
+   }
+
+    gl_Position = vec4(2.0, 3.0, 1.0, 1.1);
+    gl_Position = gtf_Vertex;
+
+
+    // VERTEX SHADER BUILT-IN ATTRIBUTES
+
+    vec4 builtInV4 = gtf_Color + gtf_SecondaryColor + gtf_Vertex + gtf_MultiTexCoord0 + gtf_MultiTexCoord1 + gtf_MultiTexCoord2 +  gtf_MultiTexCoord3;
+
+
+    int builtInI = gtf_MaxLights + gtf_MaxClipPlanes + gtf_MaxTextureUnits + gtf_MaxTextureCoords + gtf_MaxVertexAttribs + gtf_MaxVertexUniformComponents + gtf_MaxVaryingFloats + gtf_MaxVertexTextureImageUnits + gtf_MaxCombinedTextureImageUnits + gtf_MaxTextureImageUnits + gtf_MaxFragmentUniformComponents + gtf_MaxDrawBuffers ;
+
+
+    mat4 builtInM4 = gtf_ModelViewMatrix + gtf_ModelViewProjectionMatrix + gtf_ProjectionMatrix;
+
+    gtf_NormalMatrix;
+
+    gtf_TextureMatrix[gtf_MaxTextureCoords-1];
+    gtf_TextureMatrix;
+
+    gtf_DepthRange.near ;
+
+    test_float1 = gtf_DepthRange.near;
+    test_float1 = gtf_DepthRange.far;
+    test_float1 = gtf_DepthRange.diff;
+
+    gtf_Point.size;
+    gtf_Point.sizeMin;
+    gtf_Point.sizeMax;
+    gtf_Point.fadeThresholdSize ;
+    gtf_Point.distanceConstantAttenuation;
+    gtf_Point.distanceLinearAttenuation ;
+    gtf_Point.distanceQuadraticAttenuation;
+
+    gtf_MaterialParameters test;
+    gtf_FrontMaterial.emission;
+
+    color = gtf_FrontMaterial.emission;
+    color = gtf_FrontMaterial.ambient;
+    color = gtf_FrontMaterial.diffuse;
+    color = gtf_FrontMaterial.specular;
+    test_float1 = gtf_FrontMaterial.shininess;
+
+    gtf_LightSourceParameters lightSource;
+
+    float builtInFloat1 = gtf_LightSource[0].spotExponent;
+    color = gtf_LightSource[0].ambient;
+    color = lightSource.ambient;
+    color = lightSource.diffuse;
+    color = lightSource.specular;
+    color = lightSource.position;
+    color = lightSource.halfVector;
+    color4 = lightSource.spotDirection;
+    test_float1 = lightSource.spotExponent;
+    test_float1 = lightSource.spotCutoff;
+    test_float1 = lightSource.spotCosCutoff;
+    test_float1 = lightSource.constantAttenuation;
+    test_float1 = lightSource.linearAttenuation;
+    test_float1 = lightSource.quadraticAttenuation;
+
+    color = gtf_LightModel.ambient;
+
+    gtf_LightModelParameters lightModel;
+    color = gtf_LightModel.ambient;
+    color = lightModel.ambient;
+
+    color = gtf_FrontLightModelProduct.sceneColor ;
+
+    gtf_LightModelProducts lightModelProd;
+
+    color = lightModelProd.sceneColor;
+    color = gtf_FrontLightModelProduct.sceneColor;
+
+    color = gtf_FrontLightProduct[0].ambient;
+    color = gtf_FrontLightProduct[0].ambient;
+    gtf_LightProducts lightProd;
+
+    color =  lightProd.ambient;
+    color =  lightProd.diffuse;
+    color =  lightProd.specular;
+
+
+    test_float1 = gtf_Fog.density ;
+    test_float1 = gtf_Fog.start ;
+    test_float1 = gtf_Fog.end  ;
+    test_float1 = gtf_Fog.scale ;
+    color = gtf_Fog.color ;
+
+    gtf_FrontColor =  vec4(1.0, 1.0, 1.0, 1.0);
+    gtf_BackColor =  vec4(1.0, 1.0, 1.0, 1.0);
+    gtf_FrontSecondaryColor =  vec4(1.0, 1.0, 1.0, 1.0);
+    gtf_BackSecondaryColor =  vec4(1.0, 1.0, 1.0, 1.0);
+
+
+    // VARYING VARIABLES AVAILABLE IN FRAGMENT AND VERTEX SHADERS BOTH
+    gtf_TexCoord[0] =  vec4(1.0, 1.0, 1.0, 1.0);
+    gtf_FogFragCoord =  vec4(1.0, 1.0, 1.0, 1.0);
+
+}
+
+void test_function(const in int in_int, inout int out_int)
+{
+    out_int = 5;
+    int i = 5;
+    return ;
+}
+
+int test_function1(in int in_int1, inout int in_out_int)
+{
+   float ff;
+   in_int1 = 5;
+   return in_int1;
+}
+
+void test_function3(light3 ll)
+{
+    ll.i = 5.0;
+    varying_flt = 1.2;
+}
+
+void test_function4(light5 ll20)
+{
+    ll20.i = 10.0;
+}
+
+void test_function5(light1 struct_light1)
+{
+    struct_light1.light2.a = 1;
+    light5 ll5;
+    struct_light1.light2.f = ll5.i;
+    struct_light1.light2.f++;
+    struct_light1.light2.a++;
+}
+
+light6 test_function6(int a)
+{
+    int x;
+    light6 funcStruct;
+    light7 funcStruct1;
+    -x;
+    x = x - x ;
+    mat2 m;
+    m++;
+    -m;
+    (m)++;
+    return funcStruct;
+}
+
+float test_function7(light1 ll1, int light1 )
+{
+    float f;
+
+    struct ss1 {
+        int a;
+    };
+
+    return float(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_frag.frag
new file mode 100644
index 0000000..58e9a95
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_frag.frag
@@ -0,0 +1,27 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void testVoid (vec4 v, vec4 v1)
+{
+}
+
+void testVoid (ivec4 v, ivec4 v1)
+{
+}
+
+void main(void)
+{
+    vec4 v;
+    ivec4 i;
+    testVoid(i, i);
+    testVoid(v, v);
+    gl_FragColor = v;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_vert.vert
new file mode 100644
index 0000000..752f7e6
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFuncOverload_vert.vert
@@ -0,0 +1,37 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+struct S2
+{
+        float f;
+};
+
+struct S1
+{
+        float f;
+        S2 s2;
+};
+
+float process(S1 s1);
+float process(S2 s2);
+
+void main()
+{
+        S1 s1 = S1(1.0, S2(1.0));
+        gl_Position = vec4(process(s1));
+}
+
+float process(S1 s1)
+{
+        return s1.f + process(s1.s2);
+}
+
+float process(S2 s2)
+{
+        return s2.f;
+}
\ No newline at end of file
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFunction1_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFunction1_vert.vert
new file mode 100644
index 0000000..f384cc5
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectFunction1_vert.vert
@@ -0,0 +1,36 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+vec3 bar(vec3, vec3);
+
+uniform vec2 v;
+
+bool foo(out vec3);
+
+void main()
+{
+    bool b1, b2, b3, b4, b5, b6;
+
+    b1 = any(lessThan(v, v));
+
+    b2 = all(lessThanEqual(v, v));
+
+    b3 = any(not(greaterThan(v, v)));
+
+    b4 = any(greaterThanEqual(v, v));
+
+    b5 = any(notEqual(v, v));
+
+    b6 = any(equal(v, v));
+
+    vec2 u;
+    if (b1 && b2 && b3 && b4 && b5 && b6)
+        u = v;
+
+    gl_Position = vec4(u, u);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectModule_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectModule_frag.frag
new file mode 100644
index 0000000..d3bc698
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectModule_frag.frag
@@ -0,0 +1,64 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+vec4 test_function4(float);
+vec4 test_function1(float);
+vec4 test_function2(float);
+vec4 test_function3(float);
+float f = 2.6;
+
+
+vec4 test_function1(float ff)
+{
+    vec4 func_vec4 = vec4(ff+f);
+    return func_vec4;
+}
+
+float f1 = 1.5;
+
+vec4 test_function4(float ff)
+{
+    vec4 func_vec4 = vec4(f1);
+    return func_vec4;
+}
+
+float f2 = 3.5;
+
+void main()
+{
+    vec4 v1 = test_function4(f2);
+    vec4 v2 = test_function1(f2);
+    vec4 v3 = test_function2(f2);
+    vec4 v4 = test_function3(f2);
+
+    if (f1 > f2) {
+        gl_FragColor = v1 + v2 + v3 + v4;
+    } else
+        gl_FragColor = v1 + v2 + v3 + v4;
+}
+
+float f4 = 5.5;
+vec4 test_function3(float ff)
+{
+    if (ff > f4)
+	return vec4(ff);
+    else
+        return vec4(f4);
+}
+
+float f3 = 4.5;
+vec4 test_function2(float ff)
+{
+    vec4 func_vec4 = vec4(ff+f3);
+    return func_vec4;
+}
+
+float f5 = 6.5;
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse1_frag.frag
new file mode 100644
index 0000000..65a9fb0
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse1_frag.frag
@@ -0,0 +1,51 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform vec3 a[8];
+
+uniform bool ub;
+varying mat4 vm;
+
+int foo(float);
+
+float bar(int i)
+{
+    return float(i);
+}
+
+void main (void)
+{
+    const int x = 3;
+    mat4 a[4];
+    vec4 v;
+
+    for (float f = 0.0; f != 3.0; ++f)
+    {
+    }
+
+    vec3 v3[x + x];
+
+    int vi = foo(2.3);
+
+    vec3 v3_1 = v3[x];
+
+    float f1 = a[x][2].z * float(x);
+    f1 = a[x][2][2] * float(x);
+    f1 = v[2] * v[1];
+
+    const int ci = 2;
+
+}
+
+int foo(float f)
+{
+    return 2;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_frag.frag
new file mode 100644
index 0000000..6bfe2ec
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_frag.frag
@@ -0,0 +1,136 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+const float FloatConst1 = 3.0 * 8.0, floatConst2 = 4.0;
+const bool BoolConst1 = true && true || false;
+const bool BoolConst2 = false || !false && false;
+
+void main (void)
+{
+    float float1 = 4.0, float2 = floatConst2;
+    int int_1 = int(FloatConst1);
+    vec4 vec4_1;
+    vec3 vec3_1;
+//  unsigned int unsigned_int_1;
+    bool bool4, bool5;
+
+    bool4 = bool5;
+    //float1 = bool5;
+    //bool5 = float1;
+
+    bool4 = 4.0 > 5.0;
+    bool4 = !(3.2 != 0.0);
+    bool4 = bool(float1);
+    bool4 = bool(int_1);
+    float1 = float(bool4);
+    float1 = float(int_1);
+    int_1 = int(float1);
+    int_1 = int(bool4);
+
+    {
+        int a, b, c;
+
+        a = b;
+        b = c;
+        {
+            int b, c, d;
+
+            b = c;
+            c = d;
+            {
+                int a, d, e;
+
+                a = d;
+                d = e;
+            }
+            {
+                int a, b, c;
+                a = b;
+                b = c;
+            }
+        }
+        a = b;
+        b = c;
+    }
+
+    {
+        float f1, f2;
+        vec3 v31, v32;
+
+        max(f1, f2);
+        max(v31, v32);
+
+        vec4 v4 = vec4(3.0);
+        vec3 v3 = -vec3(2.0, 1.0, 3.0);
+        mat2 m2 = mat2(3.0, 4.0, 6.0, 3.0);
+        //mat4 m4 = mat4(1.0, m2, v3, v4, m2);
+    }
+
+    if (BoolConst1)
+        ++vec3_1;
+    else
+        --vec3_1;
+
+    if (BoolConst2)
+        ++vec3_1;
+    else
+        --vec3_1;
+
+    if (BoolConst1 || BoolConst2)
+        ++vec3_1;
+    else
+        --vec3_1;
+
+    if (BoolConst2 && BoolConst1)
+        ++vec3_1;
+    else
+        --vec3_1;
+
+    if (FloatConst1 != 0.0)
+        --int_1;
+    else
+        ++int_1;
+
+    if (0 != 0)
+        ++int_1;
+    else
+        --int_1;
+
+    bool4 = BoolConst1 && ! (int_1 != 0) && ! BoolConst1  && ! (FloatConst1 != 0.0) && (FloatConst1 != 0.0) && (float1 != 0.0);
+
+    float1 = 5 != 0 ? float1 : float(int_1);
+    float1 = 0 != 0 ? float1 : float(int_1);
+
+    if (float1 != float1)
+        ++int_1;
+    else
+        --int_1;
+
+    float1 = float1 != float1 ? float1 : float(int_1);
+
+    --int_1;
+    ++float1;
+    (vec4_1.x)--;
+    vec3_1++;
+
+	if (int_1 != 4)
+		discard;
+
+    float1 = 4.0 + 6.0;
+    int ii,jj,kk;
+    float ff;
+    ii = jj, kk, ff;
+
+    vec4_1 = vec4_1 + 2.0;
+    ivec4 iv;
+    iv = iv + 2;
+    gl_FragColor = vec4(float1+float1, float1, float1, float(int_1));
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_vert.vert
new file mode 100644
index 0000000..d268644
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParse2_vert.vert
@@ -0,0 +1,149 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+const float FloatConst1 = 3.0 * 8.0, floatConst2 = 4.0;
+const bool BoolConst1 = true && true || false;
+const bool BoolConst2 = false || !false && false;
+
+void main (void)
+{
+    float float1 = 4.0, float2 = floatConst2;
+    int int_1 = int(FloatConst1);
+    vec4 vec4_1;
+    vec3 vec3_1 = vec3(1, 1, 1);
+	vec3 vec3_2 = vec3(0, 0, 0);
+//  unsigned int unsigned_int_1;
+    bool bool4, bool5;
+
+    bool4 = bool5;
+    //float1 = bool5;
+    //bool5 = float1;
+
+    bool4 = 4 > 5;
+    bool4 = !(3.2 != 0.0);
+    bool4 = bool(float1);
+    bool4 = bool(int_1);
+    float1 = float(bool4);
+    float1 = float(int_1);
+    int_1 = int(float1);
+    int_1 = int(bool4);
+
+    {
+        int a, b, c;
+
+        a = b;
+        b = c;
+        {
+            int b, c, d;
+
+            b = c;
+            c = d;
+            {
+                int a, d, e;
+
+                a = d;
+                d = e;
+            }
+            {
+                int a, b, c;
+                a = b;
+                b = c;
+            }
+        }
+        a = b;
+        b = c;
+    }
+
+    {
+        float f1, f2;
+        vec3 v31, v32;
+
+        max(f1, f2);
+        max(v31, v32);
+
+        vec4 v4 = vec4(3.0);
+        vec3 v3 = -vec3(2.0, 1.0, 3.0);
+        mat2 m2 = mat2(3.0, 4.0, 6.0, 3.0);
+        //mat4 m4 = mat4(1.0, m2, v3, v4, m2);
+    }
+
+    if (BoolConst1)
+        ++vec3_1;
+    else
+        --vec3_1;
+
+    if (BoolConst2)
+        ++vec3_1;
+    else
+        --vec3_1;
+
+    if (BoolConst1 || BoolConst2)
+        ++vec3_1;
+    else
+        --vec3_1;
+
+    if (BoolConst2 && BoolConst1)
+        ++vec3_1;
+    else
+        --vec3_1;
+
+    if (FloatConst1 != 0.0)
+        --int_1;
+    else
+        ++int_1;
+
+    if (0 != 0)
+        ++int_1;
+    else
+        --int_1;
+
+    bool4 = BoolConst1 && ! (int_1 != 0) && ! BoolConst1  && ! (FloatConst1 != 0.0) && (FloatConst1 != 0.0) && (float1 != 0.0);
+
+    float1 = 5 != 0 ? float1 : float(int_1);
+    float1 = BoolConst1 ? float1 : float(int_1);
+
+    if (float1 != float1)
+        ++int_1;
+    else
+        --int_1;
+
+    float1 = float1 != float1 ? float1 : float(int_1);
+
+    --int_1;
+    ++float1;
+    (vec4_1.x)--;
+    vec3_1++;
+
+    if (vec3_1.x > vec3_2.x)
+        float1 = 4.0 + 6.0;
+
+    if (bool4 ^^ bool5)
+        float1 *= 2.4;
+
+    if (false ^^ false)
+        float1 *= 2.5;
+
+    if (true ^^ false)
+        float1 *= 2.6;
+
+    {
+        int i;
+    }
+
+    if (bool4) {
+        int i;
+    } else {
+        int i;
+        i = 5;
+    }
+
+    mat4 m1;
+    m1[2][1] = 4.0;
+
+    gl_Position = vec4(float1+float1, float1, float1, float(int_1));
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest1_frag.frag
new file mode 100644
index 0000000..05c1061
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest1_frag.frag
@@ -0,0 +1,23 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    vec4 v;
+} s2;
+
+void main()
+{
+    s s1 = s(vec4(ivec4(4.0, vec2(5,6), 7.0)));
+    vec4 v = vec4(2,ivec2(3.0, 4.0), 5.0);
+    vec4 v4 = vec4(ivec4(8.0));
+
+    gl_FragColor = v4 + v + s1.v;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest_frag.frag
new file mode 100644
index 0000000..46b6ddc
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectParseTest_frag.frag
@@ -0,0 +1,26 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s{
+    float f;
+    vec3  v;
+} s1 ;
+void main()
+{
+    vec4 v = vec4(float(vec2(1,2)), 5,6,7);  // 1, 5, 6, 7
+    vec4 v1 = vec4(3, vec2(ivec2(1,2)), 4);  // 3, 1, 2, 4
+    vec4 v2 = vec4(8, 9, vec4(ivec4(1,2,3,4))); // 8,9, 1,2
+    vec2 v3 = vec2(v2);  // 8,9
+    vec4 v4 = vec4(v3, v2.z, v2.w);  // 8,9,1,2
+
+    const vec4 v5 = vec4(2.0, s(2.0, vec3(3,4,5)).v); // 2,3,4,5
+    gl_FragColor = v5 + v + v1 + v4 ;  // 14, 18, 13, 18
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess5_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess5_frag.frag
new file mode 100644
index 0000000..1dbac1a
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess5_frag.frag
@@ -0,0 +1,31 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+//mutiple line macros - test case.
+
+#define test 5
+#define t1 1
+#define t2 2
+#define token (t1+t2)
+#define test1 int sum =1; sum = test; sum = test+test;
+
+#define test2 { test1 sum = sum +token; sum = t2*t1; }
+
+void main(void)
+{
+ int test3=1;
+ test1
+ test2;
+ test3 = test;
+ sum = test3;
+}
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess8_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess8_frag.frag
new file mode 100644
index 0000000..01a3466
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess8_frag.frag
@@ -0,0 +1,115 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+// Extensive testing on #if #else #elif #ifdef, #ifndef and #endif.
+
+
+#define t1 1
+
+#if(t1==1)
+  #define t2 2
+#endif
+
+#if (t2!=2)
+  #define t3 33
+#else
+  #define t3 3
+#endif
+
+#if (t3!=3)
+ #define t4 4
+#elif (t3==3)
+ #define t4 44
+#else
+  #define t4 0
+#endif
+
+#if defined(t5)
+ #define t6 6
+#elif (t3!=3)
+ #define t5 5
+#elif (t3==3)
+ #define t5 5
+#endif
+
+#ifdef t5
+ #define t6 6
+#else
+ #define t7 7
+#endif
+
+#ifndef t8
+ #define t8 8
+#endif
+
+#if defined t8
+ #define t9
+ #ifdef t9
+  #define  t10 10
+ #endif
+#elif
+ #define t11 11
+#endif
+
+#ifndef t8
+ #define t12 12
+#else
+ #define t12 12
+ #ifndef t13
+  #define t13 13
+ #endif
+ #ifdef t14
+  #define t15 15
+ #else
+  #if defined t8
+   #define t16 16
+  #endif
+ #endif
+#endif
+
+#ifdef t1
+   #ifdef t10
+      #if defined t8
+         #if defined(t3)
+               #ifndef t20
+                  #define t25 25
+               #endif
+         #else
+            #define t15 15
+            #define t24 24
+         #endif
+      #endif
+   #endif
+#else
+   #ifdef t21
+     #define t22 22
+   #else
+     #define t23 23
+   #endif
+#endif
+#define t7 7
+#define t11 11
+#define t14 14
+#define t15 15
+#define t20 20
+#define t22 22
+#define t23 23
+#define t24 42
+
+void main(void)
+{
+ int sum =0;
+ sum = t1+t2+t3+t4+t5;
+ sum = t6+t7+t8+t9+t10;
+ sum = t11+t12+t13+t14+t15;
+ sum = t16+t20+t22+t23+t25+t24;
+}
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess9_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess9_frag.frag
new file mode 100644
index 0000000..4946312
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectPreprocess9_frag.frag
@@ -0,0 +1,32 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#define t1 2.3333333333333333
+#define t2 (0.978293600-1.0)
+#define t3 .9090909090
+#define t4 26578235.000000083487
+#define t5 78e-03
+#define t6 78.100005E+05
+#define t7 6278.78e-5
+
+void main(void){
+    float tes=2e-3;
+    float test=3.2e-5;
+    float test1=0.99995500;
+    float test2=6789.983;
+
+    test = t1+t2;
+    test = t3-t4;
+    tes  = t5 * t6;
+    test2 = t7;
+
+    gl_FragColor = vec4(test, tes, test1, test2);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_frag.frag
new file mode 100644
index 0000000..9226f18
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_frag.frag
@@ -0,0 +1,24 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec2 v = vec2(1,5);
+    // at the end of next statement, values in
+    // v.x = 12, v.y = 12
+    v.xy += v.yx += v.xy;
+    // v1 and v2, both are initialized with 12
+    vec2 v1 = v, v2 = v;
+
+    v1.xy += v2.yx += ++(v.xy);  // v1 = 37, v2 = 25 each
+    v1.xy += v2.yx += (v.xy)++;  // v1 = 75, v2 = 38 each
+    gl_FragColor = vec4(v1,v2);  // 75, 75, 38, 38
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_vert.vert
new file mode 100644
index 0000000..06ce3b3
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle1_vert.vert
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+attribute vec4 gtf_Normal;
+uniform mat4 gtf_NormalMatrix;
+void main(void)
+{
+   vec4 v = vec4(1,2,3,4);
+   vec3 v3 = vec3(5,6,7);
+   vec4 v4  = vec4(normalize(v3.yzy).xyz.zyx, 1.0);
+   gl_Position = v4 + vec4(normalize(gtf_NormalMatrix * gtf_Normal).xyz.zyx, v4.y);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_frag.frag
new file mode 100644
index 0000000..24074aa
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_frag.frag
@@ -0,0 +1,39 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f, f1, f2;
+    f = f1 = f2;
+    f += f1 += f2;
+
+    vec4 v, v1, v2;
+    v = v1 = v2;
+    v += v1 += v2;
+    v.wx = v1.zx = v2.yx;
+    v.wx += v1.zx += v2.yx;
+
+    mat4  m, m1, m2;
+    m = m1 = m2;
+    m += m1 += m2;
+    m[3].wx = m1[2].zx = m2[1].yx;
+    m[3].wx += m1[2].zx += m2[1].yx;
+
+    mat4  am[4], am1[4], am2[4];
+    am[3] = am1[2] = am2[1];
+    am[3] += am1[2] += am2[1];
+    am[3][3].wx = am1[2][2].zx = am2[1][1].yx;
+    am[3][3].wx += am1[2][2].zx += am2[1][1].yx;
+    am[3][3].wx += am1[2][2].zx += ++(am2[1][1].yx);
+    am[3][3].wx += am1[2][2].zx += (am2[1][1].yx)++;
+
+    gl_FragColor = vec4(am[3][3].z, m[3].w, v.w, f);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_vert.vert
new file mode 100644
index 0000000..b197cc0
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle2_vert.vert
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    vec4 v1 = vec4(5,6,7,8);
+    vec4 v2 = vec4(9,10, 11, 12);
+    vec3 v3 = (v1 * v2).ywx;
+    float f = (v2 * v1).z;
+    vec3 v4 = normalize((v1.ywx * v3).xyz).xyz;
+    gl_Position = vec4(v4, f);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle3_frag.frag
new file mode 100644
index 0000000..4f2665c
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectSwizzle3_frag.frag
@@ -0,0 +1,24 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec4 v = vec4(5,6,7,8);
+    // value changes for lhs
+    // 8765, 6758, 857, 75 i.e. replace v.zx
+    // value changes for rhs
+    // 8765, 6758, 86 i.e replace with v.wy
+    // replace v.z with v.w
+    // replace v.x with v.y
+    // add 1.000000 to v.w and v.y
+    v.wzyx.zywx.wzy.zy = (v.wzyx.zywx.wx)++;
+    gl_FragColor = vec4(v);  // 6,7,8,9
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectVersion_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectVersion_V100_frag.frag
new file mode 100644
index 0000000..1a0405a
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/CorrectVersion_V100_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#version 100
+#ifdef GL_ES
+precision mediump float;
+#endif
+/* #version can only be followed by number 100. The only statements before
+   #version can be comment or white spaces */
+
+void main()
+{
+   gl_FragColor = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/DuplicateVersion1_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/DuplicateVersion1_V100_frag.frag
new file mode 100644
index 0000000..fce81e5
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/DuplicateVersion1_V100_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#version 100
+#version 100
+#ifdef GL_ES
+precision mediump float;
+#endif
+/* Two version statements are not allowed since any #version must be the first non-whitespace, non-comment */
+
+void main()
+{
+   gl_FragColor = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/FunctionParam_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/FunctionParam_vert.vert
new file mode 100644
index 0000000..4b74943
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/FunctionParam_vert.vert
@@ -0,0 +1,21 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+int y = 1;
+
+int foo(int, int b[y])  // array size should be constant
+{
+    return 1;
+}
+
+void main()
+{
+    int a[1];
+
+    gl_Position = vec4(1.0);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Include_Preprocessor_Directive_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Include_Preprocessor_Directive_frag.frag
new file mode 100644
index 0000000..0b7d674
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Include_Preprocessor_Directive_frag.frag
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#include "GL/build/NVIDIA_Test_Include_frag.frag"
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Low_Level_Assembly_Reserved_Words_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Low_Level_Assembly_Reserved_Words_frag.frag
new file mode 100644
index 0000000..4086830
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Low_Level_Assembly_Reserved_Words_frag.frag
@@ -0,0 +1,27 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform float MIN;
+uniform float R0;
+uniform float FOGC;
+uniform float CUBE;
+uniform float f;
+uniform float o;
+uniform float p;
+uniform float w;
+uniform float x;
+uniform float y;
+uniform float z;
+
+void main()
+{
+	gl_FragColor = vec4(f, o, p, w);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Main_Parameters_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Main_Parameters_vert.vert
new file mode 100644
index 0000000..200f39d
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Main_Parameters_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main(vec4 position : POSITION)
+{
+	gl_Position = position;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest3_frag.frag
new file mode 100644
index 0000000..1242467
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest3_frag.frag
@@ -0,0 +1,20 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    const vec4 v = vec4(normalize(vec4(1)));    // Builtin functions are constant expressions if all their parameters are constant expressions - code ok
+    const vec4 v1 = vec4(clamp(1.0, .20, 3.0)); // Builtin functions are constant expressions if all their parameters are constant expressions - code ok
+    float f = 1.0;
+    const vec4 v2 = vec4(float(vec4(1,2,3,f))); // f is not constant - code fails and test does not compile (expected)
+
+    gl_FragColor = v + v1 + v2;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest4_frag.frag
new file mode 100644
index 0000000..60ef6d3
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/ParseTest4_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    const vec4 v = vec2(2.0, 3.0);
+    gl_FragColor = v;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Constant_Conversions_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Constant_Conversions_frag.frag
new file mode 100644
index 0000000..526d62b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Constant_Conversions_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+	float f = 2; // Should be 2.0
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Scalar_Vector_Expressions_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Scalar_Vector_Expressions_frag.frag
new file mode 100644
index 0000000..cc67c7f
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Permissive_Scalar_Vector_Expressions_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+	vec2 v = vec2(1.0, 2.0);
+	v *= 2.0; // Legal in GLSL.
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/TernaryOp_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/TernaryOp_frag.frag
new file mode 100644
index 0000000..2356f00
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/TernaryOp_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    mat4 m;
+    vec4 v;
+    bool b;
+    gl_FragColor = b ? v : m;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Texture_Rectangle_Samplers_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Texture_Rectangle_Samplers_frag.frag
new file mode 100644
index 0000000..48bb0d6
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/Texture_Rectangle_Samplers_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform sampler2DRect samp;
+
+void main()
+{
+	gl_FragColor = texture2DRect(samp, vec2(0.0, 0.0));
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array10_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array10_frag.frag
new file mode 100644
index 0000000..a46681c
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array10_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+
+void main()
+{
+    float f[];
+    float flt = f[5];
+    float f[3];  // higher array index has already been used
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array11_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array11_frag.frag
new file mode 100644
index 0000000..dfd7abd
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array11_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f[];
+    int f[4];  // array redeclared with a different type
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array1_frag.frag
new file mode 100644
index 0000000..ab402ba
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array1_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int array[2][2];  // two dimentional arrays are not allowed
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array2_frag.frag
new file mode 100644
index 0000000..37d0cbc
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array2_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    const int array[2];  // cannot declare const arrays
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array3_frag.frag
new file mode 100644
index 0000000..d8d7061
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array3_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int array1[2], array2[2];
+    bool b = array1 == array2; // equality operator does not work on arrays but works on array elements
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array4_frag.frag
new file mode 100644
index 0000000..92abeb8
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array4_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f[-2]; // cannot declare arrays with negative size
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array5_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array5_frag.frag
new file mode 100644
index 0000000..e413562
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array5_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i = 3;
+    float f[i]; // arrays should be declared with a constant size
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array6_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array6_frag.frag
new file mode 100644
index 0000000..483f49a
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array6_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    const float index = 3.0;
+    float f[index];  // arrays should be declared with an integer expression not float
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array7_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array7_frag.frag
new file mode 100644
index 0000000..44dd6e6
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array7_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f[5];
+    f[];  // array used without a size
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array8_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array8_frag.frag
new file mode 100644
index 0000000..97db881
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array8_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f[5];
+    float f[];  // redeclaration of array already declared with a size
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array9_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array9_frag.frag
new file mode 100644
index 0000000..f75edc7
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/array9_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec2 array[2];
+    array.xy;  // arrays cannot directly be swizzled, however, an element of array can be swizzled
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute1_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute1_vert.vert
new file mode 100644
index 0000000..bb2f1be
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute1_vert.vert
@@ -0,0 +1,14 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+attribute int i;  // attributes cannot be int or bool
+
+void main()
+{
+    gl_Position = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute2_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute2_vert.vert
new file mode 100644
index 0000000..2e3309b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute2_vert.vert
@@ -0,0 +1,14 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+attribute float f[2];  // attributes cannot be arrays
+
+void main()
+{
+    gl_Position = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_frag.frag
new file mode 100644
index 0000000..894197b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    attribute float foo;  // attributes can be declared at global scope in vertex shader only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_vert.vert
new file mode 100644
index 0000000..9cf1629
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/attribute_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    attribute float foo;  // attributes can be declared at a global scope only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/break_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/break_frag.frag
new file mode 100644
index 0000000..6bfdcbd
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/break_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    break; // break keyword allowed only inside the loops
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html
new file mode 100644
index 0000000..3ff10f4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_001_to_008.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_001_to_008.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectBuiltInOveride_frag.frag"
+      },
+      "name": "CorrectBuiltInOveride_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectComma_frag.frag"
+      },
+      "name": "CorrectComma_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectConstFolding1_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectConstFolding1_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectConstFolding2_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectConstFolding2_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectConstruct_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectConstruct_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectExtension10_V100_frag.frag"
+      },
+      "name": "CorrectExtension10_V100_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectExtension1_V100_frag.frag"
+      },
+      "name": "CorrectExtension1_V100_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectExtension4_V100_frag.frag"
+      },
+      "name": "CorrectExtension4_V100_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html
new file mode 100644
index 0000000..c3f6658
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_009_to_016.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_009_to_016.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectFull_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectFull_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectFuncOverload_frag.frag"
+      },
+      "name": "CorrectFuncOverload_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectFuncOverload_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectFuncOverload_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectFunction1_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectFunction1_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectModule_frag.frag"
+      },
+      "name": "CorrectModule_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectParse1_frag.frag"
+      },
+      "name": "CorrectParse1_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectParse2_frag.frag"
+      },
+      "name": "CorrectParse2_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectParse2_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectParse2_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html
new file mode 100644
index 0000000..1869eca
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_017_to_024.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_017_to_024.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectParseTest1_frag.frag"
+      },
+      "name": "CorrectParseTest1_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectParseTest_frag.frag"
+      },
+      "name": "CorrectParseTest_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectPreprocess5_frag.frag"
+      },
+      "name": "CorrectPreprocess5_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectPreprocess8_frag.frag"
+      },
+      "name": "CorrectPreprocess8_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectPreprocess9_frag.frag"
+      },
+      "name": "CorrectPreprocess9_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectSwizzle1_frag.frag"
+      },
+      "name": "CorrectSwizzle1_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectSwizzle1_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectSwizzle1_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectSwizzle2_frag.frag"
+      },
+      "name": "CorrectSwizzle2_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html
new file mode 100644
index 0000000..132f0ce
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_025_to_032.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_025_to_032.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "CorrectSwizzle2_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "CorrectSwizzle2_vert.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectSwizzle3_frag.frag"
+      },
+      "name": "CorrectSwizzle3_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "DuplicateVersion1_V100_frag.frag"
+      },
+      "name": "DuplicateVersion1_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "CorrectVersion_V100_frag.frag"
+      },
+      "name": "CorrectVersion_V100_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "FunctionParam_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "FunctionParam_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "ParseTest3_frag.frag"
+      },
+      "name": "ParseTest3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "ParseTest4_frag.frag"
+      },
+      "name": "ParseTest4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array10_frag.frag"
+      },
+      "name": "array10_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html
new file mode 100644
index 0000000..52c70b7
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_033_to_040.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_033_to_040.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array11_frag.frag"
+      },
+      "name": "array11_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array1_frag.frag"
+      },
+      "name": "array1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array2_frag.frag"
+      },
+      "name": "array2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array3_frag.frag"
+      },
+      "name": "array3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array4_frag.frag"
+      },
+      "name": "array4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array5_frag.frag"
+      },
+      "name": "array5_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array6_frag.frag"
+      },
+      "name": "array6_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array7_frag.frag"
+      },
+      "name": "array7_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html
new file mode 100644
index 0000000..c516edb
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_041_to_048.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_041_to_048.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array8_frag.frag"
+      },
+      "name": "array8_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "array9_frag.frag"
+      },
+      "name": "array9_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "attribute1_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "attribute1_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "attribute2_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "attribute2_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "attribute_frag.frag"
+      },
+      "name": "attribute_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "attribute_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "attribute_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "break_frag.frag"
+      },
+      "name": "break_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "comma1_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "comma1_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html
new file mode 100644
index 0000000..db09be9
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_049_to_056.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_049_to_056.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "comma2_frag.frag"
+      },
+      "name": "comma2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "comma2_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "comma2_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "comma3_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "comma3_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "comment_frag.frag"
+      },
+      "name": "comment_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "conditional1_frag.frag"
+      },
+      "name": "conditional1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "conditional2_frag.frag"
+      },
+      "name": "conditional2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "conditional3_frag.frag"
+      },
+      "name": "conditional3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "constFunc_frag.frag"
+      },
+      "name": "constFunc_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html
new file mode 100644
index 0000000..8ce48b7
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_057_to_064.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_057_to_064.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "constructor1_frag.frag"
+      },
+      "name": "constructor1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "constructor2_frag.frag"
+      },
+      "name": "constructor2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "constructor3_V100_frag.frag"
+      },
+      "name": "constructor3_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "continue_frag.frag"
+      },
+      "name": "continue_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType10_frag.frag"
+      },
+      "name": "dataType10_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType11_frag.frag"
+      },
+      "name": "dataType11_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType12_frag.frag"
+      },
+      "name": "dataType12_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType13_frag.frag"
+      },
+      "name": "dataType13_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html
new file mode 100644
index 0000000..cf5b021
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_065_to_072.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_065_to_072.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType19_frag.frag"
+      },
+      "name": "dataType19_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType1_frag.frag"
+      },
+      "name": "dataType1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType2_frag.frag"
+      },
+      "name": "dataType2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType3_frag.frag"
+      },
+      "name": "dataType3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType4_frag.frag"
+      },
+      "name": "dataType4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType5_frag.frag"
+      },
+      "name": "dataType5_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType6_frag.frag"
+      },
+      "name": "dataType6_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType7_frag.frag"
+      },
+      "name": "dataType7_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html
new file mode 100644
index 0000000..a09643f
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_073_to_080.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_073_to_080.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType8_frag.frag"
+      },
+      "name": "dataType8_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dataType9_frag.frag"
+      },
+      "name": "dataType9_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dowhile_frag.frag"
+      },
+      "name": "dowhile_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dvec2_frag.frag"
+      },
+      "name": "dvec2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dvec3_frag.frag"
+      },
+      "name": "dvec3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "dvec4_frag.frag"
+      },
+      "name": "dvec4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "extension2_V100_frag.frag"
+      },
+      "name": "extension2_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "extension3_V100_frag.frag"
+      },
+      "name": "extension3_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html
new file mode 100644
index 0000000..3a06c23
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_081_to_088.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_081_to_088.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "extension5_V100_frag.frag"
+      },
+      "name": "extension5_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "extension6_V100_frag.frag"
+      },
+      "name": "extension6_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "extension7_V100_frag.frag"
+      },
+      "name": "extension7_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "extension8_V100_frag.frag"
+      },
+      "name": "extension8_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "extension9_V100_frag.frag"
+      },
+      "name": "extension9_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "float2_frag.frag"
+      },
+      "name": "float2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "float3_frag.frag"
+      },
+      "name": "float3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "float4_frag.frag"
+      },
+      "name": "float4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html
new file mode 100644
index 0000000..992594a
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_089_to_096.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_089_to_096.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "fragmentOnly1_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "fragmentOnly1_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "fragmentOnly2_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "fragmentOnly2_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "fragmentOnly3_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "fragmentOnly3_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "fragmentOnly4_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "fragmentOnly4_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "fragmentOnly_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "fragmentOnly_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function10_frag.frag"
+      },
+      "name": "function10_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function1_frag.frag"
+      },
+      "name": "function1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function2_V100_frag.frag"
+      },
+      "name": "function2_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html
new file mode 100644
index 0000000..27ce540
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_097_to_104.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_097_to_104.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function3_frag.frag"
+      },
+      "name": "function3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function4_frag.frag"
+      },
+      "name": "function4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function6_frag.frag"
+      },
+      "name": "function6_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function7_frag.frag"
+      },
+      "name": "function7_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function8_frag.frag"
+      },
+      "name": "function8_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "function9_frag.frag"
+      },
+      "name": "function9_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "hvec2_frag.frag"
+      },
+      "name": "hvec2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "hvec3_frag.frag"
+      },
+      "name": "hvec3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html
new file mode 100644
index 0000000..684fa98
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_105_to_112.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_105_to_112.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "hvec4_frag.frag"
+      },
+      "name": "hvec4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "identifier1_frag.frag"
+      },
+      "name": "identifier1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "identifier2_frag.frag"
+      },
+      "name": "identifier2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "identifier3_frag.frag"
+      },
+      "name": "identifier3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "if1_frag.frag"
+      },
+      "name": "if1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "if2_frag.frag"
+      },
+      "name": "if2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "increment1_frag.frag"
+      },
+      "name": "increment1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "increment2_frag.frag"
+      },
+      "name": "increment2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html
new file mode 100644
index 0000000..5c18100
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_113_to_120.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_113_to_120.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "increment3_frag.frag"
+      },
+      "name": "increment3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "increment4_frag.frag"
+      },
+      "name": "increment4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "increment6_frag.frag"
+      },
+      "name": "increment6_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "main1_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "main1_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "main2_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "main2_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "main3_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "main3_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "matrix_V100_frag.frag"
+      },
+      "name": "matrix_V100_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "normal_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "normal_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html
new file mode 100644
index 0000000..d645465
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_121_to_128.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_121_to_128.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "parser10_frag.frag"
+      },
+      "name": "parser10_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "parser1_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "parser1_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "parser3_frag.frag"
+      },
+      "name": "parser3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "parser4_frag.frag"
+      },
+      "name": "parser4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "parser5_frag.frag"
+      },
+      "name": "parser5_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "parser6_frag.frag"
+      },
+      "name": "parser6_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "parser7_frag.frag"
+      },
+      "name": "parser7_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "parser8_frag.frag"
+      },
+      "name": "parser8_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html
new file mode 100644
index 0000000..9abe40c
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_129_to_136.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_129_to_136.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "parser9_frag.frag"
+      },
+      "name": "parser9_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "preprocess0_frag.frag"
+      },
+      "name": "preprocess0_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "preprocess10_frag.frag"
+      },
+      "name": "preprocess10_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "preprocess1_frag.frag"
+      },
+      "name": "preprocess1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "preprocess2_frag.frag"
+      },
+      "name": "preprocess2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "preprocess3_frag.frag"
+      },
+      "name": "preprocess3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "preprocess4_frag.frag"
+      },
+      "name": "preprocess4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "preprocess6_frag.frag"
+      },
+      "name": "preprocess6_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html
new file mode 100644
index 0000000..48d2338
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_137_to_144.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_137_to_144.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "preprocess7_frag.frag"
+      },
+      "name": "preprocess7_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "scoping1_frag.frag"
+      },
+      "name": "scoping1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "scoping2_frag.frag"
+      },
+      "name": "scoping2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct10_frag.frag"
+      },
+      "name": "struct10_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct11_frag.frag"
+      },
+      "name": "struct11_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct1_frag.frag"
+      },
+      "name": "struct1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct2_frag.frag"
+      },
+      "name": "struct2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct3_frag.frag"
+      },
+      "name": "struct3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html
new file mode 100644
index 0000000..08920dd
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_145_to_152.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_145_to_152.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct4_frag.frag"
+      },
+      "name": "struct4_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct5_frag.frag"
+      },
+      "name": "struct5_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct6_frag.frag"
+      },
+      "name": "struct6_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct7_frag.frag"
+      },
+      "name": "struct7_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct8_frag.frag"
+      },
+      "name": "struct8_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "struct9_frag.frag"
+      },
+      "name": "struct9_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "swizzle1_frag.frag"
+      },
+      "name": "swizzle1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "swizzle2_frag.frag"
+      },
+      "name": "swizzle2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html
new file mode 100644
index 0000000..eb950e3
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_153_to_160.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_153_to_160.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "swizzle3_frag.frag"
+      },
+      "name": "swizzle3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "typecast_frag.frag"
+      },
+      "name": "typecast_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "uniform1_frag.frag"
+      },
+      "name": "uniform1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "uniform_frag.frag"
+      },
+      "name": "uniform_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "varying1_frag.frag"
+      },
+      "name": "varying1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "varying2_frag.frag"
+      },
+      "name": "varying2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "varying3_frag.frag"
+      },
+      "name": "varying3_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "varying_frag.frag"
+      },
+      "name": "varying_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html
new file mode 100644
index 0000000..9c66171
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_161_to_168.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_161_to_168.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "vector_frag.frag"
+      },
+      "name": "vector_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "version2_V100_frag.frag"
+      },
+      "name": "version2_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "version3_V100_frag.frag"
+      },
+      "name": "version3_V100_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "vertexOnly2_frag.frag"
+      },
+      "name": "vertexOnly2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "vertexOnly_frag.frag"
+      },
+      "name": "vertexOnly_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "vertex_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "vertex_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "while1_frag.frag"
+      },
+      "name": "while1_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "while2_frag.frag"
+      },
+      "name": "while2_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html
new file mode 100644
index 0000000..1bd3c63
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_169_to_176.html
@@ -0,0 +1,111 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_169_to_176.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "while_frag.frag"
+      },
+      "name": "while_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "../default/default.vert",
+        "fragmentShader": "TernaryOp_frag.frag"
+      },
+      "name": "TernaryOp_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "default.vert",
+        "fragmentShader": "CG_Data_Types_frag.frag"
+      },
+      "name": "CG_Data_Types_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "default.vert",
+        "fragmentShader": "CG_Standard_Library_frag.frag"
+      },
+      "name": "CG_Standard_Library_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "default.vert",
+        "fragmentShader": "Include_Preprocessor_Directive_frag.frag"
+      },
+      "name": "Include_Preprocessor_Directive_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "default.vert",
+        "fragmentShader": "Low_Level_Assembly_Reserved_Words_frag.frag"
+      },
+      "name": "Low_Level_Assembly_Reserved_Words_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "Main_Parameters_vert.vert",
+        "fragmentShader": "default.frag"
+      },
+      "name": "Main_Parameters_vert.test.html",
+      "linkstat": false,
+      "compstat": false
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "default.vert",
+        "fragmentShader": "Permissive_Constant_Conversions_frag.frag"
+      },
+      "name": "Permissive_Constant_Conversions_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html
new file mode 100644
index 0000000..cdc2b38
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/build_177_to_178.html
@@ -0,0 +1,51 @@
+<!DOCTYPE html>
+<!-- this file is auto-generated. DO NOT EDIT. -->
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL conformance test: build_177_to_178.html</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css" />
+<link rel="stylesheet" href="../../../../resources/ogles-tests.css" />
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+<script src="../../ogles-utils.js"></script>
+</head>
+<body>
+<canvas id="example" width="500" height="500" style="width: 16px; height: 16px;"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+</body>
+<script>
+"use strict";
+OpenGLESTestRunner.run({
+  "tests": [
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "default.vert",
+        "fragmentShader": "Permissive_Scalar_Vector_Expressions_frag.frag"
+      },
+      "name": "Permissive_Scalar_Vector_Expressions_frag.test.html",
+      "linkstat": true,
+      "compstat": true
+    },
+    {
+      "pattern": "build",
+      "testProgram": {
+        "vertexShader": "default.vert",
+        "fragmentShader": "Texture_Rectangle_Samplers_frag.frag"
+      },
+      "name": "Texture_Rectangle_Samplers_frag.test.html",
+      "linkstat": false,
+      "compstat": false
+    }
+  ]
+});
+var successfullyParsed = true;
+</script>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma1_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma1_vert.vert
new file mode 100644
index 0000000..26473e4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma1_vert.vert
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    int i, j, k;
+    float f;
+    i = j, k, f;
+    i = (j, k, f);   // float cannot be assigned to int
+    gl_Position = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_frag.frag
new file mode 100644
index 0000000..c7061f7
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    const vec4 v = (vec4(1,2,3,4), vec4(5,6,7,8), 1.2); // right most value of comma operator shoul be a vec4
+    const vec4 v1 = (vec3(0.2, 2.0), vec4(1,2,3,4), vec4(5,6,7,8));
+    const vec4 v2 = (vec4(1,2,3,4), vec2(2.1, 2),  vec4(5,6,7,8));
+    gl_FragColor = v + v1 + v2;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_vert.vert
new file mode 100644
index 0000000..9c32368
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma2_vert.vert
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    int i, j, k;
+    float f;
+    i = j, k, f;
+    i = (j = k, f = 1.0);   // float cannot be assigned to int
+    gl_Position = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma3_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma3_vert.vert
new file mode 100644
index 0000000..9edcb98
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comma3_vert.vert
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    int i, j, k;
+    float f;
+    i = j, k, f;
+    i = j = k, f = 1.0;
+    i = j, k = (3, f);    // float cannot be assigned to int
+    gl_Position = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comment_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comment_frag.frag
new file mode 100644
index 0000000..8d0a382
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/comment_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    /******  // comment not closed
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional1_frag.frag
new file mode 100644
index 0000000..eb830f4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional1_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f1,f2;
+    int i;
+    float f3 = i ? f1 : f2;  // expression must be boolean and not int
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional2_frag.frag
new file mode 100644
index 0000000..451a8bd
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional2_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f1,f2;
+    int i;
+    bool b;
+    float f3 = b ? i : f2; // second and third expression should of the type float
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional3_frag.frag
new file mode 100644
index 0000000..65b1b46
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/conditional3_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f1,f2;
+    bool b;
+    int i = b ? f1 : f2; // second and third expression type does not match the lvalue type
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constFunc_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constFunc_frag.frag
new file mode 100644
index 0000000..8e3a2a6
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constFunc_frag.frag
@@ -0,0 +1,22 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+vec2 func()
+{
+    vec2 v;
+    return v;
+}
+
+void main()
+{
+    const vec3 v = vec3(1.0, func()); // user defined functions do not return const value
+    gl_FragColor = vec4(v, v);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor1_frag.frag
new file mode 100644
index 0000000..ff73bcd
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor1_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec4 v = vec4(1,2,3); // insufficient data provided for constructor, 4 values are required
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor2_frag.frag
new file mode 100644
index 0000000..127bdba
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor2_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec3 v;
+    vec4 v1 = vec4(v); // insufficient data specified for construction
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor3_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor3_V100_frag.frag
new file mode 100644
index 0000000..5312587
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/constructor3_V100_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec3 v;
+    vec4 v1 = vec4(v,v,v); // too many arguments in the constructor
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/continue_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/continue_frag.frag
new file mode 100644
index 0000000..bdf83e2
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/continue_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    continue; // continue keyword allowed only inside the loops
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType10_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType10_frag.frag
new file mode 100644
index 0000000..4456d64
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType10_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f;
+    float f;  // redeclaration of a variable
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType11_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType11_frag.frag
new file mode 100644
index 0000000..ffecbbf
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType11_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i = 08;  // invalid octal number
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType12_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType12_frag.frag
new file mode 100644
index 0000000..4cf8b18
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType12_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i = 0xa8g;  // invalid hexadecimal number
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType13_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType13_frag.frag
new file mode 100644
index 0000000..7a21e6f
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType13_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i = 1;
+    float f = 1.2;
+    float result = f * i; // auto promotion now allowed
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType19_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType19_frag.frag
new file mode 100644
index 0000000..fb98c75
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType19_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform sampler2D s;
+void main()
+{
+    int i = int(s); // conversion not allowed
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType1_frag.frag
new file mode 100644
index 0000000..6f3baa2
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType1_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    void v; // variable cannot be declared of the type void
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType2_frag.frag
new file mode 100644
index 0000000..dec2aa0
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType2_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform sampler2D samp1;
+uniform sampler2D samp2 = samp1; // uniforms are read only
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType3_frag.frag
new file mode 100644
index 0000000..726ba88
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType3_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform int i = 1; // uniforms are read only
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType4_frag.frag
new file mode 100644
index 0000000..8baea0a
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType4_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i = 1.0;  // automatic type conversion does not take place, float cannot be converted to int
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType5_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType5_frag.frag
new file mode 100644
index 0000000..7e1ff75
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType5_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f = 1; // int cannot be converted to float, use constructor to do the conversion explicitly
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType6_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType6_frag.frag
new file mode 100644
index 0000000..e6ff421
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType6_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    const float f;  // constants must be initialized
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType7_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType7_frag.frag
new file mode 100644
index 0000000..be31a3c
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType7_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform float f;
+void main()
+{
+    f = 1.0;  // uniforms are read only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType8_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType8_frag.frag
new file mode 100644
index 0000000..dddecc4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType8_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+varying float f;
+void main()
+{
+    f = 1.0;  // varyings cannot be written to in a fragment shader, they can be written to in a vertex shader
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType9_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType9_frag.frag
new file mode 100644
index 0000000..1029d3d
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dataType9_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+varying float f;
+void main()
+{
+    float flt = 1.0;
+    flt++;
+    f++;  // varyings in a fragment shader are read only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.frag
new file mode 100644
index 0000000..af7b0e0
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main (void)
+{
+	gl_FragColor = vec4(1.0, 1.0, 1.0, 1.0);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.vert
new file mode 100644
index 0000000..8c736ab
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/default.vert
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+attribute vec4 gtf_Vertex;
+uniform mat4 gtf_ModelViewProjectionMatrix;
+void main (void)
+{
+	gl_Position = gtf_ModelViewProjectionMatrix * gtf_Vertex;
+	gl_PointSize = 1.0;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dowhile_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dowhile_frag.frag
new file mode 100644
index 0000000..4143dc4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dowhile_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f;
+    do {
+    } while(f);  // condition should be boolean
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec2_frag.frag
new file mode 100644
index 0000000..9451b55
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec2_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    dvec2 d; // dvec2 is not a valid datatype, reserved for future use
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec3_frag.frag
new file mode 100644
index 0000000..b7f7817
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec3_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    dvec3 d; // dvec3 is not a valid datatype, reserved for future use
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec4_frag.frag
new file mode 100644
index 0000000..56beb6a
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/dvec4_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    dvec4 d; // dvec4 is not a valid datatype, reserved for future use
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension2_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension2_V100_frag.frag
new file mode 100644
index 0000000..085a7e3
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension2_V100_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#extension all : require // cannot use require or enable with all
+#extension all : enable // cannot use require or enable with all
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension3_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension3_V100_frag.frag
new file mode 100644
index 0000000..0005c14
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension3_V100_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#extension foo : require  // error extension not supported
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension5_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension5_V100_frag.frag
new file mode 100644
index 0000000..6198d6f
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension5_V100_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#extension all : ddisablee  // error, behavior is not supported
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension6_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension6_V100_frag.frag
new file mode 100644
index 0000000..6a33fa4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension6_V100_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#extension   // error name and behavior not specified
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension7_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension7_V100_frag.frag
new file mode 100644
index 0000000..0e636d5
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension7_V100_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#extension foo  // ":" missing after extension name
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension8_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension8_V100_frag.frag
new file mode 100644
index 0000000..7c12432
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension8_V100_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#extension foo : //  behavior not specified
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension9_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension9_V100_frag.frag
new file mode 100644
index 0000000..dd7d69d
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/extension9_V100_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+#extension foo  behavior // ":" missing after extension name
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float2_frag.frag
new file mode 100644
index 0000000..23a31ca
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float2_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float2 f; // float2 is not a valid datatype
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float3_frag.frag
new file mode 100644
index 0000000..a73d3d4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float3_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float3 f; // float3 is not a valid datatype
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float4_frag.frag
new file mode 100644
index 0000000..d381373
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/float4_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float4 f; // float4 is not a valid datatype
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly1_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly1_vert.vert
new file mode 100644
index 0000000..5ebba33
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly1_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    gl_FrontFacing = true;  // can be used in fragment shader only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly2_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly2_vert.vert
new file mode 100644
index 0000000..480056b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly2_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    gl_FragCoord = vec4(1.0);  // can be used in fragment shader only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly3_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly3_vert.vert
new file mode 100644
index 0000000..8e9cb00
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly3_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    gl_FragColor = vec4(1.0);  // can be used in fragment shader only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly4_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly4_vert.vert
new file mode 100644
index 0000000..4f64483
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly4_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    discard;  // can be used in fragment shader only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly_vert.vert
new file mode 100644
index 0000000..28ea00e
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/fragmentOnly_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    gl_FragDepth = 1.0;  // can be used in fragment shader only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function10_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function10_frag.frag
new file mode 100644
index 0000000..17dfadb
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function10_frag.frag
@@ -0,0 +1,24 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void function(in int i);
+
+void main()
+{
+    float f;
+    // overloaded function not present
+    function(f);
+}
+
+void function(in int i)
+{
+   i = 3;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function1_frag.frag
new file mode 100644
index 0000000..a3327a6
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function1_frag.frag
@@ -0,0 +1,23 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void function(int i)
+{
+    return i;  // void function cannot return a value
+}
+
+void main()
+{
+    int i;
+    function(i);
+}
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function2_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function2_V100_frag.frag
new file mode 100644
index 0000000..5b9d57d
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function2_V100_frag.frag
@@ -0,0 +1,22 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void function(int i[])  // size of array must be specified
+{
+}
+
+void main()
+{
+    int i[2];
+    function(i);
+}
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function3_frag.frag
new file mode 100644
index 0000000..44835de
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function3_frag.frag
@@ -0,0 +1,23 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void function(const int i)
+{
+    i = 3;  // const value cant be modified
+}
+
+void main()
+{
+    int i;
+    function(i);
+}
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function4_frag.frag
new file mode 100644
index 0000000..eeabde9
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function4_frag.frag
@@ -0,0 +1,23 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform int uniformInt;
+
+void function(out int i)
+{
+    i = 1;
+}
+
+void main()
+{
+    function(uniformInt);  // out and inout parameters cannot be uniform since uniforms cannot be modified
+}
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function6_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function6_frag.frag
new file mode 100644
index 0000000..cbcc433
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function6_frag.frag
@@ -0,0 +1,23 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void function(const out int i)
+{  // out parameters cannot be const
+   i = 3;
+}
+
+void main()
+{
+    int i;
+    function(i);
+}
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function7_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function7_frag.frag
new file mode 100644
index 0000000..4c09028
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function7_frag.frag
@@ -0,0 +1,22 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void function(uniform int i)
+{  // uniform qualifier cannot be used with function parameters
+}
+
+void main()
+{
+    int i;
+    function(i);
+}
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function8_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function8_frag.frag
new file mode 100644
index 0000000..debe6e8
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function8_frag.frag
@@ -0,0 +1,23 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void function(const inout int i)
+{  // inout parameters cannot be const
+   i = 3;
+}
+
+void main()
+{
+    int i;
+    function(i);
+}
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function9_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function9_frag.frag
new file mode 100644
index 0000000..96af74b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/function9_frag.frag
@@ -0,0 +1,24 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void function(inout int i);
+
+void main()
+{
+    int i;
+    function(i);
+}
+
+// function definition has different parameter qualifiers than function declaration
+void function(in int i)
+{
+   i = 3;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec2_frag.frag
new file mode 100644
index 0000000..8911b69
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec2_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    hvec2 f; // hvec2 is not a valid datatype, reserved for future use
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec3_frag.frag
new file mode 100644
index 0000000..a3b61df
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec3_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    hvec3 f; // hvec3 is not a valid datatype, reserved for future use
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec4_frag.frag
new file mode 100644
index 0000000..94e7970
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/hvec4_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    hvec4 f; // hvec4 is not a valid datatype, reserved for future use
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier1_frag.frag
new file mode 100644
index 0000000..70d1d9c
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier1_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int 1i; // incorrect identifier name
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier2_frag.frag
new file mode 100644
index 0000000..316e934
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier2_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int gl_int;  // identifier name cannot begin with "gl_"
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier3_frag.frag
new file mode 100644
index 0000000..9bbeaf6
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/identifier3_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i;
+    x;  // identifier x used without being declared
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/if1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/if1_frag.frag
new file mode 100644
index 0000000..0301684
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/if1_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i;
+    if (i) // condition of if statement must be a boolean
+        i++;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/if2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/if2_frag.frag
new file mode 100644
index 0000000..04fbfdf
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/if2_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec2 v;
+    int i;
+    if (v) // vectors cannot be used as conditional expression for if statement
+        i++;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment1_frag.frag
new file mode 100644
index 0000000..4eeb5b6
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment1_frag.frag
@@ -0,0 +1,20 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    int i;
+} s1;
+
+void main()
+{
+   s1.i++;
+   s1++;  // structure cannot be incremented
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment2_frag.frag
new file mode 100644
index 0000000..561678b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment2_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i;
+    (i+i)++;  // i+i is not an l-value
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment3_frag.frag
new file mode 100644
index 0000000..0a32504
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment3_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform sampler2D sampler2d;
+
+void main()
+{
+    sampler2d++;  // uniforms cannot be modified
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment4_frag.frag
new file mode 100644
index 0000000..23ff6b4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment4_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i;
+    i++ = 5;  // i++ is not an l-value
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment6_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment6_frag.frag
new file mode 100644
index 0000000..0bc5004
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/increment6_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i;
+    ++i++;  // ++i++ is equivalent to ++(i++) which fails because i++ is not an lvalue.  (++i)++; is legal.
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/input.run.txt b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/input.run.txt
new file mode 100644
index 0000000..78dde7d
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/input.run.txt
@@ -0,0 +1,24 @@
+# this file is auto-generated. DO NOT EDIT.
+build_001_to_008.html
+build_009_to_016.html
+build_017_to_024.html
+build_025_to_032.html
+build_033_to_040.html
+build_041_to_048.html
+build_049_to_056.html
+build_057_to_064.html
+build_065_to_072.html
+build_073_to_080.html
+build_081_to_088.html
+build_089_to_096.html
+build_097_to_104.html
+build_105_to_112.html
+build_113_to_120.html
+build_121_to_128.html
+build_129_to_136.html
+build_137_to_144.html
+build_145_to_152.html
+build_153_to_160.html
+build_161_to_168.html
+build_169_to_176.html
+build_177_to_178.html
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main1_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main1_vert.vert
new file mode 100644
index 0000000..95c2663
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main1_vert.vert
@@ -0,0 +1,11 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+main() // return type of main should be void
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main2_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main2_vert.vert
new file mode 100644
index 0000000..8cdfe98b4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main2_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main(int i)  // main function cannot take any parameters
+{
+    gl_Position = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main3_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main3_vert.vert
new file mode 100644
index 0000000..09a21a9
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/main3_vert.vert
@@ -0,0 +1,12 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+int main() // return type of main should be void
+{
+   return 1;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/matrix_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/matrix_V100_frag.frag
new file mode 100644
index 0000000..f3dc0ad
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/matrix_V100_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    mat3 m;
+    mat4 m1 = mat4(m);
+}
\ No newline at end of file
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/normal_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/normal_vert.vert
new file mode 100644
index 0000000..369bce9
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/normal_vert.vert
@@ -0,0 +1,13 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+attribute vec4 gtf_Normal;
+void main()
+{
+    gtf_Normal = vec3(1.0,2.0,3.0);  // cannot be modified an attribute
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser10_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser10_frag.frag
new file mode 100644
index 0000000..6c25734
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser10_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    5 += 5; // l-value missing
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser1_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser1_vert.vert
new file mode 100644
index 0000000..90a6263
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser1_vert.vert
@@ -0,0 +1,13 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+void main()
+{
+    int a  // semicolon missing at the end of the statement
+    gl_Position = vec4(a);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser3_frag.frag
new file mode 100644
index 0000000..7b543ad
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser3_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f[3];
+    f[3] = 1.0; // index of array greater than the size of the array
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser4_frag.frag
new file mode 100644
index 0000000..c73e4b3
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser4_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    const int i = 5;
+    i++;  // const cannot be modified
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser5_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser5_frag.frag
new file mode 100644
index 0000000..ee9cbda
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser5_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec2 v;
+    v.z = 1.2;   // vec2 does not have a z component
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser6_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser6_frag.frag
new file mode 100644
index 0000000..2d4d021
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser6_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f1,f2,f3;
+    f3 = f1 > f2;  // f1 > f2 result in a bool that cannot be assigned to a float
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser7_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser7_frag.frag
new file mode 100644
index 0000000..4903231
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser7_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    mat2 m1,m2;
+    bool b = m1 > m2;  // greater-than operator can not operate on matrices, however, equal (==) and not equal (!=) operators can be used with matrices
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser8_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser8_frag.frag
new file mode 100644
index 0000000..76649c5
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser8_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec2 v2;
+    vec3 v3;
+    bool b = v2 == v3; // equal operator cannot operator on vectors of different sizes
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser9_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser9_frag.frag
new file mode 100644
index 0000000..1283c22
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/parser9_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f1,f2;
+    bool b = f1 && f2;  // &&, || and ^^ operate on a boolean expression only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess0_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess0_frag.frag
new file mode 100644
index 0000000..e9d1d9f
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess0_frag.frag
@@ -0,0 +1,63 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+//test for else elif mismatch
+#define test(x,y) (x+y)
+
+void  main(void){
+ int sum =0;
+ #define x 8
+ #endif
+ #if (x==8)
+   #undef x
+ #endif
+
+ #if 1
+   #undef x
+ #endif
+
+ #if 1
+   #define t4 4
+ #endif
+
+ sum=test(3,6)+t4;
+ #if 1
+  #if 1
+   #if 1
+    #if 1
+     #if 0
+       #undef test
+     #else
+       #if 1
+         #undef test
+       #endif
+       #if 0
+        #undef test
+       #else
+          #if 0
+             #undef test
+          #else
+             #if 1
+                #undef test
+             #else
+               #undef test
+             #else
+               #jdhgj
+             #endif
+          #endif
+       #endif
+     #endif
+    #endif
+   #endif
+  #endif
+ #endif
+
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess10_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess10_frag.frag
new file mode 100644
index 0000000..feb2279
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess10_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+/* The program should terminate with an error message and not get into an
+   infinite loop */
+#ifdef name
+
+void main()
+{
+   gl_FragColor = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess1_frag.frag
new file mode 100644
index 0000000..72f4d14
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess1_frag.frag
@@ -0,0 +1,64 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+// tests for macro redifinition (t2) and the #if and #else nestings.
+// takes care of elif also.
+
+#define t1 (1+2)
+#define t2 2
+#define t2 3
+
+// testing the if depth
+#if (t1==3)
+  #define t3 3
+  #if defined t2
+    #define t4 4
+      #if defined(t3)
+          #define t5 5
+             #ifdef t5
+               #define t6 6
+                 #ifndef t7
+                   #define t7 7
+                 #else
+                   #define t8 8
+                 #endif
+             #endif
+      #else
+         #ifndef t8
+             #define t8 8
+         #elif (t8==8)
+            #define t9 9
+         #else
+            #if defined t7
+              #define t9 9
+            #endif
+         #endif
+      #endif
+  #else
+    #define t10 10
+  #endif
+#endif
+
+
+#define t8 8
+#define t9 9
+#define t10 10
+
+void main(void)
+{
+ int sum=1 ;
+ sum = t1+t2;
+ sum = t3+t4;
+ sum = t5+t6;
+ sum = t7+t8;
+ sum = t9+t10;
+}
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess2_frag.frag
new file mode 100644
index 0000000..9aa00e8
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess2_frag.frag
@@ -0,0 +1,60 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+// #line directive-- test cases.
+// chks for Invalid directives, all possible #line errors
+// Also checks the correct verions of #line dorective.
+
+#define t1 1
+#define t2 2
+
+#
+#
+#
+#
+#line 8
+#line ""
+#line 3 3
+
+#linekfj
+#line c c
+#line t1 t2
+#line 77 89
+#line 65.4
+#line message to the user
+#line
+#line345
+
+void main(void)
+{
+ int sum =1;
+ sum = __LINE__;
+ sum = __FILE__;
+ #line 4 5
+ sum = __LINE__;
+ sum = __FILE__;
+ #line 9
+ sum = __LINE__ + __FILE__ ;
+ sum = __FILE__;
+ #
+ #
+ sum = __VERSION__;
+ sum = sum + __LINE__ ;
+ #line 4 5
+ #line 5 8
+ sum = __LINE__;
+ sum = __FILE__;
+ sum = __VERSION__;
+
+}
+
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess3_frag.frag
new file mode 100644
index 0000000..c9e2006
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess3_frag.frag
@@ -0,0 +1,43 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+// simple macro expansions.
+// Tests for Too few macro arguments, too many macro arguments.
+// Macros with no arguments.
+
+#define t1 -1
+#define t2 2
+
+#define test -258
+#define test1 (test*test)
+#define test2(x) (x+test1)
+#define test3() (test2(8)*(test*test1))
+#define test4(x,y) (x+y)
+
+void main(void)
+{
+ int sum =0;
+ sum = test3();
+ sum = test3(3);
+
+ sum = test2(9);
+ sum = test2(9,8);
+
+ sum = test4;
+ sum = test2(8,5,78,9);
+ sum = sum + test1;
+ sum = 8+58+sum;
+ sum = sum +test;
+ sum = (t1+t2);
+ sum = test4(test3(),test2(test3()));
+ sum = test4(3,8,5);
+ sum = test4();
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess4_frag.frag
new file mode 100644
index 0000000..5d9c756
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess4_frag.frag
@@ -0,0 +1,60 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+// #error and #pragma directives -- test cases.
+// tests for errors in #pragma directive.
+
+#pragma optimize(on)
+#pragma debug(off)
+
+int foo(int);
+
+void main(void)
+{
+ int sum =0;
+ #error ;
+ #error 78
+ #error c
+ #error "message to the user "
+ #error message to the user
+ #error
+ #error
+ #define t1 1
+ sum = t1*t1;
+ foo(sum);
+
+}
+
+#pragma optimize(off)
+#pragma bind(on)
+#pragma pack(off)
+
+int foo(int test)
+{
+ int binding=0;
+ binding = test;
+ return binding;
+}
+
+#line 4
+#pragma
+#line 5 6
+#pragma optmimize on
+#pragma debug off
+#pragma debug(off
+#line 9
+#prgma bind(off)
+#pragma bind
+#pragma (on)
+#pragma on (on)
+#pragma optmize(on
+
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess6_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess6_frag.frag
new file mode 100644
index 0000000..836bd02
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess6_frag.frag
@@ -0,0 +1,37 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+// operator precedence and some macro expansions.
+
+#define test (1+2)
+#define test1 (test*4)
+#define test2 (test1/test)
+//#define test3 (-1+2*3/4%test)
+#define test3 (-1+2*3/4)
+//#define test4 (test & test1 |test2)
+#define test4 (test)
+#define test5 (!8+~4+4-6)
+#define test6 (test1>>1)
+#define test7 (test1<<1)
+#define test8 (test2^6)
+#define test9 (test4 || test5 && test1)
+#define test10 (0)
+
+void main(void)
+{
+ int sum =0;
+ sum = test4;
+ sum = test3*test2+test1-test;
+// sum = test3/test6 + test4*test7 - test7 % test9;
+// sum = test3/test6 + test4*test7 - test7;
+ sum = test10*test5;
+}
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess7_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess7_frag.frag
new file mode 100644
index 0000000..08f62b1
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/preprocess7_frag.frag
@@ -0,0 +1,51 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+// testing for char constants in #if and #elif
+// Also checking whether reserved words can be redefined.
+
+#define t1 c
+#define t2 d
+#define asm a
+
+ #if(t1==c)
+  #define t3 3
+ #elif(t1==d)
+  #define t4 4
+ #elif(t2==c)
+  #define t5 5
+ #endif
+
+ #ifndef t1
+   #define t7 7
+ #elif (t2==d)
+  #define t6 6
+ #endif
+
+ #if (t2=='d')
+  #define half 5
+ #else
+  #define half 8
+ #endif
+
+ #ifdef t22
+  #define x 5
+ #endif
+
+ void main(void)
+  {
+   int sum =0,a=9;
+
+   sum = half + sum;
+   sum = asm + a;
+
+  }
+
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping1_frag.frag
new file mode 100644
index 0000000..89c9a51
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping1_frag.frag
@@ -0,0 +1,21 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    bool b;
+    if (b)
+    {
+        int i = 1;
+        i++;
+    }
+    i++;  // i is not declared in this scope
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping2_frag.frag
new file mode 100644
index 0000000..8667f40
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/scoping2_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    {
+        int i = 1;
+        i++;
+    }
+    i++;  // i is not declared in this scope
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct10_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct10_frag.frag
new file mode 100644
index 0000000..fb0c782
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct10_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    int i;
+} s1[2];
+
+void main()
+{
+   s1.i = 1;  // s1 is an array. s1[0].i is correct to use
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct11_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct11_frag.frag
new file mode 100644
index 0000000..152ce49
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct11_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    int i;
+} s1;
+
+void main()
+{
+   s1 = -s1; // cannot calculate negative of a structure
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct1_frag.frag
new file mode 100644
index 0000000..0fcbb85
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct1_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    int i;
+} uniform uniformStruct;  // uniform keyword should be used before the keyword struct
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct2_frag.frag
new file mode 100644
index 0000000..5682f67
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct2_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    int i = 1.0;  // struct members cannot be initialized at the time of structure declaration
+} s1;
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct3_frag.frag
new file mode 100644
index 0000000..2ec1e53
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct3_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    uniform int i;  // structure members cannot be declared with const qualifier
+} s1;
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct4_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct4_frag.frag
new file mode 100644
index 0000000..ae7d547
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct4_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    const int i = 1;  // structure members cannot be declared with const qualifier
+} s1;
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct5_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct5_frag.frag
new file mode 100644
index 0000000..fd62320
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct5_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+uniform struct s {
+    int i;
+} s1;
+
+void main()
+{
+   s1.i = 1;  // uniforms are read only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct6_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct6_frag.frag
new file mode 100644
index 0000000..dd98cc0
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct6_frag.frag
@@ -0,0 +1,18 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+varying struct s {
+    int i;
+} s1;  // structures cannot be declared with varying qualifier
+
+void main()
+{
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct7_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct7_frag.frag
new file mode 100644
index 0000000..01a3206
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct7_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    struct s {
+    } s1;  // structures have to be declared with atleast one member
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct8_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct8_frag.frag
new file mode 100644
index 0000000..c900bc9
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct8_frag.frag
@@ -0,0 +1,23 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct s {
+    int i;
+} s1;
+
+struct ss {
+    int i;
+} s2;
+
+void main()
+{
+    s1 = s2;  // two different structures cannot be assigned to each other
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct9_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct9_frag.frag
new file mode 100644
index 0000000..c661d25
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/struct9_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+const struct s {
+    int i;
+} s1 = s(1);
+
+void main()
+{
+   s1.i = 1;  // const struct members cannot be modified
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle1_frag.frag
new file mode 100644
index 0000000..b11ea3c
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle1_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec2 v;
+    v.xy = 1.2; // swizzle needs two values, v.xy = vec2(1.2) is correct
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle2_frag.frag
new file mode 100644
index 0000000..705bd18
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle2_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec2 v;
+    v.xx = vec2(1,1);  // x cannot be used twice in l-value
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle3_frag.frag
new file mode 100644
index 0000000..b5b9fd6
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/swizzle3_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec2 v;
+    vec3 v3 = v.xyz; // v is a vec2 and does not have a z component
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/typecast_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/typecast_frag.frag
new file mode 100644
index 0000000..fa1b124
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/typecast_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    vec4 v;
+    vec4 v1 = (vec4) v; // incorrect typecasting, vec4(v) is correct
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform1_frag.frag
new file mode 100644
index 0000000..1270647
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform1_frag.frag
@@ -0,0 +1,23 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct gtf_FogParameters {
+vec4 color;
+float density;
+float start;
+float end;
+float scale;
+};
+uniform gtf_FogParameters gtf_Fog;
+void main()
+{
+    gtf_Fog.density = 1.0;  // cannot modify a uniform
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform_frag.frag
new file mode 100644
index 0000000..195eace
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/uniform_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    uniform float foo;  // uniforms can only be declared at a global scope
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying1_frag.frag
new file mode 100644
index 0000000..9f5122e
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying1_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+varying float foo;
+
+void main()
+{
+    foo = 5.0; // varying cannot be written by a fragment shader
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying2_frag.frag
new file mode 100644
index 0000000..74cc9f4
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying2_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+varying int foo; // varyings cannot be int or bool
+
+void main()
+{
+
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying3_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying3_frag.frag
new file mode 100644
index 0000000..62ab65e
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying3_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+varying vec4 v = vec4(1,1,1,1);//gl_TexCoord[0]; // varyings cannot be initialized
+
+void main()
+{
+
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying_frag.frag
new file mode 100644
index 0000000..f85d9fd
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/varying_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    varying float foo; // varyings can only be declared at a global scope
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vector_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vector_frag.frag
new file mode 100644
index 0000000..62c298e
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vector_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    ivec4 v4;
+    v4 = v4 + 2.0;
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/version2_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/version2_V100_frag.frag
new file mode 100644
index 0000000..b83fc6a46
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/version2_V100_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#pragma debug(on)
+#version 100  // error #version should be the first statement in the program
+#ifdef GL_ES
+precision mediump float;
+#endif
+
+
+void main()
+{
+   gl_FragColor = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/version3_V100_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/version3_V100_frag.frag
new file mode 100644
index 0000000..21dfcc3
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/version3_V100_frag.frag
@@ -0,0 +1,19 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+/* This is  a comment*/ int i; // This is a global decl
+#version 100  // error #version should be the first statement in the program
+#ifdef GL_ES
+precision mediump float;
+#endif
+
+
+void main()
+{
+   gl_FragColor = vec4(1);
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly2_frag.frag
new file mode 100644
index 0000000..1c85e22
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly2_frag.frag
@@ -0,0 +1,15 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    gl_Position = vec4(4.0);  // can be used in vertex shader only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly_frag.frag
new file mode 100644
index 0000000..41ada2b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertexOnly_frag.frag
@@ -0,0 +1,25 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+struct gtf_PointParameters {
+float size;
+float sizeMin;
+float sizeMax;
+float fadeThresholdSize;
+float distanceConstantAttenuation;
+float distanceLinearAttenuation;
+float distanceQuadraticAttenuation;
+};
+uniform gtf_FogParameters gtf_Point;
+void main()
+{
+    gtf_PointSize = 4.0;  // can be used in vertex shader only
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertex_vert.vert b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertex_vert.vert
new file mode 100644
index 0000000..ab8cc45
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/vertex_vert.vert
@@ -0,0 +1,13 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+attribute vec4 gtf_Vertex;
+void main()
+{
+    gtf_Vertex = vec4(1.0,2.0,3.0, 4.0); // cannot modify an attribute
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while1_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while1_frag.frag
new file mode 100644
index 0000000..89e2c6b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while1_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    int i;
+    while(i) {  // condition should be boolean
+    }
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while2_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while2_frag.frag
new file mode 100644
index 0000000..31e75cf
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while2_frag.frag
@@ -0,0 +1,16 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    while(float f = 5.0) {  // cannot declare variables in condition
+    }
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while_frag.frag b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while_frag.frag
new file mode 100644
index 0000000..891d099
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/ogles/GL/build/while_frag.frag
@@ -0,0 +1,17 @@
+
+/*
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+*/
+
+
+#ifdef GL_ES
+precision mediump float;
+#endif
+void main()
+{
+    float f;
+    while(f) {  // condition should be boolean
+    }
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/programs/program-test.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/programs/program-test.html
index b5d5b59..34ca68f 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/programs/program-test.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/programs/program-test.html
@@ -312,9 +312,9 @@
     assertMsg(gl.getProgramParameter(progGood2, gl.LINK_STATUS) == false,
               "linking should fail with in-use formerly good program, with new bad shader attached");
 
-    // Invalid link leaves previous valid program intact.
+    // In WebGL, an unsuccessful link immediately invalidates the previous valid program.
     gl.drawArrays(gl.TRIANGLES, 0, 3);
-    wtu.glErrorShouldBe(gl, gl.NO_ERROR, "drawing with a valid program shouldn't generate a GL error");
+    wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION, "drawing with a newly-invalidated program should generate INVALID_OPERATION");
 
     gl.useProgram(progGood1);
     gl.drawArrays(gl.TRIANGLES, 0, 4);
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html
new file mode 100644
index 0000000..d33555f
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/rendering/clear-default-framebuffer-with-scissor-test.html
@@ -0,0 +1,68 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>Clear with scissor bug on WebGL canvas</title>
+<link rel="stylesheet" href="../../resources/js-test-style.css"/>
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<canvas id="canvas-webgl" width="20" height="20"> </canvas>
+<canvas id="canvas-2d" width="20" height="20"> </canvas>
+
+<script>
+"use strict";
+// This test exposes an issue in older Intel D3D drivers.
+var wtu = WebGLTestUtils;
+
+function test_clear_with_scissor_on_canvas()
+{
+  var canvasWebGL = document.getElementById("canvas-webgl");
+  var gl = canvasWebGL.getContext("webgl", { antialias:false });
+  const scissorRectSize = 16;
+  gl.enable(gl.SCISSOR_TEST);
+  gl.scissor(0, 0, scissorRectSize, scissorRectSize);
+  gl.clearColor(0, 1, 0, 1);
+  gl.clear(gl.COLOR_BUFFER_BIT);
+
+  // The issue is found in the Chromium compositor so we need another canvas element for reproduction.
+  var canvas2D = document.getElementById("canvas-2d");
+  var context2D = canvas2D.getContext('2d');
+  context2D.drawImage(canvasWebGL, 0, 0);
+  context2D.fill();
+
+  var imageData =
+    context2D.getImageData(0, canvas2D.clientHeight - scissorRectSize, scissorRectSize, scissorRectSize);
+  var data = imageData.data;
+  var expectedColor = [0, 255, 0, 255];
+  for (var pixelIndex = 0; pixelIndex < scissorRectSize * scissorRectSize; ++pixelIndex) {
+    for (var colorIndex = 0; colorIndex < 4; ++colorIndex) {
+      if (data[pixelIndex * 4 + colorIndex] !== expectedColor[colorIndex]) {
+        var y = Math.floor(pixelIndex / scissorRectSize);
+        var x = pixelIndex % scissorRectSize;
+        testFailed("The canvas color at (" + x + ", " + y + ") is not expected");
+        return;
+      }
+    }
+  }
+}
+
+test_clear_with_scissor_on_canvas();
+
+description("Exposes clearing WebGL canvas with scissor bug on Intel D3D drivers - see https://crbug.com/1206763");
+var successfullyParsed = true;
+
+</script>
+<script src="../../js/js-test-post.js"></script>
+
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html
new file mode 100644
index 0000000..7bba52e
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/rendering/color-mask-should-not-affect-antialiased-framebuffer-resolution.html
@@ -0,0 +1,71 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL ColorMask Should Not Affect Antialiased Framebuffer Resolution</title>
+<link rel="stylesheet" href="../../resources/js-test-style.css"/>
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"></script>
+</head>
+<body>
+<canvas id="canvas" width="8" height="8"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+
+<script>
+"use strict";
+
+const wtu = WebGLTestUtils;
+description("This test verifies that the colorMask state does not affect resolution of the antialiased framebuffer.");
+
+debug('Regression test for <a href="https://crbug.com/1257769">https://crbug.com/1257769</a> and <a href="https://bugs.webkit.org/show_bug.cgi?id=220129">https://bugs.webkit.org/show_bug.cgi?id=220129</a>');
+
+function run() {
+    const gl = wtu.create3DContext("canvas", { antialias: true, alpha: true });
+
+    if (!gl) {
+        testFailed("WebGL context does not exist");
+        finishTest();
+        return;
+    }
+
+    testPassed("WebGL context exists");
+
+    const program = wtu.setupColorQuad(gl);
+
+    // Clear the default (multisampled) framebuffer to red.
+    gl.clearColor(1, 0, 0, 1);
+    gl.colorMask(true, true, true, true);
+    gl.clear(gl.COLOR_BUFFER_BIT);
+
+    // Draw a transparent green quad.
+    gl.useProgram(program);
+    wtu.drawFloatColorQuad(gl, [ 0, 255, 0, 0 ]);
+
+    // Clear the alpha channel.
+    gl.colorMask(false, false, false, true);
+    gl.clearColor(0, 0, 0, 1);
+    gl.clear(gl.COLOR_BUFFER_BIT);
+
+    // At this point, even setting the colorMask to all-true won't
+    // work around the bug, since that state is latched inside ANGLE
+    // only during draws / clears.
+
+    wtu.checkCanvas(gl, [ 0, 255, 0, 255 ], "should be green", 1);
+    finishTest();
+}
+
+var successfullyParsed = true;
+
+requestAnimationFrame(run);
+
+</script>
+
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/state/gl-object-get-calls.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/state/gl-object-get-calls.html
index 530a4b4..7aa2ced 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/state/gl-object-get-calls.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/state/gl-object-get-calls.html
@@ -20,7 +20,5 @@
 var contextVersion = 1;
 </script>
 <script src="../../js/tests/gl-object-get-calls.js"></script>
-
-<script src="../../js/js-test-post.js"></script>
 </body>
 </html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html
new file mode 100644
index 0000000..df7694b
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/format-filterable-renderable.html
@@ -0,0 +1,378 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<script src="../../../js/js-test-pre.js"></script>
+<script src="../../../js/webgl-test-utils.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<script>
+"use strict";
+
+const wtu = WebGLTestUtils;
+description();
+
+const gl = wtu.create3DContext();
+gl.canvas.width = gl.canvas.height = 1;
+
+function makeTexImage(format, unpackFormat, unpackType, data) {
+    data = data || null;
+
+    const tex = gl.createTexture();
+    gl.bindTexture(gl.TEXTURE_2D, tex);
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
+    gl.texImage2D(gl.TEXTURE_2D, 0, gl[format], 2, 2, 0,
+                gl[unpackFormat], gl[unpackType], null);
+    return tex;
+}
+
+const DUMMY_COLOR = makeTexImage('RGBA', 'RGBA', 'UNSIGNED_BYTE');
+
+function makeProgram(gl, vsSrc, fsSrc) {
+  function makeShader(prog, type, src) {
+    const shader = gl.createShader(gl[type]);
+    gl.shaderSource(shader, src.trim());
+    gl.compileShader(shader);
+    gl.attachShader(prog, shader);
+    gl.deleteShader(shader);
+  };
+
+  const prog = gl.createProgram();
+  makeShader(prog, 'VERTEX_SHADER', vsSrc);
+  makeShader(prog, 'FRAGMENT_SHADER', fsSrc);
+  gl.linkProgram(prog);
+
+  if (!gl.getProgramParameter(prog, gl.LINK_STATUS)) {
+    throw 'Program linking failed' + fsSrc;
+  }
+  return prog;
+}
+
+const TEX_FILTER_PROG_T = (version, samplerT) => makeProgram(gl, `\
+    ${version}
+    void main() {
+        gl_PointSize = 1.0;
+        gl_Position = vec4(0.5,0.5,0,1);
+    }`,`\
+    ${version}
+    precision mediump float;
+    uniform ${samplerT} u_tex0;
+    #if __VERSION__ == 300
+    out vec4 o_FragColor;
+    #else
+    #define o_FragColor gl_FragColor
+    #define texture texture2D
+    #endif
+    void main() {
+        o_FragColor = vec4(texture(u_tex0, vec2(0.8)));
+    }`);
+const TEX_FILTER_PROG_BY_TYPEISH = {
+    'float': TEX_FILTER_PROG_T('', 'sampler2D'),
+};
+if (wtu.isWebGL2(gl)) {
+    TEX_FILTER_PROG_BY_TYPEISH['int'] =
+        TEX_FILTER_PROG_T('#version 300 es', 'highp isampler2D');
+    TEX_FILTER_PROG_BY_TYPEISH['uint'] =
+        TEX_FILTER_PROG_T('#version 300 es', 'highp usampler2D');
+}
+
+function runPixelProgram(gl, prog) {
+    gl.useProgram(prog);
+    gl.clear(gl.COLOR_BUFFER_BIT);
+    gl.drawArrays(gl.POINTS, 0, 1);
+    const bytes = new Uint8Array(4);
+    gl.readPixels(0,0,1,1,gl.RGBA, gl.UNSIGNED_BYTE, bytes);
+    return [].map.call(bytes, x => x/255.0);
+}
+
+// GLES 2.0.25 p63
+const FORMAT_INFO_WEBGL1 = {
+    RGBA8  : { filter: true, render: true     , unpack: ['RGBA', 'UNSIGNED_BYTE'] },
+    RGB8   : { filter: true, render: undefined, unpack: ['RGB', 'UNSIGNED_BYTE'] },
+    RGBA4  : { filter: true, render: undefined, unpack: ['RGBA', 'UNSIGNED_SHORT_4_4_4_4'] },
+    RGB5_A1: { filter: true, render: undefined, unpack: ['RGBA', 'UNSIGNED_SHORT_5_5_5_1'] },
+    RGB565 : { filter: true, render: undefined, unpack: ['RGB', 'UNSIGNED_SHORT_5_6_5'] },
+    LA8    : { filter: true, render: false    , unpack: ['LUMINANCE_ALPHA', 'UNSIGNED_BYTE'] },
+    L8     : { filter: true, render: false    , unpack: ['LUMINANCE', 'UNSIGNED_BYTE'] },
+    A8     : { filter: true, render: false    , unpack: ['ALPHA', 'UNSIGNED_BYTE'] },
+};
+
+// GLES 3.0.6 p130-132
+const FORMAT_INFO_WEBGL2 = {
+    R8            : { render: true , filter: true , unpack: ['RED', 'UNSIGNED_BYTE'] },
+    R8_SNORM      : { render: false, filter: true , unpack: ['RED', 'BYTE'] },
+    RG8           : { render: true , filter: true , unpack: ['RG', 'UNSIGNED_BYTE'] },
+    RG8_SNORM     : { render: false, filter: true , unpack: ['RG', 'BYTE'] },
+    RGB8          : { render: true , filter: true , unpack: ['RGB', 'UNSIGNED_BYTE'] },
+    RGB8_SNORM    : { render: false, filter: true , unpack: ['RGB', 'BYTE'] },
+    RGB565        : { render: true , filter: true , unpack: ['RGB', 'UNSIGNED_SHORT_5_6_5'] },
+    RGBA4         : { render: true , filter: true , unpack: ['RGBA', 'UNSIGNED_SHORT_4_4_4_4'] },
+    RGB5_A1       : { render: true , filter: true , unpack: ['RGBA', 'UNSIGNED_SHORT_5_5_5_1'] },
+    RGBA8         : { render: true , filter: true , unpack: ['RGBA', 'UNSIGNED_BYTE'] },
+    RGBA8_SNORM   : { render: false, filter: true , unpack: ['RGBA', 'BYTE'] },
+    RGB10_A2      : { render: true , filter: true , unpack: ['RGBA', 'UNSIGNED_INT_10_10_10_2'] },
+    RGB10_A2UI    : { render: true , filter: false, unpack: ['RGBA', 'UNSIGNED_INT_10_10_10_2'] },
+    SRGB8         : { render: false, filter: true , unpack: ['RGB', 'UNSIGNED_BYTE'] },
+    SRGB8_ALPHA8  : { render: true , filter: true , unpack: ['RGBA', 'UNSIGNED_BYTE'] },
+    R16F          : { render: false, filter: true , unpack: ['RED', 'FLOAT'] },
+    RG16F         : { render: false, filter: true , unpack: ['RG', 'FLOAT'] },
+    RGB16F        : { render: false, filter: true , unpack: ['RGB', 'FLOAT'] },
+    RGBA16F       : { render: false, filter: true , unpack: ['RGBA', 'FLOAT'] },
+    R32F          : { render: false, filter: false, unpack: ['RED', 'FLOAT'] },
+    RG32F         : { render: false, filter: false, unpack: ['RG', 'FLOAT'] },
+    RGB32F        : { render: false, filter: false, unpack: ['RGB', 'FLOAT'] },
+    RGBA32F       : { render: false, filter: false, unpack: ['RGBA', 'FLOAT'] },
+    R11F_G11F_B10F: { render: false, filter: true , unpack: ['RGB', 'FLOAT'] },
+    RGB9_E5       : { render: false, filter: true , unpack: ['RGB', 'FLOAT'] },
+    R8I           : { render: true , filter: false, unpack: ['RED', 'BYTE'] },
+    R8UI          : { render: true , filter: false, unpack: ['RED', 'UNSIGNED_BYTE'] },
+    R16I          : { render: true , filter: false, unpack: ['RED', 'BYTE'] },
+    R16UI         : { render: true , filter: false, unpack: ['RED', 'UNSIGNED_BYTE'] },
+    R32I          : { render: true , filter: false, unpack: ['RED', 'BYTE'] },
+    R32UI         : { render: true , filter: false, unpack: ['RED', 'UNSIGNED_BYTE'] },
+    RG8I          : { render: true , filter: false, unpack: ['RG', 'BYTE'] },
+    RG8UI         : { render: true , filter: false, unpack: ['RG', 'UNSIGNED_BYTE'] },
+    RG16I         : { render: true , filter: false, unpack: ['RG', 'SHORT'] },
+    RG16UI        : { render: true , filter: false, unpack: ['RG', 'UNSIGNED_SHORT'] },
+    RG32I         : { render: true , filter: false, unpack: ['RG', 'INT'] },
+    RG32UI        : { render: true , filter: false, unpack: ['RG', 'UNSIGNED_INT'] },
+    RGB8I         : { render: false, filter: false, unpack: ['RGB', 'BYTE'] },
+    RGB8UI        : { render: false, filter: false, unpack: ['RGB', 'UNSIGNED_BYTE'] },
+    RGB16I        : { render: false, filter: false, unpack: ['RGB', 'SHORT'] },
+    RGB16UI       : { render: false, filter: false, unpack: ['RGB', 'UNSIGNED_SHORT'] },
+    RGB32I        : { render: false, filter: false, unpack: ['RGB', 'INT'] },
+    RGB32UI       : { render: false, filter: false, unpack: ['RGB', 'UNSIGNED_INT'] },
+    RGBA8I        : { render: true , filter: false, unpack: ['RGBA', 'BYTE'] },
+    RGBA8UI       : { render: true , filter: false, unpack: ['RGBA', 'UNSIGNED_BYTE'] },
+    RGBA16I       : { render: true , filter: false, unpack: ['RGBA', 'SHORT'] },
+    RGBA16UI      : { render: true , filter: false, unpack: ['RGBA', 'UNSIGNED_SHORT'] },
+    RGBA32I       : { render: true , filter: false, unpack: ['RGBA', 'INT'] },
+    RGBA32UI      : { render: true , filter: false, unpack: ['RGBA', 'UNSIGNED_INT'] },
+
+    DEPTH_COMPONENT16:  { render: 'DEPTH_ATTACHMENT', filter: false },
+    DEPTH_COMPONENT24:  { render: 'DEPTH_ATTACHMENT', filter: false },
+    DEPTH_COMPONENT32F: { render: 'DEPTH_ATTACHMENT', filter: false },
+    DEPTH24_STENCIL8:   { render: 'DEPTH_STENCIL_ATTACHMENT', filter: false },
+    DEPTH32F_STENCIL8:  { render: 'DEPTH_STENCIL_ATTACHMENT', filter: false },
+};
+
+const ONE_BY_TYPE = {
+    'BYTE': (1<<7)-1,
+    'UNSIGNED_BYTE': (1<<8)-1,
+    'SHORT': (1<<15)-1,
+    'UNSIGNED_SHORT': (1<<16)-1,
+    'INT': (1<<31)-1,
+    'UNSIGNED_INT': Math.pow(2,32)-1,
+    'FLOAT': 1,
+};
+
+const ABV_BY_TYPE = {
+    'BYTE': Int8Array,
+    'UNSIGNED_BYTE': Uint8Array,
+    'SHORT': Int16Array,
+    'UNSIGNED_SHORT': Uint16Array,
+    'INT': Int32Array,
+    'UNSIGNED_INT': Uint32Array,
+    'FLOAT': Float32Array,
+};
+
+function pushBitsUnorm(prev, bitCount, floatVal) {
+    let ret = prev << bitCount;
+    ret |= floatVal * ((1 << bitCount)-1);
+    return ret;
+}
+
+const CHANNELS_BY_FORMAT = {
+    'RED': 1,
+    'LUMINANCE': 1,
+    'ALPHA': 1,
+    'LUMINANCE_ALPHA': 2,
+    'RG': 2,
+    'RGB': 3,
+    'RGBA': 4,
+};
+
+function throwv(val) {
+    throw val;
+}
+
+function pixelDataForUnpack(format, type, floatVal) {
+    switch (type) {
+        case 'UNSIGNED_SHORT_5_6_5': {
+            let bits = 0;
+            bits = pushBitsUnorm(bits, 5, floatVal);
+            bits = pushBitsUnorm(bits, 6, floatVal);
+            bits = pushBitsUnorm(bits, 5, floatVal);
+            return new Uint16Array([bits]);
+        }
+        case 'UNSIGNED_SHORT_4_4_4_4': {
+            let bits = 0;
+            bits = pushBitsUnorm(bits, 4, floatVal);
+            bits = pushBitsUnorm(bits, 4, floatVal);
+            bits = pushBitsUnorm(bits, 4, floatVal);
+            bits = pushBitsUnorm(bits, 4, floatVal);
+            return new Uint16Array([bits]);
+        }
+        case 'UNSIGNED_SHORT_5_5_5_1': {
+            let bits = 0;
+            bits = pushBitsUnorm(bits, 5, floatVal);
+            bits = pushBitsUnorm(bits, 5, floatVal);
+            bits = pushBitsUnorm(bits, 5, floatVal);
+            bits = pushBitsUnorm(bits, 1, floatVal); // Ok, silly for 1 bit here.
+            return new Uint16Array([bits]);
+        }
+        case 'UNSIGNED_INT_10_10_10_2': {
+            let bits = 0;
+            bits = pushBitsUnorm(bits, 10, floatVal);
+            bits = pushBitsUnorm(bits, 10, floatVal);
+            bits = pushBitsUnorm(bits, 10, floatVal);
+            bits = pushBitsUnorm(bits, 2, floatVal); // 2 bits isn't much more useful
+            return new Uint32Array([bits]);
+        }
+    }
+
+    const channels = CHANNELS_BY_FORMAT[format] || throwv(format);
+    const one = ONE_BY_TYPE[type] || throwv('240', type);
+    const abvType = ABV_BY_TYPE[type] || throwv('241', type);
+
+    const val = floatVal * one;
+    const arr = [];
+    for (const i of range(channels)) {
+        arr.push(val);
+    }
+    return new abvType(arr);
+}
+
+function expect(name, was, expected) {
+    let text = `${name} was ${was}`;
+    const cond = was == expected;
+    if (!cond) {
+        text += `, but expected ${expected}`;
+    }
+    expectTrue(cond, text);
+}
+
+function toTypeish(sizedFormat) {
+    if (sizedFormat.endsWith('UI')) {
+        return 'int';
+    } else if (sizedFormat.endsWith('I')) {
+        return 'uint';
+    }
+    return 'float';
+}
+
+call(async () => {
+    gl.pixelStorei(gl.UNPACK_ALIGNMENT, 1);
+
+    let formatList = FORMAT_INFO_WEBGL1;
+    if (wtu.isWebGL2(gl)) {
+        formatList = FORMAT_INFO_WEBGL2;
+    }
+    for (const [sizedFormat, info] of Object.entries(formatList)) {
+        await wtu.dispatchPromise();
+        debug(``);
+        debug(`${sizedFormat}: ${JSON.stringify(info)}`);
+
+        const typeish = toTypeish(sizedFormat);
+
+        //  |---|---|
+        //  | 0 | 1 |
+        //  |---|---|
+        // 0| 0 | 0 |
+        //  |---|---|
+        //    0
+        const tex = gl.createTexture();
+        gl.bindTexture(gl.TEXTURE_2D, tex);
+        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
+        gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
+
+        if (gl.texStorage2D) {
+            gl.texStorage2D(gl.TEXTURE_2D, 1, gl[sizedFormat], 2, 2);
+        } else {
+            gl.texImage2D(gl.TEXTURE_2D, 0, gl[info.unpack[0]],
+                2, 2, 0, gl[info.unpack[0]], gl[info.unpack[1]], null);
+        }
+
+        if (info.unpack) {
+            const one = pixelDataForUnpack(...info.unpack, 1.0);
+            const data = new one.constructor(one.length*4);
+            data.set(one, one.length*3);
+            gl.texSubImage2D(gl.TEXTURE_2D, 0, 0,0,
+                2,2, gl[info.unpack[0]], gl[info.unpack[1]], data);
+        } else {
+            info.render || throwv(`${sizedFormat} without unpack or render`);
+        }
+
+        // -
+        // color-renderable test
+
+        {
+            const fb = gl.createFramebuffer();
+            gl.bindFramebuffer(gl.FRAMEBUFFER, fb);
+            let attach = info.render || true;
+            const isColor = (attach === true);
+            if (isColor) {
+                attach = 'COLOR_ATTACHMENT0';
+            } else {
+                gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0,
+                                        gl.TEXTURE_2D, DUMMY_COLOR, 0);
+            }
+            gl.framebufferTexture2D(gl.FRAMEBUFFER, gl[attach],
+                                    gl.TEXTURE_2D, tex, 0);
+            const status = gl.checkFramebufferStatus(gl.FRAMEBUFFER);
+            const wasRenderable = (status == gl.FRAMEBUFFER_COMPLETE);
+            if (info.render === undefined) {
+                debug(`Non-normative: color-renderable was ${wasRenderable}`);
+            } else {
+                expect('color-renderable', wasRenderable, !!info.render);
+            }
+            if (wasRenderable) {
+                gl.clearColor(0,0,0,0);
+                gl.clearDepth(0);
+                gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
+                gl.enable(gl.SCISSOR_TEST);
+                gl.scissor(1,1,1,1);
+                gl.clearColor(1,1,1,1);
+                gl.clearDepth(1);
+                gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
+                gl.disable(gl.SCISSOR_TEST);
+            }
+            gl.deleteFramebuffer(fb);
+            if (!wasRenderable && !info.unpack) {
+                testFailed('No unpack provided and !wasRenderable, skipping filtering subtest...');
+                continue;
+            }
+        }
+
+        // -
+        // filterable test
+
+        const prog = TEX_FILTER_PROG_BY_TYPEISH[typeish];
+        gl.bindTexture(gl.TEXTURE_2D, tex);
+        gl.clearColor(0,0,0,0);
+        gl.bindFramebuffer(gl.FRAMEBUFFER, null);
+        gl.viewport(0,0,1,1);
+        const v = runPixelProgram(gl, prog);
+        if (sizedFormat != 'A8') {
+            v[3] = 0; // Incomplete no-alpha formats put 1 in alpha.
+        }
+        const wasFilterable = v.some(x => !!x);
+        expect('filterable', wasFilterable, info.filter);
+    }
+
+    finishTest();
+});
+
+</script>
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/png-image-types.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/png-image-types.html
new file mode 100644
index 0000000..4eb98b1
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/png-image-types.html
@@ -0,0 +1,164 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+
+<head>
+    <meta charset="utf-8">
+    <link rel="stylesheet" href="../../../resources/js-test-style.css" />
+    <script src="../../../js/js-test-pre.js"></script>
+    <script src="../../../js/webgl-test-utils.js"></script>
+</head>
+
+<body>
+    <div id="description"></div>
+    <div id="console"></div>
+    <script>
+"use strict";
+description("This test verifies correct channel mapping of different PNG image types.");
+
+const testData = {
+    "Grayscale": {
+        src: [
+            // [0x40]
+            "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAAAAAA6fptVAAAACklEQVQI12NwAAAAQgBBg7nsrQAAAABJRU5ErkJggg==",
+            // [0x4040]
+            "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABEAAAAABq7kcWAAAAC0lEQVQI12NwcAAAAMMAgUenLEIAAAAASUVORK5CYII="
+        ],
+        expectations: [
+            { color: [0x00, 0x00, 0x00, 0xFF], format: "ALPHA" },
+            { color: [0x40, 0x40, 0x40, 0xFF], format: "RGB" },
+            { color: [0x40, 0x40, 0x40, 0xFF], format: "RGBA" },
+            { color: [0x40, 0x40, 0x40, 0xFF], format: "LUMINANCE" },
+            { color: [0x40, 0x40, 0x40, 0xFF], format: "LUMINANCE_ALPHA" },
+            { color: [0x40, 0x00, 0x00, 0xFF], format: "RED", internalformat: "R8" },
+            { color: [0x40, 0x40, 0x00, 0xFF], format: "RG", internalformat: "RG8" }
+        ]
+    },
+    "Grayscale Alpha": {
+        src: [
+            // [0x40, 0x80]
+            "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVQI12NwaAAAAQMAwUxZTl4AAAAASUVORK5CYII=",
+            // [0x4040, 0x8080]
+            "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABEAQAAADljNBBAAAADUlEQVQI12NwcGhoAAADRQGBoxssPgAAAABJRU5ErkJggg=="
+        ],
+        expectations: [
+            { color: [0x00, 0x00, 0x00, 0x80], format: "ALPHA" },
+            { color: [0x40, 0x40, 0x40, 0xFF], format: "RGB" },
+            { color: [0x40, 0x40, 0x40, 0x80], format: "RGBA" },
+            { color: [0x40, 0x40, 0x40, 0xFF], format: "LUMINANCE" },
+            { color: [0x40, 0x40, 0x40, 0x80], format: "LUMINANCE_ALPHA" },
+            { color: [0x40, 0x00, 0x00, 0xFF], format: "RED", internalformat: "R8" },
+            { color: [0x40, 0x40, 0x00, 0xFF], format: "RG", internalformat: "RG8" }
+        ]
+    },
+    "Color": {
+        src: [
+            // [0xBF, 0x7F, 0xFF]
+            "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAADElEQVQI12PYX/8fAAQ+Aj5BqwprAAAAAElFTkSuQmCC",
+            // [0xBFBF, 0x7F7F, 0xFFFF]
+            "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABEAIAAADA54+dAAAAD0lEQVQI12PYv7++/v9/AA6yBHvtbgBNAAAAAElFTkSuQmCC"
+        ],
+        expectations: [
+            { color: [0x00, 0x00, 0x00, 0xFF], format: "ALPHA" },
+            { color: [0xBF, 0x7F, 0xFF, 0xFF], format: "RGB" },
+            { color: [0xBF, 0x7F, 0xFF, 0xFF], format: "RGBA" },
+            { color: [0xBF, 0xBF, 0xBF, 0xFF], format: "LUMINANCE" },
+            { color: [0xBF, 0xBF, 0xBF, 0xFF], format: "LUMINANCE_ALPHA" },
+            { color: [0xBF, 0x00, 0x00, 0xFF], format: "RED", internalformat: "R8" },
+            { color: [0xBF, 0x7F, 0x00, 0xFF], format: "RG", internalformat: "RG8" }
+        ]
+
+    },
+    "Color Alpha": {
+        src: [
+            // [0xBF, 0x7F, 0xFF, 0x40]
+            "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVQI12PYX//fAQAGvAJ+xPMwKQAAAABJRU5ErkJggg==",
+            // [0xBFBF, 0x7F7F, 0xFFFF, 0x4040]
+            "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABEAYAAABPhRjKAAAAEUlEQVQI12PYv7++/v9/BwcAGGgE+8YN4XUAAAAASUVORK5CYII="
+        ],
+        expectations: [
+            { color: [0x00, 0x00, 0x00, 0x40], format: "ALPHA" },
+            { color: [0xBF, 0x7F, 0xFF, 0xFF], format: "RGB" },
+            { color: [0xBF, 0x7F, 0xFF, 0x40], format: "RGBA" },
+            { color: [0xBF, 0xBF, 0xBF, 0xFF], format: "LUMINANCE" },
+            { color: [0xBF, 0xBF, 0xBF, 0x40], format: "LUMINANCE_ALPHA" },
+            { color: [0xBF, 0x00, 0x00, 0xFF], format: "RED", internalformat: "R8" },
+            { color: [0xBF, 0x7F, 0x00, 0xFF], format: "RG", internalformat: "RG8" }
+        ]
+    }
+};
+
+const wtu = WebGLTestUtils;
+const gl = wtu.create3DContext();
+
+wtu.setupTexturedQuad(gl);
+gl.bindTexture(gl.TEXTURE_2D, gl.createTexture());
+
+(async () => {
+    for (const [type, testCase] of Object.entries(testData)) {
+        if (testCase.src.length != 2) throw new Error('testCase.src.length != 2');
+        let images = testCase.src.map(src => loadImage(src));
+        images = await Promise.all(images);
+        debug("");
+        debug("");
+        debug(`PNG image type ${type} with RGBA values of ${testCase.expectations[2].color}`);
+        let formats = testCase.expectations;
+        if (!wtu.isWebGL2(gl)) {
+            formats = formats.filter((f) => !f.internalformat);
+        }
+        for (const f of formats) {
+            debug("");
+            debug(`GL format: ${f.format}`);
+
+            function check(data, description) {
+                debug(`Upload ${description}`);
+                gl.texImage2D(
+                    gl.TEXTURE_2D,
+                    0,
+                    gl[f.internalformat || f.format],
+                    gl[f.format],
+                    gl.UNSIGNED_BYTE,
+                    data
+                );
+                wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+                wtu.clearAndDrawUnitQuad(gl);
+                wtu.checkCanvas(gl, f.color, undefined, 1);
+            }
+
+            check(images[0].image, "8-bit PNG from Image");
+            check(images[1].image, "16-bit PNG from Image");
+
+            if (images[0].bitmap) {
+                check(images[0].bitmap, "8-bit PNG from ImageBitmap");
+                check(images[1].bitmap, "16-bit PNG from ImageBitmap");
+            }
+        }
+    }
+    finishTest();
+})();
+
+async function loadImage(src) {
+    const img = new Image();
+    img.src = src;
+    await img.decode();
+    const ret = { image: img };
+    if (self.createImageBitmap) {
+        try {
+            ret.bitmap = await createImageBitmap(img, {
+                premultiplyAlpha: "none",
+            });
+        } catch {}
+    }
+    return ret;
+}
+
+var successfullyParsed = true;
+    </script>
+</body>
+
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/video-rotation.html b/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/video-rotation.html
index b6d28f1..b336ed6 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/video-rotation.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance/textures/misc/video-rotation.html
@@ -1,5 +1,5 @@
 <!--
-Copyright (c) 2020 The Khronos Group Inc.
+Copyright (c) 2021 The Khronos Group Inc.
 Use of this source code is governed by an MIT-style license that can be
 found in the LICENSE.txt file.
 -->
@@ -29,7 +29,9 @@
         let gl = wtu.create3DContext(canvas);
         let program = tiu.setupTexturedQuad(gl, gl.RGBA);
         const resourcePath = "../../../resources/";
-        const tolerance = 10;
+        const mp4Tolerance = 10;
+        // Significantly higher tolerance needed for VP9 tests. http://crbug.com/1219015 .
+        const vp9Tolerance = 45;
 
         const expectedColors = {
             top: { location: [0.5, 0.25], color: [255, 0, 0] },
@@ -43,7 +45,7 @@
             bufferedLogToConsole(str);
         }
 
-        function checkPixels() {
+        function checkPixels(tolerance) {
             for (let place in expectedColors) {
                 let color = expectedColors[place];
                 let loc = color.location;
@@ -64,7 +66,7 @@
             });
         }
 
-        async function testVideoElement(filename) {
+        async function testVideoElement(filename, isVP9) {
             const video = await loadVideoElement(filename);
 
             output("----------------------------------------------------------------");
@@ -73,80 +75,87 @@
             output("  Testing texImage2D");
             gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, video);
             wtu.clearAndDrawUnitQuad(gl, [0, 0, 0, 255]);
-            checkPixels();
+            const localTolerance = isVP9 ? vp9Tolerance : mp4Tolerance;
+            checkPixels(localTolerance);
 
             output("  Testing texSubImage2D");
             gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, video.videoWidth, video.videoHeight, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
             gl.texSubImage2D(gl.TEXTURE_2D, 0, 0, 0, gl.RGBA, gl.UNSIGNED_BYTE, video);
             wtu.clearAndDrawUnitQuad(gl, [0, 0, 0, 255]);
-            checkPixels();
+            checkPixels(localTolerance);
         }
 
         async function run() {
-            const video = document.createElement('video');
-            if (!video.canPlayType) {
-                testFailed("video.canPlayType required method missing");
-                return;
-            }
+            await (async () => {
+                const video = document.createElement('video');
+                if (!video.canPlayType) {
+                    testFailed("video.canPlayType required method missing");
+                    return;
+                }
 
-            let supports_h264 = !!video.canPlayType('video/mp4; codecs="avc1.42E01E"').replace(/no/, '');
-            let supports_vp9 = !!video.canPlayType('video/mp4; codecs="vp09.00.10.08"').replace(/no/, '');
-            if (!supports_h264 && !supports_vp9) {
-                testFailed("No supported video types.");
-                return;
-            }
+                let supports_h264 = !!video.canPlayType('video/mp4; codecs="avc1.42E01E"').replace(/no/, '');
+                let supports_vp9 = !!video.canPlayType('video/mp4; codecs="vp09.00.10.08"').replace(/no/, '');
+                if (!supports_h264 && !supports_vp9) {
+                    testFailed("No supported video types.");
+                    return;
+                }
 
-            let tex = gl.createTexture();
-            // Bind the texture to the default texture unit 0
-            gl.bindTexture(gl.TEXTURE_2D, tex);
-            // Set up texture parameters
-            gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-            gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-            gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-            gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
+                let tex = gl.createTexture();
+                // Bind the texture to the default texture unit 0
+                gl.bindTexture(gl.TEXTURE_2D, tex);
+                // Set up texture parameters
+                gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
+                gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
+                gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
+                gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
 
-            // These files were created by converting exif-orientation-test-1-normal.jpg to mp4
-            // files, rotating them using the transpose filter, and adding rotate metadata, all
-            // using the ffmpeg command-line tool.
-            //
-            // From sdk/tests/resources/ directory:
-            //
-            // 0:
-            // ffmpeg -noautorotate -i exif-orientation-test-1-normal.jpg -pix_fmt yuv420p -y temp.mp4 &&
-            // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=0 video-rotation-0.mp4
-            // ffmpeg -noautorotate -i exif-orientation-test-1-normal.jpg -pix_fmt yuv420p -crf 0 -vcodec libvpx-vp9 -y temp.mp4 &&
-            // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=0 video-rotation-0.vp9.mp4
-            // 90:
-            // ffmpeg -noautorotate -i exif-orientation-test-1-normal.jpg -vf "transpose=2" -pix_fmt yuv420p -y temp.mp4 &&
-            // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=270 video-rotation-90.mp4
-            // ffmpeg -noautorotate -i exif-orientation-test-1-normal.jpg -vf "transpose=2" -pix_fmt yuv420p -crf 0 -vcodec libvpx-vp9 -y temp.mp4 &&
-            // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=270 video-rotation-90.vp9.mp4
-            // 180:
-            // ffmpeg -noautorotate -i exif-orientation-test-1-normal.jpg -vf "transpose=2,transpose=2" -pix_fmt yuv420p -y temp.mp4 &&
-            // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=180 video-rotation-180.mp4
-            // ffmpeg -noautorotate -i exif-orientation-test-1-normal.jpg -vf "transpose=2,transpose=2" -pix_fmt yuv420p -crf 0 -vcodec libvpx-vp9 -y temp.mp4 &&
-            // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=180 video-rotation-180.vp9.mp4
-            // 270:
-            // ffmpeg -noautorotate -i exif-orientation-test-1-normal.jpg -vf "transpose=1" -pix_fmt yuv420p -y temp.mp4 &&
-            // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=90 video-rotation-270.mp4
-            // ffmpeg -noautorotate -i exif-orientation-test-1-normal.jpg -vf "transpose=1" -pix_fmt yuv420p -crf 0 -vcodec libvpx-vp9 -y temp.mp4 &&
-            // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=90 video-rotation-270.vp9.mp4
-            const filenames = [
-                "video-rotation-0",
-                "video-rotation-90",
-                "video-rotation-180",
-                "video-rotation-270",
-            ];
+                // These files were created by converting exif-orientation-test.psd to mp4
+                // files, rotating them using the transpose filter, and adding rotate metadata, all
+                // using the ffmpeg command-line tool.
+                //
+                // From sdk/tests/resources/ directory:
+                //
+                // 0:
+                // ffmpeg -noautorotate -i exif-orientation-originals\exif-orientation-test.psd -vf scale=128x96 -pix_fmt yuv420p -y temp.mp4
+                // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=0 video-rotation-0.mp4
+                // ffmpeg -noautorotate -i exif-orientation-originals\exif-orientation-test.psd -vf scale=128x96 -pix_fmt yuv420p -crf 0 -vcodec libvpx-vp9 -y temp.mp4
+                // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=0 video-rotation-0.vp9.mp4
+                //
+                // 90:
+                // ffmpeg -noautorotate -i exif-orientation-originals\exif-orientation-test.psd -vf scale=128x96,transpose=2 -pix_fmt yuv420p -y temp.mp4
+                // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=270 video-rotation-90.mp4
+                // ffmpeg -noautorotate -i exif-orientation-originals\exif-orientation-test.psd -vf scale=128x96,transpose=2 -pix_fmt yuv420p -crf 0 -vcodec libvpx-vp9 -y temp.mp4
+                // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=270 video-rotation-90.vp9.mp4
+                //
+                // 180:
+                // ffmpeg -noautorotate -i exif-orientation-originals\exif-orientation-test.psd -vf scale=128x96,transpose=2,transpose=2 -pix_fmt yuv420p -y temp.mp4
+                // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=180 video-rotation-180.mp4
+                // ffmpeg -noautorotate -i exif-orientation-originals\exif-orientation-test.psd -vf scale=128x96,transpose=2,transpose=2 -pix_fmt yuv420p -crf 0 -vcodec libvpx-vp9 -y temp.mp4
+                // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=180 video-rotation-180.vp9.mp4
+                //
+                // 270:
+                // ffmpeg -noautorotate -i exif-orientation-originals\exif-orientation-test.psd -vf scale=128x96,transpose=1 -pix_fmt yuv420p -y temp.mp4
+                // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=90 video-rotation-270.mp4
+                // ffmpeg -noautorotate -i exif-orientation-originals\exif-orientation-test.psd -vf scale=128x96,transpose=1 -pix_fmt yuv420p -crf 0 -vcodec libvpx-vp9 -y temp.mp4
+                // ffmpeg -i temp.mp4 -c copy -metadata:s:v:0 rotate=90 video-rotation-270.vp9.mp4
 
-            if (supports_h264) {
-                for (let fn of filenames)
-                    await testVideoElement(fn + ".mp4");
-            }
+                const filenames = [
+                    "video-rotation-0",
+                    "video-rotation-90",
+                    "video-rotation-180",
+                    "video-rotation-270",
+                ];
 
-            if (supports_vp9) {
-                for (let fn of filenames)
-                    await testVideoElement(fn + ".vp9.mp4");
-            }
+                if (supports_h264) {
+                    for (let fn of filenames)
+                        await testVideoElement(fn + ".mp4", false);
+                }
+
+                if (supports_vp9) {
+                    for (let fn of filenames)
+                        await testVideoElement(fn + ".vp9.mp4", true);
+                }
+            })();
 
             finishTest();
         }
@@ -155,4 +164,4 @@
     </script>
 </body>
 
-</html>
\ No newline at end of file
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/context/methods-2.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/context/methods-2.html
index 50a5b80..a389329 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/context/methods-2.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/context/methods-2.html
@@ -11,6 +11,7 @@
 <link rel="stylesheet" href="../../resources/js-test-style.css"/>
 <script src="../../js/js-test-pre.js"></script>
 <script src="../../js/webgl-test-utils.js"></script>
+<script src="../../js/tests/context-methods.js"></script>
 </head>
 <body>
 <div id="description"></div>
@@ -20,7 +21,7 @@
 "use strict";
 description("This test ensures that the WebGL context has all the methods in the specification.");
 
-var methods = [
+const methods = [
   "getContextAttributes",
   "activeTexture",
   "attachShader",
@@ -249,55 +250,14 @@
   "bindVertexArray",
 ];
 
-// Properties to be ignored because they were added in versions of the
-// spec that are backward-compatible with this version
-var ignoredMethods = [
-  // There is no official spec for the commit API yet, the proposal link is:
-  // https://wiki.whatwg.org/wiki/OffscreenCanvas
-  "commit"
-];
-
-function assertFunction(v, f) {
-  try {
-    if (typeof v[f] != "function") {
-      testFailed("Property either does not exist or is not a function: " + f);
-      return false;
-    } else {
-      return true;
-    }
-  } catch(e) {
-    testFailed("Trying to access the property '" + f + "' threw an error: "+e.toString());
-  }
-}
-
 debug("");
 debug("Canvas.getContext");
 
-var wtu = WebGLTestUtils;
-var canvas = document.getElementById("canvas");
-var gl = wtu.create3DContext(canvas, null, 2);
-var passed = true;
-for (var i=0; i<methods.length; i++) {
-  var r = assertFunction(gl, methods[i]);
-  passed = passed && r;
-}
-if (passed) {
-  testPassed("All WebGL methods found.");
-}
-var extended = false;
-for (var i in gl) {
-  if (typeof gl[i] == "function" && methods.indexOf(i) == -1 && ignoredMethods.indexOf(i) == -1) {
-    if (!extended) {
-      extended = true;
-      testFailed("Also found the following extra methods:");
-    }
-    testFailed(i);
-  }
-}
+const wtu = WebGLTestUtils;
+const canvas = document.getElementById("canvas");
+const gl = wtu.create3DContext(canvas, null, 2);
 
-if (!extended) {
-  testPassed("No extra methods found on WebGL context.");
-}
+testContextMethods(gl, methods);
 
 debug("");
 var successfullyParsed = true;
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/ext-color-buffer-float.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/ext-color-buffer-float.html
index e2eebd1..b57a6ca 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/ext-color-buffer-float.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/ext-color-buffer-float.html
@@ -284,7 +284,7 @@
     debug("testing the internal format query");
 
     var maxSamples = gl.getParameter(gl.MAX_SAMPLES);
-    var formats = new Array(gl.RGBA16F, gl.R32F, gl.RG32F, gl.RGBA32F, gl.R16F, gl.RG16F, gl.R11F_G11F_B10F);
+    const formats = [gl.RGBA16F, gl.R32F, gl.RG32F, gl.RGBA32F, gl.R16F, gl.RG16F, gl.R11F_G11F_B10F];
     var firstMultiOnlyFormat = 4;
     for (var fmt = 0; fmt < formats.length; ++fmt) {
         var samples = gl.getInternalformatParameter(gl.RENDERBUFFER, formats[fmt], gl.SAMPLES);
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/ext-texture-norm16.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/ext-texture-norm16.html
index 1d9ff64..31ed8f3 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/ext-texture-norm16.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/ext-texture-norm16.html
@@ -153,6 +153,23 @@
                                 "framebuffer should not be complete with SNORM16 texture attached");
 }
 
+function runInternalFormatQueryTest()
+{
+    debug("");
+    debug("testing the internal format query");
+
+    var maxSamples = gl.getParameter(gl.MAX_SAMPLES);
+    const formats = [ext.R16_EXT, ext.RG16_EXT, ext.RGBA16_EXT];
+    for (const format of formats) {
+        var samples = gl.getInternalformatParameter(gl.RENDERBUFFER, format, gl.SAMPLES);
+        if (samples == null || samples.length == 0 || samples[0] < maxSamples) {
+            testFailed("the maximum value in SAMPLES should be at least " + maxSamples);
+            return;
+        }
+    }
+    testPassed("Internal format query succeeded");
+}
+
 function runTestExtension() {
   textures = [gl.createTexture(), gl.createTexture()];
   fbos = [gl.createFramebuffer(), gl.createFramebuffer()];
@@ -207,6 +224,7 @@
     wtu.runExtensionSupportedTest(gl, "EXT_texture_norm16", ext !== null);
 
     if (ext !== null) {
+      runInternalFormatQueryTest();
       runTestExtension();
     } else {
       testPassed("No EXT_texture_norm16 support -- this is legal");
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/oes-draw-buffers-indexed.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/oes-draw-buffers-indexed.html
index 3be7717..e35cc26 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/oes-draw-buffers-indexed.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/oes-draw-buffers-indexed.html
@@ -79,6 +79,8 @@
 
     // Invalid input
     ext.enableiOES(gl.DEPTH_TEST, 0);
+    wtu.glErrorShouldBe(gl, gl.INVALID_ENUM, 'target could only be gl.BLEND');
+
     ext.disableiOES(gl.DEPTH_TEST, 0);
     wtu.glErrorShouldBe(gl, gl.INVALID_ENUM, 'target could only be gl.BLEND');
 
@@ -164,7 +166,10 @@
 }
 
 function indexedBlendColorTest() {
+    debug('');
     debug("Testing blendEquationiOES and blendFunciOES");
+    wtu.glErrorShouldBe(gl, 0, 'top of indexedBlendColorTest');
+
     gl.clearColor(0, 0, 1, 1);
     gl.clear(gl.COLOR_BUFFER_BIT);
 
@@ -211,22 +216,32 @@
     gl.readBuffer(gl.COLOR_ATTACHMENT1);
     wtu.checkCanvasRect(gl, 0, 0, 1, 1, [0, 0, 255, 0]);
 
-    debug("Testing new tokens for getIndexedParameterTest");
-    shouldBe('gl.getIndexedParameter(ext.BLEND_EQUATION_RGB, 0)', 'gl.FUNC_ADD');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_EQUATION_ALPHA, 0)', 'gl.FUNC_SUBTRACT');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_SRC_RGB, 0)', 'gl.ONE');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_DST_RGB, 0)', 'gl.ONE');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_SRC_ALPHA, 0)', 'gl.ZERO');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_DST_ALPHA, 0)', 'gl.ZERO');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_EQUATION_RGB, 1)', 'gl.FUNC_ADD');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_EQUATION_ALPHA, 1)', 'gl.FUNC_SUBTRACT');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_SRC_RGB, 1)', 'gl.SRC_ALPHA');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_DST_RGB, 1)', 'gl.ONE_MINUS_SRC_ALPHA');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_SRC_ALPHA, 1)', 'gl.ZERO');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_DST_ALPHA, 1)', 'gl.ZERO');
+    debug('');
+    debug(`Testing that new tokens aren't on the extension.`);
+    shouldBe('ext.BLEND_EQUATION_RGB', 'undefined');
+    shouldBe('ext.BLEND_EQUATION_ALPHA', 'undefined');
+    shouldBe('ext.BLEND_SRC_RGB', 'undefined');
+    shouldBe('ext.BLEND_SRC_ALPHA', 'undefined');
+    shouldBe('ext.BLEND_DST_RGB', 'undefined');
+    shouldBe('ext.BLEND_DST_ALPHA', 'undefined');
+    shouldBe('ext.COLOR_WRITEMASK', 'undefined');
 
-    shouldBe('gl.getIndexedParameter(ext.COLOR_WRITEMASK, 0)', '[false, false, false, false]');
-    shouldBe('gl.getIndexedParameter(ext.COLOR_WRITEMASK, 1)', '[true, true, true, true]');
+    debug("Testing new tokens for getIndexedParameterTest");
+    shouldBe('gl.getIndexedParameter(gl.BLEND_EQUATION_RGB, 0)', 'gl.FUNC_ADD');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_EQUATION_ALPHA, 0)', 'gl.FUNC_SUBTRACT');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_SRC_RGB, 0)', 'gl.ONE');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_DST_RGB, 0)', 'gl.ONE');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_SRC_ALPHA, 0)', 'gl.ZERO');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_DST_ALPHA, 0)', 'gl.ZERO');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_EQUATION_RGB, 1)', 'gl.FUNC_ADD');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_EQUATION_ALPHA, 1)', 'gl.FUNC_SUBTRACT');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_SRC_RGB, 1)', 'gl.SRC_ALPHA');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_DST_RGB, 1)', 'gl.ONE_MINUS_SRC_ALPHA');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_SRC_ALPHA, 1)', 'gl.ZERO');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_DST_ALPHA, 1)', 'gl.ZERO');
+
+    shouldBe('gl.getIndexedParameter(gl.COLOR_WRITEMASK, 0)', '[false, false, false, false]');
+    shouldBe('gl.getIndexedParameter(gl.COLOR_WRITEMASK, 1)', '[true, true, true, true]');
 
     debug("Testing non-indexed getParamter get state from draw buffer 0");
     shouldBe('gl.getParameter(gl.BLEND_SRC_RGB)', 'gl.ONE');
@@ -251,26 +266,28 @@
     shouldBe('gl.getParameter(gl.BLEND_DST_ALPHA)', 'gl.ONE');
     shouldBe('gl.getParameter(gl.COLOR_WRITEMASK)', '[true, false, true, false]');
 
-    shouldBe('gl.getIndexedParameter(ext.BLEND_EQUATION_RGB, 0)', 'gl.FUNC_SUBTRACT');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_EQUATION_ALPHA, 0)', 'gl.FUNC_ADD');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_SRC_RGB, 0)', 'gl.ONE_MINUS_DST_ALPHA');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_DST_RGB, 0)', 'gl.DST_ALPHA');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_SRC_ALPHA, 0)', 'gl.ONE');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_DST_ALPHA, 0)', 'gl.ONE');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_EQUATION_RGB, 1)', 'gl.FUNC_SUBTRACT');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_EQUATION_ALPHA, 1)', 'gl.FUNC_ADD');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_SRC_RGB, 1)', 'gl.ONE_MINUS_DST_ALPHA');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_DST_RGB, 1)', 'gl.DST_ALPHA');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_SRC_ALPHA, 1)', 'gl.ONE');
-    shouldBe('gl.getIndexedParameter(ext.BLEND_DST_ALPHA, 1)', 'gl.ONE');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_EQUATION_RGB, 0)', 'gl.FUNC_SUBTRACT');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_EQUATION_ALPHA, 0)', 'gl.FUNC_ADD');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_SRC_RGB, 0)', 'gl.ONE_MINUS_DST_ALPHA');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_DST_RGB, 0)', 'gl.DST_ALPHA');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_SRC_ALPHA, 0)', 'gl.ONE');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_DST_ALPHA, 0)', 'gl.ONE');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_EQUATION_RGB, 1)', 'gl.FUNC_SUBTRACT');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_EQUATION_ALPHA, 1)', 'gl.FUNC_ADD');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_SRC_RGB, 1)', 'gl.ONE_MINUS_DST_ALPHA');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_DST_RGB, 1)', 'gl.DST_ALPHA');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_SRC_ALPHA, 1)', 'gl.ONE');
+    shouldBe('gl.getIndexedParameter(gl.BLEND_DST_ALPHA, 1)', 'gl.ONE');
 
-    shouldBe('gl.getIndexedParameter(ext.COLOR_WRITEMASK, 0)', '[true, false, true, false]');
-    shouldBe('gl.getIndexedParameter(ext.COLOR_WRITEMASK, 1)', '[true, false, true, false]');
+    shouldBe('gl.getIndexedParameter(gl.COLOR_WRITEMASK, 0)', '[true, false, true, false]');
+    shouldBe('gl.getIndexedParameter(gl.COLOR_WRITEMASK, 1)', '[true, false, true, false]');
 }
 
 function runTestExtension() {
     setup();
 
+    testInvalidValues();
+
     enableDisableTest();
 
     // blending should be enabled for drawBuffers 0 and 1 at this point
@@ -278,6 +295,8 @@
     constantAlphaBlendColorValidationTest();
 
     indexedBlendColorTest();
+
+    testColorMaskDrawNoOp();
 }
 
 function runInvalidEnumsTest() {
@@ -298,6 +317,206 @@
     wtu.glErrorShouldBe(gl, [gl.INVALID_OPERATION, gl.INVALID_ENUM], 'invalid operations or invalid enums for COLOR_WRITEMASK');
 }
 
+function testInvalidValues() {
+    const numDrawBuffers = gl.getParameter(gl.MAX_DRAW_BUFFERS);
+    if (!numDrawBuffers) throw new Error('!numDrawBuffers');
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.enableiOES(gl.BLEND, -1)`);
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.enableiOES(gl.BLEND, ${numDrawBuffers})`);
+    wtu.shouldGenerateGLError(gl, 0, `ext.enableiOES(gl.BLEND, ${numDrawBuffers-1})`);
+
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.disableiOES(gl.BLEND, -1)`);
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.disableiOES(gl.BLEND, ${numDrawBuffers})`);
+    wtu.shouldGenerateGLError(gl, 0, `ext.disableiOES(gl.BLEND, ${numDrawBuffers-1})`);
+
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.blendEquationiOES(-1, gl.FUNC_ADD)`);
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.blendEquationiOES(${numDrawBuffers}, gl.FUNC_ADD)`);
+    wtu.shouldGenerateGLError(gl, 0, `ext.blendEquationiOES(${numDrawBuffers-1}, gl.FUNC_ADD)`);
+
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.blendEquationSeparateiOES(-1, gl.FUNC_ADD, gl.FUNC_ADD)`);
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.blendEquationSeparateiOES(${numDrawBuffers}, gl.FUNC_ADD, gl.FUNC_ADD)`);
+    wtu.shouldGenerateGLError(gl, 0, `ext.blendEquationSeparateiOES(${numDrawBuffers-1}, gl.FUNC_ADD, gl.FUNC_ADD)`);
+
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.blendFunciOES(-1, gl.ONE, gl.ONE)`);
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.blendFunciOES(${numDrawBuffers}, gl.ONE, gl.ONE)`);
+    wtu.shouldGenerateGLError(gl, 0, `ext.blendFunciOES(${numDrawBuffers-1}, gl.ONE, gl.ONE)`);
+
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.blendFuncSeparateiOES(-1, gl.ONE, gl.ZERO, gl.ONE, gl.ZERO)`);
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.blendFuncSeparateiOES(${numDrawBuffers}, gl.ONE, gl.ZERO, gl.ONE, gl.ZERO)`);
+    wtu.shouldGenerateGLError(gl, 0, `ext.blendFuncSeparateiOES(${numDrawBuffers-1}, gl.ONE, gl.ZERO, gl.ONE, gl.ZERO)`);
+
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.colorMaskiOES(-1, 1,1,1,1)`);
+    wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, `ext.colorMaskiOES(${numDrawBuffers}, 1,1,1,1)`);
+    wtu.shouldGenerateGLError(gl, 0, `ext.colorMaskiOES(${numDrawBuffers-1}, 1,1,1,1)`);
+}
+
+function* range(n) {
+  for (let i = 0; i < n; i++) {
+    yield i;
+  }
+}
+
+function testColorMaskDrawNoOp() {
+    debug('');
+    debug('testColorMaskDrawNoOp')
+    // > If any draw buffer with an attachment does not have a defined
+    //   fragment shader output, draws generate INVALID_OPERATION,
+    //   unless all 4 channels of colorMask are set to false.
+    const NUM_OUTPUTS = gl.getParameter(gl.MAX_COLOR_ATTACHMENTS);
+    shouldBeTrue(`${NUM_OUTPUTS} > 1`);
+
+    const fb = gl.createFramebuffer();
+    gl.bindFramebuffer(gl.FRAMEBUFFER, fb);
+    gl.viewport(0,0,1,1);
+
+    const DRAW_BUFFERS = [];
+    for (const i of range(NUM_OUTPUTS)) {
+        const tex = gl.createTexture();
+        gl.bindTexture(gl.TEXTURE_2D, tex);
+        gl.texStorage2D(gl.TEXTURE_2D, 1, gl.RGBA8, 1, 1);
+        const ca = gl.COLOR_ATTACHMENT0+i;
+        DRAW_BUFFERS.push(ca)
+        gl.framebufferTexture2D(gl.FRAMEBUFFER, ca,
+                                gl.TEXTURE_2D, tex, 0);
+    }
+    shouldBe('gl.checkFramebufferStatus(gl.FRAMEBUFFER)', 'gl.FRAMEBUFFER_COMPLETE');
+
+    gl.drawBuffers(DRAW_BUFFERS);
+    gl.colorMask(1, 1, 1, 1);
+    gl.disable(gl.BLEND);
+
+    gl.clearColor(0, 0, 0, 0);
+    gl.clear(gl.COLOR_BUFFER_BIT);
+
+    for (const i of range(NUM_OUTPUTS)) {
+        gl.readBuffer(gl.COLOR_ATTACHMENT0+i);
+        wtu.checkCanvasRect(gl, 0, 0, 1, 1, [0, 0, 0, 0], `COLOR_ATTACHMENT${i} initially black`);
+    }
+
+    for (const validOutput of range(NUM_OUTPUTS)) {
+        const invalidOutput = validOutput ^ 0b11;
+        debug(`validOutput: ${validOutput}, invalidOutput: ${invalidOutput}`);
+        const prog = wtu.setupProgram(gl, [
+            `\
+#version 300 es
+void main() {
+    gl_Position = vec4(0,0,0,1);
+    gl_PointSize = 1.0f;
+}
+`,
+            `\
+#version 300 es
+precision mediump float;
+layout(location=${validOutput}) out vec4 o_color;
+void main() {
+    o_color = vec4(1,1,1,1);
+}
+`
+        ]);
+        gl.useProgram(prog);
+
+        wtu.glErrorShouldBe(gl, gl.NO_ERROR,
+            'After init.');
+
+        gl.colorMask(1,1,1,1);
+        gl.drawBuffers(DRAW_BUFFERS);
+        gl.drawArrays(gl.POINTS, 0, 1);
+        wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION,
+            'Drawing with unmasked undefined color outputs.');
+
+        gl.colorMask(0,0,0,0);
+        gl.drawBuffers(DRAW_BUFFERS);
+        gl.drawArrays(gl.POINTS, 0, 1);
+        wtu.glErrorShouldBe(gl, gl.NO_ERROR,
+            'Drawing with colorMask-masked-out undefined color outputs.');
+
+        gl.colorMask(1,1,1,1);
+        gl.drawBuffers(DRAW_BUFFERS.map((x,i) => (i == invalidOutput) ? x : 0));
+        gl.drawArrays(gl.POINTS, 0, 1);
+        wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION,
+            'Drawing with wrong-id drawBuffer-masked-out undefined color outputs.');
+
+        gl.drawBuffers(DRAW_BUFFERS.map((x,i) => (i == validOutput) ? x : 0));
+        gl.drawArrays(gl.POINTS, 0, 1);
+        wtu.glErrorShouldBe(gl, gl.NO_ERROR,
+            'Drawing with drawBuffer-masked-out undefined color outputs.');
+
+        gl.colorMask(0,0,0,0);
+        gl.drawBuffers([]);
+        gl.drawArrays(gl.POINTS, 0, 1);
+        wtu.glErrorShouldBe(gl, gl.NO_ERROR,
+            'Drawing with colorMask+drawBuffer-masked-out undefined color outputs.');
+
+        const testMask = (r,g,b,a) => {
+            debug(`testMask(${[r,g,b,a]})`);
+            gl.drawBuffers(DRAW_BUFFERS);
+
+            gl.colorMask(1,1,1,1);
+            gl.clearColor(0, 0, 0, 0);
+            gl.clear(gl.COLOR_BUFFER_BIT);
+            gl.colorMask(0,0,0,0);
+            ext.colorMaskiOES(validOutput, r,g,b,a);
+            gl.drawArrays(gl.POINTS, 0, 1);
+            wtu.glErrorShouldBe(gl, gl.NO_ERROR,
+                `Drawing with sole defined color${validOutput} output writemask: ${[r,g,b,a]}.`);
+
+            for (const i of range(NUM_OUTPUTS)) {
+                gl.readBuffer(gl.COLOR_ATTACHMENT0+i);
+                let expect = [0,0,0,0];
+                if (i == validOutput) {
+                    expect = [r,g,b,a].map(x => 0xff*x);
+                }
+                wtu.checkCanvasRect(gl, 0, 0, 1, 1, expect, `COLOR_ATTACHMENT${i}: [${expect}]`);
+            }
+
+            gl.colorMask(1,1,1,1);
+            gl.clearColor(0, 0, 0, 0);
+            gl.clear(gl.COLOR_BUFFER_BIT);
+            gl.colorMask(r,g,b,a);
+            for (const i of range(NUM_OUTPUTS)) {
+                if (i == validOutput) continue;
+                ext.colorMaskiOES(i, 0,0,0,0);
+            }
+            gl.drawArrays(gl.POINTS, 0, 1);
+            wtu.glErrorShouldBe(gl, gl.NO_ERROR,
+                `Drawing with sole remaining defined color${validOutput} output writemask: ${[r,g,b,a]}.`);
+
+            for (const i of range(NUM_OUTPUTS)) {
+                gl.readBuffer(gl.COLOR_ATTACHMENT0+i);
+                let expect = [0,0,0,0];
+                if (i == validOutput) {
+                    expect = [r,g,b,a].map(x => 0xff*x);
+                }
+                wtu.checkCanvasRect(gl, 0, 0, 1, 1, expect, `COLOR_ATTACHMENT${i}: [${expect}]`);
+            }
+
+            if (r || g || b || a) {
+                gl.colorMask(0,0,0,0);
+                ext.colorMaskiOES(invalidOutput, r,g,b,a);
+                gl.drawArrays(gl.POINTS, 0, 1);
+                wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION,
+                    `Drawing with wrong-id undefined color output color masked: ${[r,g,b,a]}.`);
+
+                gl.drawBuffers([]);
+                gl.drawArrays(gl.POINTS, 0, 1);
+                wtu.glErrorShouldBe(gl, gl.NO_ERROR,
+                    'Drawing with wrong-id colorMask, but all-off drawBuffers.');
+
+                gl.drawBuffers(DRAW_BUFFERS.map((x,i) => (i == validOutput) ? x : 0));
+                gl.drawArrays(gl.POINTS, 0, 1);
+                wtu.glErrorShouldBe(gl, gl.NO_ERROR,
+                    'Drawing with wrong-id colorMask, but right-id drawBuffers masked.');
+            }
+        };
+
+        testMask(0,0,0,0);
+        testMask(1,0,0,0);
+        testMask(0,1,0,0);
+        testMask(0,0,1,0);
+        testMask(0,0,0,1);
+        testMask(1,1,1,1);
+    }
+}
+
 function runTest() {
   if (!gl) {
     testFailed("context does not exist");
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/required-extensions.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/required-extensions.html
new file mode 100644
index 0000000..c3de2a5
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/required-extensions.html
@@ -0,0 +1,58 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<link rel="stylesheet" href="../../resources/js-test-style.css"/>
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+
+<script>
+"use strict";
+const wtu = WebGLTestUtils;
+let gl;
+
+description("Ensure that required extensions are supported");
+
+shouldBeNonNull("gl = wtu.create3DContext(undefined, undefined, 2)");
+
+const supportedExts = gl.getSupportedExtensions();
+
+function hasExt(name) {
+    return supportedExts.indexOf(name) >= 0;
+}
+
+const has_s3tc = hasExt('WEBGL_compressed_texture_s3tc');
+const has_s3tc_srgb = hasExt('WEBGL_compressed_texture_s3tc_srgb');
+const has_rgtc = hasExt('EXT_texture_compression_rgtc');
+const has_etc = hasExt('WEBGL_compressed_texture_etc');
+
+debug(`has_s3tc: ${has_s3tc}`);
+debug(`has_s3tc_srgb: ${has_s3tc_srgb}`);
+debug(`has_rgtc: ${has_rgtc}`);
+debug(`has_etc: ${has_etc}`);
+
+shouldBeTrue("((has_s3tc && has_s3tc_srgb && has_rgtc) || has_etc)");
+
+// ETC1 extension must not be exposed on WebGL 2.0 contexts without ETC2.
+debug("");
+const has_etc1 = hasExt('WEBGL_compressed_texture_etc1');
+debug(`has_etc1: ${has_etc1}`);
+shouldBeTrue("has_etc1 == has_etc");
+
+debug("");
+var successfullyParsed = true;
+</script>
+
+<script src="../../js/js-test-post.js"></script>
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/webgl-multi-draw-instanced-base-vertex-base-instance.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/webgl-multi-draw-instanced-base-vertex-base-instance.html
index 9555b04..128a4fc 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/webgl-multi-draw-instanced-base-vertex-base-instance.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/extensions/webgl-multi-draw-instanced-base-vertex-base-instance.html
@@ -9,7 +9,7 @@
 <script src="../../js/webgl-test-utils.js"></script>
 </head>
 <body>
-<script id="vshaderIllegalBaseInstance" type="x-shader/x-vertex">#version 300 es
+<script id="vshaderBaseInstanceWithoutExt" type="x-shader/x-vertex">#version 300 es
 layout(location = 0) in vec2 vPosition;
 out vec4 color;
 void main()
@@ -18,20 +18,6 @@
   gl_Position = vec4(vPosition * 2.0 - 1.0, gl_BaseInstance, 1);
 }
 </script>
-<script id="vshaderBaseInstanceZero" type="x-shader/x-vertex">#version 300 es
-#extension GL_ANGLE_base_vertex_base_instance : require
-layout(location = 0) in vec2 vPosition;
-out vec4 color;
-void main()
-{
-  if (gl_BaseInstance == 0) {
-    color = vec4(0, 1, 0, 1);
-  } else {
-    color = vec4(1, 0, 0, 1);
-  }
-  gl_Position = vec4(vPosition * 2.0 - 1.0, 0, 1);
-}
-</script>
 <!-- Check gl_InstanceID starts at 0 regardless of gl_BaseInstance -->
 <script id="vshaderInstanceIDCheck" type="x-shader/x-vertex">#version 300 es
 layout(location = 0) in vec2 vPosition;
@@ -46,7 +32,7 @@
   gl_Position = vec4(vPosition * 2.0 - 1.0, 0, 1);
 }
 </script>
-<script id="vshaderIllegalBaseVertex" type="x-shader/x-vertex">#version 300 es
+<script id="vshaderBaseVertexWithoutExt" type="x-shader/x-vertex">#version 300 es
 layout(location = 0) in vec2 vPosition;
 out vec4 color;
 void main()
@@ -55,17 +41,13 @@
   gl_Position = vec4(vPosition * 2.0 - 1.0, gl_BaseVertex, 1);
 }
 </script>
-<script id="vshaderBaseVertexZero" type="x-shader/x-vertex">#version 300 es
+<script id="vshaderWithExt" type="x-shader/x-vertex">#version 300 es
 #extension GL_ANGLE_base_vertex_base_instance : require
 layout(location = 0) in vec2 vPosition;
 out vec4 color;
 void main()
 {
-  if (gl_BaseVertex == 0) {
-    color = vec4(0, 1, 0, 1);
-  } else {
-    color = vec4(1, 0, 0, 1);
-  }
+  color = vec4(0, 1, 0, 1);
   gl_Position = vec4(vPosition * 2.0 - 1.0, 0, 1);
 }
 </script>
@@ -84,7 +66,6 @@
 }
 </script>
 <script id="vshaderSimple" type="x-shader/x-vertex">#version 300 es
-  #extension GL_ANGLE_base_vertex_base_instance : require
   layout(location = 0) in vec2 vPosition;
   layout(location = 1) in float vInstance;
   out vec4 color;
@@ -121,7 +102,13 @@
 
 const wtu = WebGLTestUtils;
 const canvas = document.getElementById("canvas");
-const gl = wtu.create3DContext(canvas, null, 2);
+canvas.style.backgroundColor = '#000';
+canvas.style.imageRendering = 'pixelated'; // Because Chrome doesn't support crisp-edges.
+canvas.style.imageRendering = 'crisp-edges';
+const attribs = {
+  antialias: false,
+};
+const gl = wtu.create3DContext(canvas, attribs, 2);
 
 const width = gl.canvas.width;
 const height = gl.canvas.height;
@@ -270,8 +257,250 @@
 
   doTest('WEBGL_draw_instanced_base_vertex_base_instance', false);
   doTest('WEBGL_multi_draw_instanced_base_vertex_base_instance', true);
+
+  testGlslBuiltins();
 }
 
+// -
+
+function* range(n) {
+  for (let i = 0; i < n; i++) {
+    yield i;
+  }
+}
+
+function crossCombine(...args) {
+  function crossCombine2(listA, listB) {
+    const listC = [];
+    for (const a of listA) {
+      for (const b of listB) {
+        const c = Object.assign({}, a, b);
+        listC.push(c);
+      }
+    }
+    return listC;
+  }
+
+  let res = [{}];
+  while (args.length) {
+    const next = args.shift();
+    next[0].defined;
+    res = crossCombine2(res, next);
+  }
+  return res;
+}
+
+// -
+
+const PASSTHROUGH_FRAG_SRC = `\
+#version 300 es
+precision mediump float;
+in vec4 v_color;
+out vec4 o_color;
+
+void main() {
+  o_color = v_color;
+}
+`;
+
+function testGlslBuiltins() {
+  const EXT = gl.getExtension('WEBGL_draw_instanced_base_vertex_base_instance');
+
+  const vertid_prog = (() => {
+      const vert_src = `\
+#version 300 es
+#line 405
+layout(location = 0) in int a_vertex_id; // Same as gl_VertexID
+out vec4 v_color;
+
+void main() {
+  gl_Position = vec4(0,0,0,1);
+  gl_PointSize = 1.0;
+  v_color = vec4(float(gl_VertexID), float(a_vertex_id),0,0);
+  v_color /= 255.0;
+}
+`;
+      const prog = wtu.setupProgram(gl, [vert_src, PASSTHROUGH_FRAG_SRC],
+              undefined, undefined, /*logShaders*/ true);
+      expectTrue(!!prog, `make_vertid_prog failed`);
+      return prog;
+    })();
+
+  const instid_prog = (() => {
+      const vert_src = `\
+#version 300 es
+#line 425
+layout(location = 0) in int a_vertex_id; // Same as gl_VertexID
+layout(location = 1) in int a_instance_div1; // Same as base_instance+gl_InstanceID
+layout(location = 2) in int a_instance_div2; // Same as base_instance+floor(gl_InstanceID/2)
+layout(location = 3) in int a_instance_div3; // Same as base_instance+floor(gl_InstanceID/3)
+out vec4 v_color;
+
+void main() {
+  gl_Position = vec4(0,0,0,1);
+  gl_PointSize = 1.0;
+  v_color = vec4(float(gl_InstanceID), float(a_instance_div1),
+                 float(a_instance_div2), float(a_instance_div3));
+  v_color /= 255.0;
+}
+`;
+      const prog = wtu.setupProgram(gl, [vert_src, PASSTHROUGH_FRAG_SRC],
+              undefined, undefined, /*logShaders*/ true);
+      expectTrue(!!prog, `make_instid_prog failed`);
+      return prog;
+    })();
+
+  const COUNT_UP_DATA = new Int32Array(1000);
+  for (const i in COUNT_UP_DATA) {
+    COUNT_UP_DATA[i] = i;
+  }
+
+  const vertex_id_buf = gl.createBuffer();
+  gl.bindBuffer(gl.ARRAY_BUFFER, vertex_id_buf);
+  gl.bufferData(gl.ARRAY_BUFFER, COUNT_UP_DATA, gl.STATIC_DRAW);
+  gl.enableVertexAttribArray(0);
+  gl.vertexAttribIPointer(0, 1, gl.INT, 0, 0);
+
+  gl.enableVertexAttribArray(1);
+  gl.vertexAttribIPointer(1, 1, gl.INT, 0, 0);
+  gl.vertexAttribDivisor(1, 1);
+
+  gl.enableVertexAttribArray(2);
+  gl.vertexAttribIPointer(2, 1, gl.INT, 0, 0);
+  gl.vertexAttribDivisor(2, 2);
+
+  gl.enableVertexAttribArray(3);
+  gl.vertexAttribIPointer(3, 1, gl.INT, 0, 0);
+  gl.vertexAttribDivisor(3, 3);
+
+  const index_buf = gl.createBuffer();
+  gl.bindBuffer(gl.ELEMENT_ARRAY_BUFFER, index_buf);
+  gl.bufferData(gl.ELEMENT_ARRAY_BUFFER, COUNT_UP_DATA, gl.STATIC_DRAW);
+
+  gl.canvas.width = gl.canvas.height = 1;
+  gl.canvas.style.width = gl.canvas.style.height = '1em';
+  gl.viewport(0, 0, 1, 1);
+
+  const expect_pixel = (() => {
+    const was = new Uint8Array(4);
+    return (desc, subtest, expected) => {
+      gl.readPixels(0, 0, 1, 1, gl.RGBA, gl.UNSIGNED_BYTE, was);
+      if (!areArraysEqual(was, expected)) {
+        testFailed(`${subtest}: Expected [${expected}], was [${was}]. desc: ${JSON.stringify(desc)}`);
+      } else {
+        debug(`${subtest}: Was [${was}] as expected.`);
+      }
+    };
+  })();
+
+  // Common setup complete
+  // -
+  // Create testcases
+
+  const DRAW_FUNC_COMBINER = [{
+    name: 'drawArraysInstanced',
+    draw: desc => {
+      if (desc.base_vert) return false;
+      if (desc.base_inst) return false;
+      gl.drawArraysInstanced(gl[desc.mode], desc.first_vert,
+          desc.vert_count, desc.inst_count);
+      return true;
+    },
+  }, {
+    name: 'drawElementsInstanced',
+    draw: desc => {
+      if (desc.base_vert) return false;
+      if (desc.base_inst) return false;
+      gl.drawElementsInstanced(gl[desc.mode], desc.vert_count,
+          gl.UNSIGNED_INT, 4*desc.first_vert, desc.inst_count);
+      return true;
+    },
+  }, {
+    name: 'drawArraysInstancedBaseInstanceWEBGL',
+    draw: desc => {
+      if (desc.base_vert) return false;
+      if (!EXT) return false;
+      EXT.drawArraysInstancedBaseInstanceWEBGL(gl[desc.mode],
+        desc.first_vert, desc.vert_count, desc.inst_count,
+        desc.base_inst);
+      return true;
+    },
+  }, {
+    name: 'drawElementsInstancedBaseVertexBaseInstanceWEBGL',
+    draw: desc => {
+      if (!EXT) return false;
+      EXT.drawElementsInstancedBaseVertexBaseInstanceWEBGL(
+          gl[desc.mode], desc.vert_count, gl.UNSIGNED_INT, 4*desc.first_vert,
+          desc.inst_count, desc.base_vert, desc.base_inst);
+      return true;
+    },
+  }];
+
+  // -
+
+  function make_key_combiner(key, vals) {
+    const ret = [];
+    for (const v of vals) {
+      const cur = {};
+      cur[key] = v;
+      ret.push(cur);
+    }
+    return ret;
+  }
+
+  const TEST_DESCS = crossCombine(
+    DRAW_FUNC_COMBINER,
+    make_key_combiner('base_vert', [0,1,2]),
+    make_key_combiner('vert_count', [0,1,2]),
+    make_key_combiner('base_inst', [0,1,2]),
+    make_key_combiner('inst_count', range(10)),
+    make_key_combiner('first_vert', [0,1,2]),
+  );
+  console.log('TEST_DESCS', TEST_DESCS);
+
+  // -
+  // Run testcases
+
+  gl.disable(gl.DEPTH_TEST);
+  gl.disable(gl.STENCIL_TEST);
+  gl.disable(gl.BLEND);
+
+  for (const desc of TEST_DESCS) {
+    gl.disable(gl.SCISSOR_TEST);
+    gl.clearBufferfv(gl.COLOR, 0, [1,0,0,1]);
+
+    // From OpenGL ES 3.2 spec section 10.5
+    // https://www.khronos.org/registry/OpenGL/specs/es/3.2/es_spec_3.2.pdf
+    // The index of any element transferred to the GL by DrawArraysOneInstance
+    // is referred to as its vertex ID, and may be read by a vertex shader as gl_VertexID.
+    // The vertex ID of the ith element transferred is first + i.
+    const last_gl_vert_id = desc.base_vert + desc.first_vert + desc.vert_count - 1;
+    const last_vert_id = last_gl_vert_id;
+    const last_inst_id = desc.inst_count - 1;
+    const last_inst_div1 = desc.base_inst + last_inst_id;
+    const last_inst_div2 = desc.base_inst + Math.floor(last_inst_id / 2);
+    const last_inst_div3 = desc.base_inst + Math.floor(last_inst_id / 3);
+
+    gl.useProgram(vertid_prog);
+    if (!desc.draw(desc)) continue;
+    debug('\ndesc: ' + JSON.stringify(desc));
+
+    wtu.glErrorAssert(gl, 0);
+    if (!desc.vert_count || !desc.inst_count) {
+      expect_pixel(desc, 'vertid_prog', [255, 0, 0, 255]);
+      continue;
+    }
+
+    expect_pixel(desc, 'vertid_prog', [last_gl_vert_id, last_vert_id, 0, 0]);
+
+    gl.useProgram(instid_prog);
+    desc.draw(desc);
+    expect_pixel(desc, 'instid_prog', [last_inst_id, last_inst_div1, last_inst_div2, last_inst_div3]);
+  }
+}
+
+// -
+
 function doTest(extensionName, multiDraw) {
   const ext = gl.getExtension(extensionName);
   if (!runSupportedTest(extensionName, ext)) {
@@ -282,21 +511,19 @@
     const vs = [
       '#version 300 es',
       config.isMultiDraw ? '#extension GL_ANGLE_multi_draw : require' : '',
-      '#extension GL_ANGLE_base_vertex_base_instance : require',
       '#define kCountX ' + countX.toString(),
       '#define kCountY ' + countY.toString(),
       'layout(location = 0) in vec2 vPosition;',
-      config.useBaseInstanceBuiltin ? '' : 'layout(location = 1) in float vInstanceID;',
+      'layout(location = 1) in float vInstanceID;',
       'out vec4 color;',
       'void main()',
       '{',
       '  const float xStep = 1.0 / float(kCountX);',
       '  const float yStep = 1.0 / float(kCountY);',
-      '  float xID = ' + (config.useBaseInstanceBuiltin ? 'float(gl_InstanceID + gl_BaseInstance)' : 'vInstanceID') + ';',
+      '  float xID = vInstanceID;',
       '  float xColor = 1.0 - xStep * xID;',
       '  float yID = floor(float(gl_VertexID) / ' + (config.isDrawArrays ? '6.0' : '4.0') + ' + 0.01);',
-      '  color = vec4(xColor, 1.0 - yStep * yID, ',
-      config.useBaseVertexBuiltin ? '1.0 - yStep * float(gl_BaseVertex) / 4.0' : '1.0',
+      '  color = vec4(xColor, 1.0 - yStep * yID, 1.0',
       '  , 1.0);',
       '  mat3 transform = mat3(1.0);',
       '  transform[2][0] = xID * xStep;',
@@ -322,7 +549,7 @@
     gl.bindBuffer(gl.ARRAY_BUFFER, instanceBuffer);
     gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([ 0, 1, 2 ]), bufferUsage);
 
-    const program = wtu.setupProgram(gl, ['vshaderSimple', 'fshader'], ['vPosition, vInstanceID'], [0, 1]);
+    const program = wtu.setupProgram(gl, ['vshaderSimple', 'fshader'], ['vPosition, vInstanceID'], [0, 1], true);
     expectTrue(program != null, "can compile simple program");
 
     function setupInstanced() {
@@ -490,38 +717,27 @@
   }
 
   function runShaderTests(bufferUsage) {
-    const illegalBaseInstanceProgram = wtu.setupProgram(gl, ["vshaderIllegalBaseInstance", "fshader"]);
-    expectTrue(illegalBaseInstanceProgram == null, "cannot compile program with gl_BaseInstance but no extension directive");
-    const illegalBaseVertexProgram = wtu.setupProgram(gl, ["vshaderIllegalBaseVertex", "fshader"]);
-    expectTrue(illegalBaseVertexProgram == null, "cannot compile program with gl_BaseVertex but no extension directive");
+    let badProgram;
+
+    badProgram = wtu.setupProgram(gl, ["vshaderBaseInstanceWithoutExt", "fshader"]);
+    expectTrue(!badProgram, "cannot compile program with gl_BaseInstance but no extension directive");
+    badProgram = wtu.setupProgram(gl, ["vshaderBaseVertexWithoutExt", "fshader"]);
+    expectTrue(!badProgram, "cannot compile program with gl_BaseVertex but no extension directive");
+
+    badProgram = wtu.setupProgram(gl, ["vshaderWithExt", "fshader"]);
+    expectTrue(!badProgram, "cannot compile program with #extension GL_ANGLE_base_vertex_base_instance");
 
     const x = Math.floor(width * 0.4);
     const y = Math.floor(height * 0.4);
     const xSize = Math.floor(width * 0.2);
     const ySize = Math.floor(height * 0.2);
 
-    // gl_BaseInstance and gl_InstanceID
+    // gl_InstanceID
     gl.bindBuffer(gl.ARRAY_BUFFER, gl.createBuffer());
     gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([ 0,0, 1,0, 0.5,1, 0,1, 0.5,0, 1,1 ]), bufferUsage);
     gl.enableVertexAttribArray(0);
     gl.vertexAttribPointer(0, 2, gl.FLOAT, false, 0, 0);
 
-    const baseInstanceZeroProgram = wtu.setupProgram(gl, ["vshaderBaseInstanceZero", "fshader"], ["vPosition"], [0]);
-    expectTrue(baseInstanceZeroProgram !== null, "can compile program with gl_BaseInstance");
-    gl.useProgram(baseInstanceZeroProgram);
-
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    if (!multiDraw) {
-      ext.drawArraysInstancedBaseInstanceWEBGL(gl.TRIANGLES, 0, 6, 1, 5);
-    } else {
-      ext.multiDrawArraysInstancedBaseInstanceWEBGL(gl.TRIANGLES, [0], 0, [6], 0, [1], 0, [5], 0, 1);
-    }
-
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    gl.drawArrays(gl.TRIANGLES, 0, 6);
-
-    wtu.checkCanvasRect(gl, x, y, xSize, ySize, [0, 255, 0, 255], "gl_BaseInstance is 0 for non-BaseInstance draw calls");
-
     const instanceIDProgram = wtu.setupProgram(gl, ["vshaderInstanceIDCheck", "fshader"], ["vPosition"], [0]);
     expectTrue(instanceIDProgram !== null, "can compile program with gl_InstanceID");
     gl.useProgram(instanceIDProgram);
@@ -535,7 +751,7 @@
 
     wtu.checkCanvasRect(gl, x, y, xSize, ySize, [0, 255, 0, 255], "gl_InstanceID should always starts from 0");
 
-    // gl_BaseVertex and gl_VertexID
+    // gl_VertexID
     gl.bindBuffer(gl.ARRAY_BUFFER, gl.createBuffer());
     gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([ 0,0, 1,0, 0.5,1, 0,1, 0.5,0, 1,1, 0,0, 1,0, 0.5,1, 0,1 ]), bufferUsage);
     gl.bindBuffer(gl.ELEMENT_ARRAY_BUFFER, gl.createBuffer());
@@ -543,22 +759,6 @@
     gl.enableVertexAttribArray(0);
     gl.vertexAttribPointer(0, 2, gl.FLOAT, false, 0, 0);
 
-    const baseVertexZeroProgram = wtu.setupProgram(gl, ["vshaderBaseVertexZero", "fshader"], ["vPosition"], [0]);
-    expectTrue(baseVertexZeroProgram !== null, "can compile program with gl_BaseVertex");
-    gl.useProgram(baseVertexZeroProgram);
-
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    if (!multiDraw) {
-      ext.drawElementsInstancedBaseVertexBaseInstanceWEBGL(gl.TRIANGLES, 6, gl.UNSIGNED_BYTE, 0, 1, 3, 0);
-    } else {
-      ext.multiDrawElementsInstancedBaseVertexBaseInstanceWEBGL(gl.TRIANGLES, [6], 0, gl.UNSIGNED_BYTE, [0], 0, [1], 0, [3], 0, [0], 0, 1);
-    }
-
-    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
-    gl.drawElements(gl.TRIANGLES, 6, gl.UNSIGNED_BYTE, 0);
-
-    wtu.checkCanvasRect(gl, x, y, xSize, ySize, [0, 255, 0, 255], "gl_BaseVertex is 0 for non-BaseVertex draw calls");
-
     const vertexIDProgram = wtu.setupProgram(gl, ["vshaderVertexIDCheck", "fshader"], ["vPosition"], [0]);
     expectTrue(vertexIDProgram !== null, "can compile program with gl_VertexID");
     gl.useProgram(vertexIDProgram);
@@ -678,60 +878,12 @@
     });
 
     checkDraw({
-      drawFunc: multiDraw ? multiDrawArraysInstancedBaseInstance : drawArraysInstancedBaseInstance,
-      isDrawArrays: true,
-      isMultiDraw: multiDraw,
-      useBaseVertexBuiltin: true,
-      useBaseInstanceBuiltin: false
-    });
-
-    checkDraw({
-      drawFunc: multiDraw ? multiDrawArraysInstancedBaseInstance : drawArraysInstancedBaseInstance,
-      isDrawArrays: true,
-      isMultiDraw: multiDraw,
-      useBaseVertexBuiltin: false,
-      useBaseInstanceBuiltin: true
-    });
-
-    checkDraw({
-      drawFunc: multiDraw ? multiDrawArraysInstancedBaseInstance : drawArraysInstancedBaseInstance,
-      isDrawArrays: true,
-      isMultiDraw: multiDraw,
-      useBaseVertexBuiltin: true,
-      useBaseInstanceBuiltin: true
-    });
-
-    checkDraw({
       drawFunc: multiDraw ? multiDrawElementsInstancedBaseVertexBaseInstance : drawElementsInstancedBaseVertexBaseInstance,
       isDrawArrays: false,
       isMultiDraw: multiDraw,
       useBaseVertexBuiltin: false,
       useBaseInstanceBuiltin: false
     });
-
-    checkDraw({
-      drawFunc: multiDraw ? multiDrawElementsInstancedBaseVertexBaseInstance : drawElementsInstancedBaseVertexBaseInstance,
-      isDrawArrays: false,
-      isMultiDraw: multiDraw,
-      useBaseVertexBuiltin: true,
-      useBaseInstanceBuiltin: false
-    });
-
-    checkDraw({
-      drawFunc: multiDraw ? multiDrawElementsInstancedBaseVertexBaseInstance : drawElementsInstancedBaseVertexBaseInstance,
-      isDrawArrays: false,
-      isMultiDraw: multiDraw,
-      useBaseVertexBuiltin: false,
-      useBaseInstanceBuiltin: true
-    });
-
-    checkDraw({
-      drawFunc: multiDraw ? multiDrawElementsInstancedBaseVertexBaseInstance : drawElementsInstancedBaseVertexBaseInstance,
-      isDrawArrays: false,
-      isMultiDraw: multiDraw,
-      useBaseVertexBuiltin: true,
-      useBaseInstanceBuiltin: true
-    });
   }
 
   for (let i = 0; i < bufferUsageSet.length; i++) {
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/array-equality.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/array-equality.html
index a3eefd5..dcffa2c 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/array-equality.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/array-equality.html
@@ -61,6 +61,54 @@
     my_FragColor = vec4(0.0, (success ? 1.0 : 0.0), 0.0, 1.0);
 }
 </script>
+<script id="simple-float-array-fs" type="x-shader/x-fragment">#version 300 es
+precision mediump float;
+
+uniform float a[3];
+uniform float b[3];
+
+out vec4 fragColor;
+
+void main(void) {
+    fragColor = vec4(0.0, 0.0, 0.0, 1.0);
+
+    if (a == b) {
+        fragColor.g = 1.0;
+    }
+}
+</script>
+<script id="simple-vec-array-fs" type="x-shader/x-fragment">#version 300 es
+precision mediump float;
+
+uniform vec3 a[3];
+uniform vec3 b[3];
+
+out vec4 fragColor;
+
+void main(void) {
+    fragColor = vec4(0.0, 0.0, 0.0, 1.0);
+
+    if (a == b) {
+        fragColor.g = 1.0;
+    }
+}
+</script>
+<script id="simple-mat-array-fs" type="x-shader/x-fragment">#version 300 es
+precision mediump float;
+
+uniform mat3 a[3];
+uniform mat3 b[3];
+
+out vec4 fragColor;
+
+void main(void) {
+    fragColor = vec4(0.0, 0.0, 0.0, 1.0);
+
+    if (a == b) {
+        fragColor.g = 1.0;
+    }
+}
+</script>
 <script type="application/javascript">
 "use strict";
 description("Comparing arrays should work.");
@@ -77,7 +125,114 @@
   fShaderSuccess: true,
   linkSuccess: true,
   passMsg: 'Arrays of structs'
-}
+},
+{
+  fShaderId: "simple-float-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  passMsg: "Simple float array with default values",
+},
+{
+  fShaderId: "simple-float-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  renderColor: [0, 0, 0, 255],
+  uniforms: [
+    { name: 'a', functionName: 'uniform1fv', value: [1, 2, 3]},
+    { name: 'b', functionName: 'uniform1fv', value: [1, 2, 4]},
+  ],
+  passMsg: "Simple float array with different values",
+},
+{
+  fShaderId: "simple-float-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  uniforms: [
+    { name: 'a', functionName: 'uniform1fv', value: [1, 2, 3]},
+    { name: 'b', functionName: 'uniform1fv', value: [1, 2, 3]},
+  ],
+  passMsg: "Simple float array with same values",
+},
+{
+  fShaderId: "simple-vec-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  passMsg: "Simple vec array with default values",
+},
+{
+  fShaderId: "simple-vec-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  renderColor: [0, 0, 0, 255],
+  uniforms: [
+    { name: 'a', functionName: 'uniform3fv', value: [1, 2, 3, 4, 5, 6, 7, 8, 9]},
+    { name: 'b', functionName: 'uniform3fv', value: [1, 2, 3, 4, 5, 6, 7, 8, 10]},
+  ],
+  passMsg: "Simple vec array with different values",
+},
+{
+  fShaderId: "simple-vec-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  uniforms: [
+    { name: 'a', functionName: 'uniform3fv', value: [1, 2, 3, 4, 5, 6, 7, 8, 9]},
+    { name: 'b', functionName: 'uniform3fv', value: [1, 2, 3, 4, 5, 6, 7, 8, 9]},
+  ],
+  passMsg: "Simple vec array with same values",
+},
+{
+//           "simple-mat-array-fs"
+  fShaderId: "simple-mat-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  passMsg: "Simple mat array with default values",
+},
+{
+  fShaderId: "simple-mat-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  renderColor: [0, 0, 0, 255],
+  uniforms: [
+    { name: 'a', functionName: 'uniformMatrix3fv', value: [
+      11, 12, 13, 14, 15, 16, 17, 18, 19,
+      21, 22, 23, 24, 25, 26, 27, 28, 29,
+      31, 32, 33, 34, 35, 36, 37, 38, 39,
+    ]},
+    { name: 'b', functionName: 'uniformMatrix3fv', value: [
+      11, 12, 13, 14, 15, 16, 17, 18, 19,
+      21, 22, 23, 24, 25, 26, 27, 28, 29,
+      31, 32, 33, 34, 35, 36, 37, 30, 39,
+    ]},
+  ],
+  passMsg: "Simple vec array with different values",
+},
+{
+  fShaderId: "simple-mat-array-fs",
+  fShaderSuccess: true,
+  linkSuccess: true,
+  render: true,
+  uniforms: [
+    { name: 'a', functionName: 'uniformMatrix3fv', value: [
+      11, 12, 13, 14, 15, 16, 17, 18, 19,
+      21, 22, 23, 24, 25, 26, 27, 28, 29,
+      31, 32, 33, 34, 35, 36, 37, 38, 39,
+    ]},
+    { name: 'b', functionName: 'uniformMatrix3fv', value: [
+      11, 12, 13, 14, 15, 16, 17, 18, 19,
+      21, 22, 23, 24, 25, 26, 27, 28, 29,
+      31, 32, 33, 34, 35, 36, 37, 38, 39,
+    ]},
+  ],
+  passMsg: "Simple vec array with same values",
+},
 ], 2);
 </script>
 </body>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html
new file mode 100644
index 0000000..a171b94
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/fragment-shader-loop-crash.html
@@ -0,0 +1,72 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>Fragment shader containing loop should not crash</title>
+<link rel="stylesheet" href="../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"></script>
+<script src="../../js/glsl-conformance-test.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<script id="vshader" type="x-shader/x-vertex">#version 300 es
+precision highp float;
+out vec2 v_tex_coord;
+uniform mat4 matrix;
+
+void main() {
+   v_tex_coord = vec2(0.0, 0.0);
+   gl_Position = vec4(0.0, 0.0, 0.0, 0.0);
+}
+</script>
+<script id="fshader" type="x-shader/x-fragment">#version 300 es
+precision highp float;
+
+in vec2 v_tex_coord;
+out vec4 out_color;
+
+uniform sampler2D texture_1;
+uniform vec2 resolution;
+
+vec4 do_loops(vec4 z)
+{
+    vec4 v[16];
+    for (int i = 0; i < 16; i++)
+    {
+        v[i] = z;
+    }
+    return v[1];
+}
+
+void main() {
+    out_color = do_loops(vec4(0.2, 0.4, 0.6, 1.0)) - texture(texture_1, v_tex_coord);
+}
+</script>
+<script type="application/javascript">
+"use strict";
+description();
+const wtu = WebGLTestUtils;
+const tests = [
+    {
+        vShaderSource: wtu.getScript('vshader'),
+        fShaderSource: wtu.getScript('fshader'),
+        vShaderSuccess: true,
+        fShaderSuccess: true,
+        linkSuccess: true,
+        passMsg: 'Fragment shader containing a simple loop should compile and link'
+    }
+];
+
+GLSLConformanceTester.runTests(tests, 2);
+</script>
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/matrix-row-major-dynamic-indexing.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/matrix-row-major-dynamic-indexing.html
index 8cbcb99..ec6a9bb 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/matrix-row-major-dynamic-indexing.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/matrix-row-major-dynamic-indexing.html
@@ -33,6 +33,22 @@
     my_FragColor = vec4(1.0 - f, f, 0.0, 1.0);
 }
 </script>
+<script id="fshaderRowMatrixIndexedByRowMatrixInUniformBlock" type="x-shader/x-fragment">#version 300 es
+precision mediump float;
+
+uniform Stuff {
+  layout(row_major) mat4 u_mat[3];
+  layout(row_major) mat4 u_ndx[3];
+} stuff;
+
+
+out vec4 my_FragColor;
+
+void main() {
+  vec4 row = stuff.u_mat[int(stuff.u_ndx[1][1][3])][2];
+  my_FragColor = row == vec4(9, 10, 11, 12) ? vec4(0, 1, 0, 1) : vec4(1, 0, 0, 1);
+}
+</script>
 <script type="application/javascript">
 "use strict";
 description("Indexing row-major matrices within a uniform block should work");
@@ -49,6 +65,51 @@
     0, 0, 0, 0,
     0, 0, 0, 0,
   ])}],
+},
+{
+  fShaderId: 'fshaderRowMatrixIndexedByRowMatrixInUniformBlock',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: '',
+  uniformBlocks: [{name: "Stuff", value: new Float32Array([
+    // mat4 u_mat[3]
+     1,  2,  3,  4,
+     5,  6,  7,  8,
+     9, 10, 11, 12,
+    13, 14, 15, 16,
+
+         //  +-- we should be pulling out this column
+         //  |
+         //  V
+     1,  5,  9, 13,
+     2,  6, 10, 14,
+     3,  7, 11, 15,
+     4,  8, 12, 16,
+
+     2, 10, 18, 22,
+     4, 12, 20, 28,
+     6, 14, 22, 30,
+     8, 16, 24, 32,
+
+    // mat4 u_ndx[3]
+    0, 0, 0, 0,
+    0, 0, 0, 0,
+    0, 0, 0, 0,
+    0, 0, 0, 0,
+
+    0, 0, 0, 0,
+    0, 0, 0, 2,
+    0, 0, 0, 0,
+    0, 1, 0, 0,
+    // ^
+    // |
+    // +-- we should be reading this value as an index into u_mat
+
+    0, 0, 0, 0,
+    0, 0, 0, 0,
+    0, 0, 0, 0,
+    0, 0, 0, 0,
+  ])}],
 }
 ], 2);
 </script>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html
new file mode 100644
index 0000000..691523a
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/glsl3/reciprocal-sqrt-of-sum-of-squares-crash.html
@@ -0,0 +1,66 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>Shader identified as containing reciprocal square root of sum of squares should not crash</title>
+<link rel="stylesheet" href="../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"></script>
+<script src="../../js/glsl-conformance-test.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<script id="vshader" type="x-shader/x-vertex">#version 300 es
+void main() {
+   gl_Position = vec4(0.0, 0.0, 0.0, 0.0);
+}
+</script>
+<script id="fshader" type="x-shader/x-fragment">#version 300 es
+precision highp float;
+
+#define CRASH 1
+
+out vec4 fragmentColor;
+void main()
+{
+    vec2 p = gl_FragCoord.xy;
+    // This expression meets the requirement of being the reciprocal
+    // square root of a sum of squares.
+    float d = 1.0 / length(p);
+#if CRASH
+    if (p.x > 0.0)
+    {
+        d *= 2.0;
+    }
+#endif
+    fragmentColor = vec4(d);
+}
+</script>
+<script type="application/javascript">
+"use strict";
+description();
+debug('Regression test for <a href="https://crbug.com/1079309">crbug.com/1079309</a>');
+const wtu = WebGLTestUtils;
+const tests = [
+    {
+        vShaderSource: wtu.getScript('vshader'),
+        fShaderSource: wtu.getScript('fshader'),
+        vShaderSuccess: true,
+        fShaderSuccess: true,
+        linkSuccess: true,
+        passMsg: 'Shader containing expression that driver recognizes as reciprocal square root of sum of squares should compile and link'
+    }
+];
+
+GLSLConformanceTester.runTests(tests, 2);
+</script>
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/misc/blend-integer.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/misc/blend-integer.html
new file mode 100644
index 0000000..40ccfd0
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/misc/blend-integer.html
@@ -0,0 +1,176 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL 2 Blend Integer Conformance Tests</title>
+<link rel="stylesheet" href="../../resources/js-test-style.css" />
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<script id="outputVertexShader" type="x-shader/x-vertex">
+#version 300 es
+in vec4 vPosition;
+void main()
+{
+  gl_Position = vPosition;
+}
+</script>
+<script id="outputFragmentShaderSigned" type="x-shader/x-fragment">
+#version 300 es
+layout(location = 1) out highp vec4 o_drawBuffer1;
+layout(location = 2) out highp ivec4 o_drawBuffer2;
+layout(location = 3) out highp vec4 o_drawBuffer3;
+void main(void)
+{
+  o_drawBuffer1 = vec4(0, 0, 0, 0);
+  o_drawBuffer2 = ivec4(0, 0, 0, 0);
+  o_drawBuffer3 = vec4(0, 0, 0, 0);
+}
+</script>
+<script id="outputFragmentShaderUnsigned" type="x-shader/x-fragment">
+  #version 300 es
+  layout(location = 1) out highp vec4 o_drawBuffer1;
+  layout(location = 2) out highp uvec4 o_drawBuffer2;
+  layout(location = 3) out highp vec4 o_drawBuffer3;
+  void main(void)
+  {
+    o_drawBuffer1 = vec4(0, 0, 0, 0);
+    o_drawBuffer2 = uvec4(0, 0, 0, 0);
+    o_drawBuffer3 = vec4(0, 0, 0, 0);
+  }
+  </script>
+
+<script>
+"use strict";
+description("This test verifies correct behavior of min/max blending operations on integer attachments.");
+
+debug("");
+
+const wtu = WebGLTestUtils;
+const gl = wtu.create3DContext(null, undefined, 2);
+
+if (!gl) {
+  testFailed("WebGL context does not exist");
+} else {
+  testPassed("WebGL context exists");
+
+  debug("")
+  debug("GL_MIN");
+  runTest(false, gl.MIN);
+  runTest(true, gl.MIN);
+
+  debug("")
+  debug("GL_MAX");
+  runTest(false, gl.MAX);
+  runTest(true, gl.MAX);
+}
+
+function compareValue(value, attachment, isSigned) {
+  const pixel = isSigned ? new Int32Array(4) : new Uint32Array(4);
+  gl.readBuffer(attachment);
+  gl.readPixels(0, 0, 1, 1, gl.RGBA_INTEGER, isSigned ? gl.INT : gl.UNSIGNED_INT, pixel);
+  let pass = true;
+  for (let i = 0; i < 4; i++) {
+    if (value[i] != pixel[i]) {
+      testFailed(`Read value of channel ${i} should be ${pixel[i]}, was ${value[i]}.`);
+      pass = false;
+    }
+  }
+  return pass;
+}
+
+function runTest(isSigned, operation) {
+  gl.viewport(0, 0, 1, 1);
+  gl.disable(gl.BLEND);
+
+  const program = wtu.setupProgram(gl,
+    ["outputVertexShader",
+      isSigned ? "outputFragmentShaderSigned" : "outputFragmentShaderUnsigned"],
+    ['vPosition'], [0]);
+  const quadParameters = wtu.setupUnitQuad(gl, 0, 1);
+
+  // Setup render targets
+  const fb = gl.createFramebuffer();
+  gl.bindFramebuffer(gl.FRAMEBUFFER, fb);
+
+  const rb1 = gl.createRenderbuffer();
+  gl.bindRenderbuffer(gl.RENDERBUFFER, rb1);
+  gl.renderbufferStorage(gl.RENDERBUFFER, gl.RGBA8, 50, 50);
+  gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT1, gl.RENDERBUFFER, rb1);
+
+  const rb2 = gl.createRenderbuffer();
+  gl.bindRenderbuffer(gl.RENDERBUFFER, rb2);
+  gl.renderbufferStorage(gl.RENDERBUFFER, isSigned ? gl.RGBA32I : gl.RGBA32UI, 50, 50);
+  gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT2, gl.RENDERBUFFER, rb2);
+
+  const rb3 = gl.createRenderbuffer();
+  gl.bindRenderbuffer(gl.RENDERBUFFER, rb3);
+  gl.renderbufferStorage(gl.RENDERBUFFER, gl.RGBA8, 50, 50);
+  gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT3, gl.RENDERBUFFER, rb3);
+
+  gl.drawBuffers([gl.NONE, gl.COLOR_ATTACHMENT1, gl.COLOR_ATTACHMENT2, gl.COLOR_ATTACHMENT3]);
+
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR, "Pipeline setup complete.");
+
+  if (isSigned) {
+    const clearValue = new Int32Array([-1, 2, -3, 4]);
+    gl.clearBufferiv(gl.COLOR, 2, clearValue);
+    if (compareValue(clearValue, gl.COLOR_ATTACHMENT2, isSigned)) {
+      testPassed("Signed clear passed.");
+    } else {
+      testFailed("Signed clear failed.");
+    }
+  } else {
+    const clearValue = new Uint32Array([1, 2, 3, 4]);
+    gl.clearBufferuiv(gl.COLOR, 2, clearValue);
+    if (compareValue(clearValue, gl.COLOR_ATTACHMENT2, isSigned)) {
+      testPassed("Unsigned clear passed.");
+    } else {
+      testFailed("Unsigned clear failed.");
+    }
+  }
+
+  gl.blendEquation(operation);
+  gl.enable(gl.BLEND);
+
+  wtu.drawUnitQuad(gl);
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR, "Draw complete.");
+
+  if (isSigned) {
+    const drawValue = new Int32Array([0, 0, 0, 0]);
+    if (compareValue(drawValue, gl.COLOR_ATTACHMENT2, isSigned)) {
+      testPassed("Signed draw passed.");
+    } else {
+      testFailed("Signed draw failed.");
+    }
+  } else {
+    const drawValue = new Uint32Array([0, 0, 0, 0]);
+    if (compareValue(drawValue, gl.COLOR_ATTACHMENT2, isSigned)) {
+      testPassed("Unsigned draw passed.");
+    } else {
+      testFailed("Unsigned draw failed.");
+    }
+  }
+  gl.deleteRenderbuffer(rb1);
+  gl.deleteRenderbuffer(rb2);
+  gl.deleteRenderbuffer(rb3);
+  gl.deleteFramebuffer(fb);
+  gl.deleteProgram(program);
+}
+
+debug("");
+var successfullyParsed = true;
+</script>
+<script src="../../js/js-test-post.js"></script>
+
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/programs/gl-get-frag-data-location.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/programs/gl-get-frag-data-location.html
index ff66282..1e006eb 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/programs/gl-get-frag-data-location.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/programs/gl-get-frag-data-location.html
@@ -1,5 +1,5 @@
 <!--
-Copyright (c) 2019 The Khronos Group Inc.
+Copyright (c) 2021 The Khronos Group Inc.
 Use of this source code is governed by an MIT-style license that can be
 found in the LICENSE.txt file.
 -->
@@ -43,6 +43,18 @@
 }
 </script>
 
+<script id="vs-es2" type="x-shader/x-vertex">
+void main() {
+  gl_Position = vec4(0, 0, 0, 1);
+}
+</script>
+<script id="fs-es2" type="x-shader/x-fragment">
+precision mediump float;
+void main() {
+  gl_FragColor = vec4(0, 1, 0, 1);
+}
+</script>
+
 <script>
 "use strict";
 description("This test verifies getFragDataLocation behaviors.");
@@ -61,14 +73,23 @@
 }
 
 function runTests() {
-  var program = wtu.setupProgram(gl, ["vs", "fs"]);
-  var programArray = wtu.setupProgram(gl, ["vs", "fs-array"]);
-  if (!program || !programArray) {
+  window.program = wtu.setupProgram(gl, ["vs", "fs"]);
+  window.programArray = wtu.setupProgram(gl, ["vs", "fs-array"]);
+  window.programEs2 = wtu.setupProgram(gl, ["vs-es2", "fs-es2"]);
+  if (!program || !programArray || !programEs2) {
     testFailed("Set up program failed");
     return;
   }
   wtu.glErrorShouldBe(gl, gl.NO_ERROR, "No GL error from set up");
 
+  shouldBe("gl.getFragDataLocation(program, 'gl_FragColor')", "-1");
+  shouldBe("gl.getFragDataLocation(programArray, 'gl_FragColor')", "-1");
+  shouldBe("gl.getFragDataLocation(programEs2, 'gl_FragColor')", "-1");
+  shouldBe("gl.getFragDataLocation(program, 'gl_FragData')", "-1");
+  shouldBe("gl.getFragDataLocation(programArray, 'gl_FragData')", "-1");
+  shouldBe("gl.getFragDataLocation(programEs2, 'gl_FragData')", "-1");
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR, "No GL error from gl_* queries");
+
   var loc0 = gl.getFragDataLocation(program, "fragColor0");
   var loc1 = gl.getFragDataLocation(program, "fragColor1");
   if (loc0 != 2 || loc1 != 0) {
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html
new file mode 100644
index 0000000..3d2d7f5
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/rendering/blitframebuffer-unaffected-by-colormask.html
@@ -0,0 +1,102 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>BlitFramebuffer Should Be Unaffected by ColorMask</title>
+<link rel="stylesheet" href="../../resources/js-test-style.css"/>
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"></script>
+</head>
+<body>
+<canvas id="canvas" width="8" height="8"></canvas>
+<div id="description"></div>
+<div id="console"></div>
+
+<script>
+"use strict";
+
+const wtu = WebGLTestUtils;
+description("This test verifies that the blitFramebuffer is unaffected by the colorMask state.");
+
+debug('Regression test for <a href="https://crbug.com/1257769">https://crbug.com/1257769</a> and <a href="https://bugs.webkit.org/show_bug.cgi?id=220129">https://bugs.webkit.org/show_bug.cgi?id=220129</a>');
+
+function allocateTexture(gl, size) {
+    const tex = gl.createTexture();
+    gl.bindTexture(gl.TEXTURE_2D, tex);
+    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA8, size, size, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
+    return tex;
+}
+
+function allocateFBO(gl, tex) {
+    const fbo = gl.createFramebuffer();
+    gl.bindFramebuffer(gl.DRAW_FRAMEBUFFER, fbo);
+    gl.framebufferTexture2D(gl.DRAW_FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, tex, 0);
+    return fbo;
+}
+
+function run() {
+    const gl = wtu.create3DContext("canvas", { antialias: false }, 2);
+
+    if (!gl) {
+        testFailed("WebGL context does not exist");
+        finishTest();
+        return;
+    }
+
+    const size = 8;
+
+    testPassed("WebGL context exists");
+
+    // Allocate source and destination textures and framebuffer objects.
+    const sourceTex = allocateTexture(gl, size);
+    const sourceFBO = allocateFBO(gl, sourceTex);
+
+    const destTex = allocateTexture(gl, size);
+    const destFBO = allocateFBO(gl, destTex);
+
+    const program = wtu.setupColorQuad(gl);
+
+    gl.bindFramebuffer(gl.FRAMEBUFFER, sourceFBO);
+
+    // Clear the source framebuffer to red.
+    gl.clearColor(1, 0, 0, 1);
+    gl.colorMask(true, true, true, true);
+    gl.clear(gl.COLOR_BUFFER_BIT);
+
+    // Draw a transparent green quad.
+    gl.useProgram(program);
+    wtu.drawFloatColorQuad(gl, [ 0, 255, 0, 0 ]);
+
+    // Clear the alpha channel.
+    gl.colorMask(false, false, false, true);
+    gl.clearColor(0, 0, 0, 1);
+    gl.clear(gl.COLOR_BUFFER_BIT);
+
+    // At this point, even setting the colorMask to all-true won't
+    // work around the bug, since that state is latched inside ANGLE
+    // only during draws / clears.
+
+    // Blit source to dest.
+    gl.bindFramebuffer(gl.DRAW_FRAMEBUFFER, destFBO);
+    gl.blitFramebuffer(0, 0, size, size, 0, 0, size, size, gl.COLOR_BUFFER_BIT, gl.NEAREST);
+    gl.bindFramebuffer(gl.READ_FRAMEBUFFER, destFBO);
+
+    // Note that the on-screen canvas is always black - we don't blit the result to it.
+    wtu.checkCanvas(gl, [ 0, 255, 0, 255 ], "should be green", 1);
+    finishTest();
+}
+
+var successfullyParsed = true;
+
+requestAnimationFrame(run);
+
+</script>
+
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html
new file mode 100644
index 0000000..4c679df
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/rendering/draw-buffers-sparse-output-locations.html
@@ -0,0 +1,108 @@
+<!--
+Copyright (c) 2019 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Tests: Verify drawBuffers sparse output locations</title>
+<link rel="stylesheet" href="../../resources/js-test-style.css"/>
+<script src="../../js/js-test-pre.js"></script>
+<script src="../../js/webgl-test-utils.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<canvas id="canvas" width="1" height="1" style="width: 4px; height: 4px;"> </canvas>
+<div id="console"></div>
+
+<script id="vs" type="x-shader/x-vertex">#version 300 es
+void main() {
+  gl_PointSize = 100.0;
+  gl_Position = vec4(0, 0, 0, 1);
+}
+</script>
+
+<script id="fs" type="x-shader/x-fragment">#version 300 es
+// fragment shader only outputs to attachments 1 and 3
+precision highp float;
+layout(location = 1) out vec4 output1;
+layout(location = 3) out vec4 output2;
+void main()
+{
+    output1 = vec4(0.0, 1.0, 0.0, 1.0);
+    output2 = vec4(0.0, 0.0, 1.0, 1.0);
+}
+
+</script>
+<script>
+"use strict";
+description("This test verifies sparse output locations of fragment shaders render correctly");
+
+debug("");
+
+var wtu = WebGLTestUtils;
+var canvas = document.getElementById("canvas");
+var gl = wtu.create3DContext(canvas, null, 2);
+
+if (!gl) {
+  testFailed("WebGL context does not exist");
+} else {
+  testPassed("WebGL context exists");
+  runTests();
+}
+
+function testAttachment(attachment, expected) {
+  gl.readBuffer(gl.COLOR_ATTACHMENT0 + attachment);
+  wtu.checkCanvas(gl, expected, `check COLOR_ATTACHMENT${attachment}`, 1);
+}
+
+function runTests() {
+  var program = wtu.setupProgram(gl, ["vs", "fs"]);
+  if (!program) {
+    testFailed("Set up program failed");
+    return;
+  }
+  gl.useProgram(program);
+
+  // create a framebuffer with 4 1x1 pixel color attachments
+  const fb = gl.createFramebuffer();
+  gl.bindFramebuffer(gl.FRAMEBUFFER, fb);
+
+  for (let i = 0; i < 4; ++i) {
+    const tex = gl.createTexture();
+    gl.bindTexture(gl.TEXTURE_2D, tex);
+    gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA8, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);
+    gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + i, gl.TEXTURE_2D, tex, 0);
+  }
+
+  // draw only to the 1st and 3rd attachments
+  gl.drawBuffers([
+    gl.NONE,
+    gl.COLOR_ATTACHMENT1,
+    gl.NONE,
+    gl.COLOR_ATTACHMENT3,
+  ]);
+
+  // draw
+  gl.drawArrays(gl.POINTS, 0, 1);
+
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR, "No GL error from set up");
+
+  // check we got the correct values
+  testAttachment(0, [0, 0, 0, 0]);
+  testAttachment(1, [0, 255, 0, 255]);
+  testAttachment(2, [0, 0, 0, 0]);
+  testAttachment(3, [0, 0, 255, 255]);
+
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR, "No GL error from testing");
+}
+
+var successfullyParsed = true;
+</script>
+<script src="../../js/js-test-post.js"></script>
+
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/state/gl-object-get-calls.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/state/gl-object-get-calls.html
index ef77593..62ed70d 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/state/gl-object-get-calls.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/state/gl-object-get-calls.html
@@ -15,12 +15,9 @@
 <body>
 <div id="description"></div>
 <div id="console"></div>
-
 <script>
 var contextVersion = 2;
 </script>
 <script src="../../js/tests/gl-object-get-calls.js"></script>
-
-<script src="../../js/js-test-post.js"></script>
 </body>
 </html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/conformance2/textures/misc/tex-storage-compressed-formats.html b/LayoutTests/webgl/resources/webgl_test_files/conformance2/textures/misc/tex-storage-compressed-formats.html
index ada77ca..e154631 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/conformance2/textures/misc/tex-storage-compressed-formats.html
+++ b/LayoutTests/webgl/resources/webgl_test_files/conformance2/textures/misc/tex-storage-compressed-formats.html
@@ -98,7 +98,7 @@
         // Test a 2D texture.
         var tex = gl.createTexture();
         gl.bindTexture(gl.TEXTURE_2D, tex);
-        gl.texStorage2D(gl.TEXTURE_2D, 1, internalformat, 1, 1);
+        gl.texStorage2D(gl.TEXTURE_2D, 1, internalformat, 4, 4);
         wtu.glErrorShouldBe(gl, gl.NO_ERROR,
                             "texStorage2D should succeed for " + enumToString(internalformat));
         gl.deleteTexture(tex);
@@ -111,14 +111,14 @@
         // Test the 3D texture targets.
         var tex3d = gl.createTexture();
         gl.bindTexture(gl.TEXTURE_3D, tex3d);
-        gl.texStorage3D(gl.TEXTURE_3D, 1, internalformat, 1, 1, 1);
+        gl.texStorage3D(gl.TEXTURE_3D, 1, internalformat, 4, 4, 1);
         wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION,
                             "texStorage3D(TEXTURE_3D) should fail for " + enumToString(internalformat));
         gl.deleteTexture(tex3d);
 
         var tex2dArr = gl.createTexture();
         gl.bindTexture(gl.TEXTURE_2D_ARRAY, tex2dArr);
-        gl.texStorage3D(gl.TEXTURE_2D_ARRAY, 1, internalformat, 1, 1, 1);
+        gl.texStorage3D(gl.TEXTURE_2D_ARRAY, 1, internalformat, 4, 4, 1);
         wtu.glErrorShouldBe(gl, gl.NO_ERROR,
                             "texStorage3D(TEXTURE_2D_ARRAY) should succeed for " + enumToString(internalformat));
         wtu.clearAndDrawUnitQuad(gl);
diff --git a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/es3fMultisampleTests.js b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/es3fMultisampleTests.js
index 50e2a21..47e6267 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/es3fMultisampleTests.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/es3fMultisampleTests.js
@@ -1713,7 +1713,7 @@
      * Run test
      * @param {WebGL2RenderingContext} context
      */
-     es3fMultisampleTests.run = function(context) {
+    es3fMultisampleTests.run = function(context, range) {
         gl = context;
         //Set up Test Root parameters
         var testName = 'multisample';
@@ -1730,6 +1730,8 @@
         try {
             //Create test cases
             es3fMultisampleTests.init();
+            if (range)
+                state.setRange(range);
             //Run test cases
             tcuTestCase.runTestCases();
         }
diff --git a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/es3fPrimitiveRestartTests.js b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/es3fPrimitiveRestartTests.js
index 85973665..ac0da2f 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/es3fPrimitiveRestartTests.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/es3fPrimitiveRestartTests.js
@@ -334,10 +334,15 @@
             '\n' +
             'void main()\n' +
             ' {\n' +
-            ' gl_Position = a_position;\n' +
-            '}\n';
+            ' gl_Position = a_position;\n';
 
-            /** @type {string} */ var fragShaderSource =
+        if (this.m_primType == es3fPrimitiveRestartTests.PrimitiveType.PRIMITIVE_POINTS) {
+            vertShaderSource += ' gl_PointSize = 1.0;\n';
+        }
+
+        vertShaderSource += '}\n';
+
+        /** @type {string} */ var fragShaderSource =
             '#version 300 es\n' +
             'layout(location = 0) out mediump vec4 o_color;\n' +
             '\n' +
diff --git a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample.html b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample.html
deleted file mode 100644
index f02db30..0000000
--- a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample.html
+++ /dev/null
@@ -1,24 +0,0 @@
-<html>
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>WebGL Multisample Conformance Tests</title>
-<link rel="stylesheet" href="../../../resources/js-test-style.css"/>
-<script src="../../../js/js-test-pre.js"></script>
-<script src="../../../js/webgl-test-utils.js"></script>
-
-<script src="../../../closure-library/closure/goog/base.js"></script>
-<script src="../../deqp-deps.js"></script>
-<script>goog.require('functional.gles3.es3fMultisampleTests');</script>
-</head>
-<body>
-<div id="description"></div>
-<div id="console"></div>
-<canvas id="canvas" width="256" height="256"> </canvas>
-<script>
-var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext('canvas', null, 2);
-
-functional.gles3.es3fMultisampleTests.run(gl);
-</script>
-</body>
-</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html
new file mode 100644
index 0000000..71d3f06
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/default_fbo.html
@@ -0,0 +1,31 @@
+<!--
+
+This file is auto-generated from multisample_test_generator.py
+DO NOT EDIT!
+
+-->
+
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+<title>WebGL Multisample Conformance Tests</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css"/>
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+
+<script src="../../../../closure-library/closure/goog/base.js"></script>
+<script src="../../../deqp-deps.js"></script>
+<script>goog.require('functional.gles3.es3fMultisampleTests');</script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<canvas id="canvas" width="256" height="256"> </canvas>
+<script>
+var wtu = WebGLTestUtils;
+var gl = wtu.create3DContext('canvas', null, 2);
+
+functional.gles3.es3fMultisampleTests.run(gl, [0, 1]);
+</script>
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html
new file mode 100644
index 0000000..c021f57
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_4_samples.html
@@ -0,0 +1,31 @@
+<!--
+
+This file is auto-generated from multisample_test_generator.py
+DO NOT EDIT!
+
+-->
+
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+<title>WebGL Multisample Conformance Tests</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css"/>
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+
+<script src="../../../../closure-library/closure/goog/base.js"></script>
+<script src="../../../deqp-deps.js"></script>
+<script>goog.require('functional.gles3.es3fMultisampleTests');</script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<canvas id="canvas" width="256" height="256"> </canvas>
+<script>
+var wtu = WebGLTestUtils;
+var gl = wtu.create3DContext('canvas', null, 2);
+
+functional.gles3.es3fMultisampleTests.run(gl, [1, 2]);
+</script>
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html
new file mode 100644
index 0000000..adca5ae
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_8_samples.html
@@ -0,0 +1,31 @@
+<!--
+
+This file is auto-generated from multisample_test_generator.py
+DO NOT EDIT!
+
+-->
+
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+<title>WebGL Multisample Conformance Tests</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css"/>
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+
+<script src="../../../../closure-library/closure/goog/base.js"></script>
+<script src="../../../deqp-deps.js"></script>
+<script>goog.require('functional.gles3.es3fMultisampleTests');</script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<canvas id="canvas" width="256" height="256"> </canvas>
+<script>
+var wtu = WebGLTestUtils;
+var gl = wtu.create3DContext('canvas', null, 2);
+
+functional.gles3.es3fMultisampleTests.run(gl, [2, 3]);
+</script>
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html
new file mode 100644
index 0000000..32c75c7
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/deqp/functional/gles3/multisample/fbo_max_samples.html
@@ -0,0 +1,31 @@
+<!--
+
+This file is auto-generated from multisample_test_generator.py
+DO NOT EDIT!
+
+-->
+
+<html>
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
+<title>WebGL Multisample Conformance Tests</title>
+<link rel="stylesheet" href="../../../../resources/js-test-style.css"/>
+<script src="../../../../js/js-test-pre.js"></script>
+<script src="../../../../js/webgl-test-utils.js"></script>
+
+<script src="../../../../closure-library/closure/goog/base.js"></script>
+<script src="../../../deqp-deps.js"></script>
+<script>goog.require('functional.gles3.es3fMultisampleTests');</script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<canvas id="canvas" width="256" height="256"> </canvas>
+<script>
+var wtu = WebGLTestUtils;
+var gl = wtu.create3DContext('canvas', null, 2);
+
+functional.gles3.es3fMultisampleTests.run(gl, [3, 4]);
+</script>
+</body>
+</html>
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/glsl-conformance-test.js b/LayoutTests/webgl/resources/webgl_test_files/js/glsl-conformance-test.js
index ed6eaad..12a056c 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/glsl-conformance-test.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/glsl-conformance-test.js
@@ -277,12 +277,17 @@
 
   if (info.uniforms !== undefined) {
     for (var i = 0; i < info.uniforms.length; ++i) {
-      var uniformLocation = gl.getUniformLocation(program, info.uniforms[i].name);
+      var uniform = info.uniforms[i];
+      var uniformLocation = gl.getUniformLocation(program, uniform.name);
       if (uniformLocation !== null) {
-        gl[info.uniforms[i].functionName](uniformLocation, info.uniforms[i].value);
-        debug(info.uniforms[i].name + ' set to ' + info.uniforms[i].value);
+        if (uniform.functionName.includes("Matrix")) {
+          gl[uniform.functionName](uniformLocation, false, uniform.value);
+        } else {
+          gl[uniform.functionName](uniformLocation, uniform.value);
+        }
+        debug(uniform.name + ' set to ' + uniform.value);
       } else {
-        debug('uniform ' + info.uniforms[i].name + ' had null location and was not set');
+        debug('uniform ' + uniform.name + ' had null location and was not set');
       }
     }
   }
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/js-test-post.js b/LayoutTests/webgl/resources/webgl_test_files/js/js-test-post.js
index ff89e58..23df550 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/js-test-post.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/js-test-post.js
@@ -9,4 +9,19 @@
 if (_jsTestPreVerboseLogging) {
     _bufferedLogToConsole('TEST COMPLETE');
 }
+
+{
+    const e_results = document.createElement('div');
+    let fails_class = 'pass';
+    if (RESULTS.fail) {
+        fails_class = 'fail';
+    }
+    e_results.classList.add('pass');
+    e_results.innerHTML = `<p>TEST COMPLETE: ${RESULTS.pass} PASS, ` +
+      `<span class="${fails_class}">${RESULTS.fail} FAIL</span></p>`;
+
+    const e_desc = document.getElementById("description");
+    e_desc.appendChild(e_results);
+}
+
 notifyFinishedToHarness()
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/js-test-pre.js b/LayoutTests/webgl/resources/webgl_test_files/js/js-test-pre.js
index a0da348..e1cb9f7 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/js-test-pre.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/js-test-pre.js
@@ -88,7 +88,17 @@
   }
 }
 
+const RESULTS = {
+  pass: 0,
+  fail: 0,
+};
+
 function reportTestResultsToHarness(success, msg) {
+  if (success) {
+    RESULTS.pass += 1;
+  } else {
+    RESULTS.fail += 1;
+  }
   if (window.parent.webglTestHarness) {
     window.parent.webglTestHarness.reportResults(window.location.pathname, success, msg);
   }
@@ -101,6 +111,11 @@
 }
 
 function notifyFinishedToHarness() {
+  if (window._didNotifyFinishedToHarness) {
+    testFailed("Duplicate notifyFinishedToHarness()");
+  }
+  window._didNotifyFinishedToHarness = true;
+
   if (window.parent.webglTestHarness) {
     window.parent.webglTestHarness.notifyFinished(window.location.pathname);
   }
@@ -771,3 +786,16 @@
   document.body.appendChild(epilogue);
 }
 
+/// Prefer `call(() => { ... })` to `(() => { ... })()`\
+/// This way, it's clear up-front that we're calling not just defining.
+function call(fn) {
+    return fn();
+}
+
+/// `for (const i of range(3))` => 0, 1, 2
+/// Don't use `for...in range(n)`, it will not work.
+function* range(n) {
+  for (let i = 0; i < n; i++) {
+    yield i;
+  }
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/tests/compressed-texture-utils.js b/LayoutTests/webgl/resources/webgl_test_files/js/tests/compressed-texture-utils.js
index d6f02c4..46d155f 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/tests/compressed-texture-utils.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/tests/compressed-texture-utils.js
@@ -165,7 +165,7 @@
  * @param {number} height Height of the image in pixels.
  * @param {Object} subImageConfigs configs for compressedTexSubImage calls
  */
-let testTexSubImageDimensions = function(gl, validFormats, expectedByteLength, getBlockDimensions, width, height, subImageConfigs) {
+let testTexSubImageDimensions = function(gl, ext, validFormats, expectedByteLength, getBlockDimensions, width, height, subImageConfigs) {
     let tex = gl.createTexture();
     gl.bindTexture(gl.TEXTURE_2D, tex);
 
@@ -173,6 +173,7 @@
         if (validFormats.hasOwnProperty(formatId)) {
             let format = validFormats[formatId];
             let blockSize = getBlockDimensions(format);
+            debug("testing " + ctu.formatToString(ext, format));
             let expectedSize = expectedByteLength(width, height, format);
             let data = new Uint8Array(expectedSize);
 
@@ -192,7 +193,7 @@
     gl.deleteTexture(tex);
 };
 
-let testTexImageLevelDimensions = function(gl, validFormats, expectedByteLength, getBlockDimensions, imageConfigs) {
+let testTexImageLevelDimensions = function(gl, ext, validFormats, expectedByteLength, getBlockDimensions, imageConfigs) {
     let tex = gl.createTexture();
     gl.bindTexture(gl.TEXTURE_2D, tex);
 
@@ -200,6 +201,7 @@
         if (validFormats.hasOwnProperty(formatId)) {
             let format = validFormats[formatId];
             let blockSize = getBlockDimensions(format);
+            debug("testing " + ctu.formatToString(ext, format));
 
             for (let i = 0, len = imageConfigs.length; i < len; ++i) {
                 let c = imageConfigs[i];
@@ -214,6 +216,32 @@
     gl.deleteTexture(tex);
 }
 
+let testTexStorageLevelDimensions = function(gl, ext, validFormats, expectedByteLength, getBlockDimensions, imageConfigs) {
+    for (let formatId in validFormats) {
+        let tex = gl.createTexture();
+        gl.bindTexture(gl.TEXTURE_2D, tex);
+
+        if (validFormats.hasOwnProperty(formatId)) {
+            let format = validFormats[formatId];
+            let blockSize = getBlockDimensions(format);
+            debug("testing " + ctu.formatToString(ext, format));
+
+            for (let i = 0, len = imageConfigs.length; i < len; ++i) {
+                let c = imageConfigs[i];
+                let data = new Uint8Array(expectedByteLength(c.width, c.height, format));
+                if (i == 0) {
+                    gl.texStorage2D(gl.TEXTURE_2D, imageConfigs.length, format, c.width, c.height);
+                    wtu.glErrorShouldBe(gl, c.expectation, c.message);
+                }
+                gl.compressedTexSubImage2D(gl.TEXTURE_2D, i, 0, 0, c.width, c.height, format, data);
+                wtu.glErrorShouldBe(gl, c.expectation, c.message);
+            }
+        }
+        gl.bindTexture(gl.TEXTURE_2D, null);
+        gl.deleteTexture(tex);
+    }
+}
+
 return {
     formatToString: formatToString,
     insertCaptionedImg: insertCaptionedImg,
@@ -224,6 +252,7 @@
     testFormatRestrictionsOnBufferSize: testFormatRestrictionsOnBufferSize,
     testTexSubImageDimensions: testTexSubImageDimensions,
     testTexImageLevelDimensions: testTexImageLevelDimensions,
+    testTexStorageLevelDimensions: testTexStorageLevelDimensions,
 };
 
 })();
\ No newline at end of file
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/tests/context-methods.js b/LayoutTests/webgl/resources/webgl_test_files/js/tests/context-methods.js
new file mode 100644
index 0000000..f647646
--- /dev/null
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/tests/context-methods.js
@@ -0,0 +1,52 @@
+"use strict";
+
+// Properties to be ignored because they were added in versions of the
+// spec that are backward-compatible with this version
+const IGNORED_METHODS = [
+  // There is no official spec for the commit API yet, the proposal link is:
+  // https://wiki.whatwg.org/wiki/OffscreenCanvas
+  "commit",
+
+  // For WebXR integration:
+  "makeXRCompatible",
+];
+
+function assertFunction(v, f) {
+  try {
+    if (typeof v[f] != "function") {
+      testFailed(`Property either does not exist or is not a function: ${f}`);
+      return false;
+    } else {
+      return true;
+    }
+  } catch(e) {
+    testFailed(`Trying to access the property '${f}' threw an error: ${e.toString()}`);
+  }
+}
+
+function testContextMethods(gl, requiredContextMethods) {
+  const acceptableMethods = [].concat(requiredContextMethods, IGNORED_METHODS);
+
+  let passed = true;
+  requiredContextMethods.forEach(method => {
+    const r = assertFunction(gl, method);
+    passed = passed && r;
+  });
+  if (passed) {
+    testPassed("All WebGL methods found.");
+  }
+  let extended = false;
+  for (let propertyName of Object.getOwnPropertyNames(gl)) {
+    if (typeof gl[propertyName] == "function" && !acceptableMethods.includes(propertyName)) {
+      if (!extended) {
+        extended = true;
+        testFailed("Also found the following extra methods:");
+      }
+      testFailed(propertyName);
+    }
+  }
+
+  if (!extended) {
+    testPassed("No extra methods found on WebGL context.");
+  }
+}
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/tests/ext-color-buffer-half-float.js b/LayoutTests/webgl/resources/webgl_test_files/js/tests/ext-color-buffer-half-float.js
index 93de8b6..51509e8 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/tests/ext-color-buffer-half-float.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/tests/ext-color-buffer-half-float.js
@@ -244,7 +244,7 @@
     debug("testing the internal format query");
 
     var maxSamples = gl.getParameter(gl.MAX_SAMPLES);
-    var formats = new Array(gl.RGBA16F, gl.R16F, gl.RG16F);
+    const formats = [gl.RGBA16F, gl.R16F, gl.RG16F];
     var firstMultiOnlyFormat = 4;
     for (var fmt = 0; fmt < formats.length; ++fmt) {
         var samples = gl.getInternalformatParameter(gl.RENDERBUFFER, formats[fmt], gl.SAMPLES);
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/tests/gl-object-get-calls.js b/LayoutTests/webgl/resources/webgl_test_files/js/tests/gl-object-get-calls.js
index 28dc305..bd97434 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/tests/gl-object-get-calls.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/tests/gl-object-get-calls.js
@@ -9,26 +9,32 @@
 // on -- 1 for WebGL 1.0, 2 for WebGL 2.0, etc.
 
 "use strict";
-var wtu = WebGLTestUtils;
+const wtu = WebGLTestUtils;
 description("Test of get calls against GL objects like getBufferParameter, etc.");
 
-var gl = wtu.create3DContext(undefined, undefined, contextVersion);
+let gl = wtu.create3DContext(undefined, undefined, contextVersion);
 
-function testInvalidArgument(funcName, argumentName, validArgumentArray, func) {
-  var validArguments = {};
-  for (var ii = 0; ii < validArgumentArray.length; ++ii) {
+async function testInvalidArgument(funcName, argumentName, validArgumentArray, func) {
+  let validArguments = {};
+  for (let ii = 0; ii < validArgumentArray.length; ++ii) {
     validArguments[validArgumentArray[ii]] = true;
   }
-  var success = true;
-  for (var ii = 0; ii < 0x10000; ++ii) {
+  let success = true;
+  const MAX = 0x10000;
+  const STEP = Math.ceil(MAX / 10);
+  for (let ii = 0; ii < MAX; ii += 1) {
+    if (ii && ii % STEP == 0) {
+      debug(`(${ii} of ${MAX}: ${(ii/MAX*100).toFixed(1)}%)`);
+      await wtu.dispatchPromise(); // Spin the event loop.
+    }
     if (!validArguments[ii]) {
-      var result = func(ii);
+      let result = func(ii);
       if (result !== null) {
         success = false;
         testFailed(funcName + " returned " + result + " instead of null for invalid " + argumentName + " enum: " + wtu.glEnumToString(gl, ii));
         break;
       }
-      var err = gl.getError();
+      let err = gl.getError();
       if (err != gl.INVALID_ENUM) {
         success = false;
         testFailed(funcName + " did not generate INVALID_ENUM for invalid " + argumentName + " enum: " + wtu.glEnumToString(gl, ii));
@@ -41,72 +47,58 @@
   }
 }
 
-debug("");
-debug("test getBufferParameter");
-// Test getBufferParameter
-var bufferTypes = [gl.ARRAY_BUFFER, gl.ELEMENT_ARRAY_BUFFER];
-if (contextVersion > 1) {
-  bufferTypes = bufferTypes.concat([gl.COPY_READ_BUFFER, gl.COPY_WRITE_BUFFER, gl.PIXEL_PACK_BUFFER, gl.PIXEL_UNPACK_BUFFER, gl.TRANSFORM_FEEDBACK_BUFFER, gl.UNIFORM_BUFFER]);
-}
-for (var bb = 0; bb < bufferTypes.length; ++bb) {
-  var bufferType = bufferTypes[bb];
-  var buffer = gl.createBuffer();
-  gl.bindBuffer(bufferType, buffer);
-  gl.bufferData(bufferType, 16, gl.DYNAMIC_DRAW);
-  var expression1 = "gl.getBufferParameter(" + bufferType + ", gl.BUFFER_SIZE)";
-  var expression2 = "gl.getBufferParameter(" + bufferType + ", gl.BUFFER_USAGE)";
-  shouldBe(expression1, '16');
-  shouldBe(expression2, 'gl.DYNAMIC_DRAW');
-  testInvalidArgument("getBufferParameter", "parameter", [gl.BUFFER_SIZE, gl.BUFFER_USAGE], function(bufferType) {
-    return function(parameter) {
-      return gl.getBufferParameter(bufferType, parameter);
-    };
-  }(bufferType));
-  gl.bindBuffer(bufferType, null);
-}
-testInvalidArgument(
-    "getBufferParameter",
-    "target",
-    bufferTypes,
-    function(target) {
-      return gl.getBufferParameter(target, gl.BUFFER_SIZE);
-    }
-);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-var testCases = [
-  { contextStencil: true},
-  { contextStencil: false}
-];
-
-for (var run = 0; run < testCases.length; ++run) {
+(async () => {
   debug("");
-  debug("Test getFramebufferAttachmentParameter with stencil " + testCases[run].contextStencil);
-
-  if (testCases[run].contextStencil) {
-    gl = wtu.create3DContext(null, {stencil: true}, contextVersion);
-  } else {
-    gl = wtu.create3DContext(null, {stencil: false}, contextVersion);
-  }
-
-  var texture = gl.createTexture();
-  var anotherTexture = gl.createTexture();
-  gl.bindTexture(gl.TEXTURE_2D, texture);
-  gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 2, 2, 0, gl.RGBA, gl.UNSIGNED_BYTE,
-                new Uint8Array([
-                    0, 0, 0, 255,
-                    255, 255, 255, 255,
-                    255, 255, 255, 255,
-                    0, 0, 0, 255]));
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
-  gl.bindTexture(gl.TEXTURE_2D, null);
-  var framebuffer = gl.createFramebuffer();
-  gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);
-  gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);
-  var colorAttachmentsNum = 1;
+  debug("test getBufferParameter");
+  // Test getBufferParameter
+  let bufferTypes = [gl.ARRAY_BUFFER, gl.ELEMENT_ARRAY_BUFFER];
   if (contextVersion > 1) {
-    gl.bindTexture(gl.TEXTURE_2D, anotherTexture);
+    bufferTypes = bufferTypes.concat([gl.COPY_READ_BUFFER, gl.COPY_WRITE_BUFFER, gl.PIXEL_PACK_BUFFER, gl.PIXEL_UNPACK_BUFFER, gl.TRANSFORM_FEEDBACK_BUFFER, gl.UNIFORM_BUFFER]);
+  }
+  for (let bb = 0; bb < bufferTypes.length; ++bb) {
+    let bufferType = bufferTypes[bb];
+    let buffer = gl.createBuffer();
+    gl.bindBuffer(bufferType, buffer);
+    gl.bufferData(bufferType, 16, gl.DYNAMIC_DRAW);
+    let expression1 = "gl.getBufferParameter(" + bufferType + ", gl.BUFFER_SIZE)";
+    let expression2 = "gl.getBufferParameter(" + bufferType + ", gl.BUFFER_USAGE)";
+    shouldBe(expression1, '16');
+    shouldBe(expression2, 'gl.DYNAMIC_DRAW');
+    await testInvalidArgument("getBufferParameter", "parameter", [gl.BUFFER_SIZE, gl.BUFFER_USAGE], function(bufferType) {
+      return function(parameter) {
+        return gl.getBufferParameter(bufferType, parameter);
+      };
+    }(bufferType));
+    gl.bindBuffer(bufferType, null);
+  }
+  await testInvalidArgument(
+      "getBufferParameter",
+      "target",
+      bufferTypes,
+      function(target) {
+        return gl.getBufferParameter(target, gl.BUFFER_SIZE);
+      }
+  );
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+
+  let testCases = [
+    { contextStencil: true},
+    { contextStencil: false}
+  ];
+
+  for (let run = 0; run < testCases.length; ++run) {
+    debug("");
+    debug("Test getFramebufferAttachmentParameter with stencil " + testCases[run].contextStencil);
+
+    if (testCases[run].contextStencil) {
+      gl = wtu.create3DContext(null, {stencil: true}, contextVersion);
+    } else {
+      gl = wtu.create3DContext(null, {stencil: false}, contextVersion);
+    }
+
+    window.texture = gl.createTexture();
+    window.anotherTexture = gl.createTexture();
+    gl.bindTexture(gl.TEXTURE_2D, texture);
     gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 2, 2, 0, gl.RGBA, gl.UNSIGNED_BYTE,
                   new Uint8Array([
                       0, 0, 0, 255,
@@ -116,960 +108,983 @@
     gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
     gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
     gl.bindTexture(gl.TEXTURE_2D, null);
-    colorAttachmentsNum = gl.getParameter(gl.MAX_COLOR_ATTACHMENTS);
-    gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + colorAttachmentsNum - 1, gl.TEXTURE_2D, anotherTexture, 0);
-  }
-  var renderbuffer = gl.createRenderbuffer();
-  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-  gl.bindRenderbuffer(gl.RENDERBUFFER, renderbuffer);
-  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-  if (contextVersion == 1)
-    gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_COMPONENT16, 2, 2);
-  else
-    gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH24_STENCIL8, 2, 2);
-  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-  gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.RENDERBUFFER, renderbuffer);
-  if (contextVersion > 1)
-    gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.RENDERBUFFER, renderbuffer);
-  shouldBe('gl.checkFramebufferStatus(gl.FRAMEBUFFER)', 'gl.FRAMEBUFFER_COMPLETE');
-  // The for loop tests two color attachments for WebGL 2: the first one (gl.COLOR_ATTACHMENT0)
-  // and the last one (gl.COLOR_ATTACHMENT0 + gl.MAX_COLOR_ATTACHMENTS - 1).
-  for (var ii = 0; ii < colorAttachmentsNum; ii += (colorAttachmentsNum > 1 ? colorAttachmentsNum - 1 : 1)) {
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.TEXTURE');
-    if (ii == 0)
-      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'texture');
-    else
-      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'anotherTexture');
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL)', '0');
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE)', '0');
+    window.framebuffer = gl.createFramebuffer();
+    gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);
+    gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);
+    let colorAttachmentsNum = 1;
     if (contextVersion > 1) {
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_RED_SIZE)');
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE)');
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE)');
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE)');
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
-      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER)', '0');
+      gl.bindTexture(gl.TEXTURE_2D, anotherTexture);
+      gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, 2, 2, 0, gl.RGBA, gl.UNSIGNED_BYTE,
+                    new Uint8Array([
+                        0, 0, 0, 255,
+                        255, 255, 255, 255,
+                        255, 255, 255, 255,
+                        0, 0, 0, 255]));
+      gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);
+      gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);
+      gl.bindTexture(gl.TEXTURE_2D, null);
+      colorAttachmentsNum = gl.getParameter(gl.MAX_COLOR_ATTACHMENTS);
+      gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + colorAttachmentsNum - 1, gl.TEXTURE_2D, anotherTexture, 0);
     }
-  }
-  shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.RENDERBUFFER');
-  shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'renderbuffer');
-  if (contextVersion > 1) {
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.RENDERBUFFER');
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'renderbuffer');
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.RENDERBUFFER');
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'renderbuffer');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
-    wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
-  }
-  var validParametersForFBAttachment =
-      [ gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE,
-        gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME,
-        gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL,
-        gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE
-      ];
-  if (contextVersion > 1) {
-    validParametersForFBAttachment = validParametersForFBAttachment.concat([
-        gl.FRAMEBUFFER_ATTACHMENT_RED_SIZE,
-        gl.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE,
-        gl.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE,
-        gl.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE,
-        gl.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE,
-        gl.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE,
-        gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE,
-        gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING,
-        gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER
-    ]);
-  }
-  testInvalidArgument(
-      "getFramebufferAttachmentParameter",
-      "parameter",
-      validParametersForFBAttachment,
-      function(parameter) {
-        return gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT, parameter);
-      }
-  );
-  var validTargetsForFBAttachment = [gl.FRAMEBUFFER];
-  if (contextVersion > 1) {
-    validTargetsForFBAttachment = validTargetsForFBAttachment.concat([gl.READ_FRAMEBUFFER, gl.DRAW_FRAMEBUFFER]);
-  }
-  testInvalidArgument(
-      "getFramebufferAttachmentParameter",
-      "target",
-      validTargetsForFBAttachment,
-      function(target) {
-        return gl.getFramebufferAttachmentParameter(target, gl.COLOR_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE);
-      }
-  );
-  var validAttachmentsForFBAttachment = new Array(
-      gl.COLOR_ATTACHMENT0,
-      gl.DEPTH_ATTACHMENT,
-      gl.STENCIL_ATTACHMENT,
-      gl.DEPTH_STENCIL_ATTACHMENT
-  );
-  if (contextVersion > 1) {
-    for (var ii = 1; ii < gl.getParameter(gl.MAX_COLOR_ATTACHMENTS); ++ii) {
-      validAttachmentsForFBAttachment[validAttachmentsForFBAttachment.length] = gl.COLOR_ATTACHMENT0 + ii;
-    }
-  }
-  testInvalidArgument(
-      "getFramebufferAttachmentParameter",
-      "attachment",
-      validAttachmentsForFBAttachment,
-      function(attachment) {
-        return gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, attachment, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE);
-      }
-  );
-  if (contextVersion > 1) {
-    // test default framebuffer
-    gl.bindFramebuffer(gl.FRAMEBUFFER, null);
-    shouldBe('gl.checkFramebufferStatus(gl.FRAMEBUFFER)', 'gl.FRAMEBUFFER_COMPLETE');
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.FRAMEBUFFER_DEFAULT');
-    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.FRAMEBUFFER_DEFAULT');
-    if (testCases[run].contextStencil)
-      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.FRAMEBUFFER_DEFAULT');
+    window.renderbuffer = gl.createRenderbuffer();
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+    gl.bindRenderbuffer(gl.RENDERBUFFER, renderbuffer);
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+    if (contextVersion == 1)
+      gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH_COMPONENT16, 2, 2);
     else
-      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.NONE');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_RED_SIZE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH, gl.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
-    shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
-    if (testCases[run].contextStencil) {
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE)');
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
-      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
-      wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-    } else {
-      wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE)');
-      wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
-      wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+      gl.renderbufferStorage(gl.RENDERBUFFER, gl.DEPTH24_STENCIL8, 2, 2);
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+    gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.RENDERBUFFER, renderbuffer);
+    if (contextVersion > 1)
+      gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.RENDERBUFFER, renderbuffer);
+    shouldBe('gl.checkFramebufferStatus(gl.FRAMEBUFFER)', 'gl.FRAMEBUFFER_COMPLETE');
+    // The for loop tests two color attachments for WebGL 2: the first one (gl.COLOR_ATTACHMENT0)
+    // and the last one (gl.COLOR_ATTACHMENT0 + gl.MAX_COLOR_ATTACHMENTS - 1).
+    for (let ii = 0; ii < colorAttachmentsNum; ii += (colorAttachmentsNum > 1 ? colorAttachmentsNum - 1 : 1)) {
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.TEXTURE');
+      if (ii == 0)
+        shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'texture');
+      else
+        shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'anotherTexture');
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL)', '0');
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE)', '0');
+      if (contextVersion > 1) {
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_RED_SIZE)');
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE)');
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE)');
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE)');
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+        shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0 + ' + ii + ', gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER)', '0');
+      }
     }
-    testInvalidArgument(
+    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.RENDERBUFFER');
+    shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'renderbuffer');
+    if (contextVersion > 1) {
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.RENDERBUFFER');
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'renderbuffer');
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.RENDERBUFFER');
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)', 'renderbuffer');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+      wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_STENCIL_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+    }
+    let validParametersForFBAttachment =
+        [ gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE,
+          gl.FRAMEBUFFER_ATTACHMENT_OBJECT_NAME,
+          gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL,
+          gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE
+        ];
+    if (contextVersion > 1) {
+      validParametersForFBAttachment = validParametersForFBAttachment.concat([
+          gl.FRAMEBUFFER_ATTACHMENT_RED_SIZE,
+          gl.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE,
+          gl.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE,
+          gl.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE,
+          gl.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE,
+          gl.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE,
+          gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE,
+          gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING,
+          gl.FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER
+      ]);
+    }
+    await testInvalidArgument(
         "getFramebufferAttachmentParameter",
         "parameter",
         validParametersForFBAttachment,
         function(parameter) {
-          return gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, parameter);
+          return gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT, parameter);
         }
     );
-    testInvalidArgument(
+    let validTargetsForFBAttachment = [gl.FRAMEBUFFER];
+    if (contextVersion > 1) {
+      validTargetsForFBAttachment = validTargetsForFBAttachment.concat([gl.READ_FRAMEBUFFER, gl.DRAW_FRAMEBUFFER]);
+    }
+    await testInvalidArgument(
         "getFramebufferAttachmentParameter",
         "target",
         validTargetsForFBAttachment,
         function(target) {
-          return gl.getFramebufferAttachmentParameter(target, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE);
+          return gl.getFramebufferAttachmentParameter(target, gl.COLOR_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE);
         }
     );
-    testInvalidArgument(
+    let validAttachmentsForFBAttachment = new Array(
+        gl.COLOR_ATTACHMENT0,
+        gl.DEPTH_ATTACHMENT,
+        gl.STENCIL_ATTACHMENT,
+        gl.DEPTH_STENCIL_ATTACHMENT
+    );
+    if (contextVersion > 1) {
+      for (let ii = 1; ii < gl.getParameter(gl.MAX_COLOR_ATTACHMENTS); ++ii) {
+        validAttachmentsForFBAttachment[validAttachmentsForFBAttachment.length] = gl.COLOR_ATTACHMENT0 + ii;
+      }
+    }
+    await testInvalidArgument(
         "getFramebufferAttachmentParameter",
         "attachment",
-        [ gl.BACK,
-          gl.DEPTH,
-          gl.STENCIL
-        ],
+        validAttachmentsForFBAttachment,
         function(attachment) {
           return gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, attachment, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE);
         }
     );
+    if (contextVersion > 1) {
+      // test default framebuffer
+      gl.bindFramebuffer(gl.FRAMEBUFFER, null);
+      shouldBe('gl.checkFramebufferStatus(gl.FRAMEBUFFER)', 'gl.FRAMEBUFFER_COMPLETE');
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.FRAMEBUFFER_DEFAULT');
+      shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.FRAMEBUFFER_DEFAULT');
+      if (testCases[run].contextStencil)
+        shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.FRAMEBUFFER_DEFAULT');
+      else
+        shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.NONE');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_RED_SIZE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_GREEN_SIZE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_BLUE_SIZE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH, gl.FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
+      shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+      if (testCases[run].contextStencil) {
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE)');
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
+        shouldBeNonZero('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+        wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+      } else {
+        wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE)');
+        wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE)');
+        wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.STENCIL, gl.FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING)');
+      }
+      await testInvalidArgument(
+          "getFramebufferAttachmentParameter",
+          "parameter",
+          validParametersForFBAttachment,
+          function(parameter) {
+            return gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.BACK, parameter);
+          }
+      );
+      await testInvalidArgument(
+          "getFramebufferAttachmentParameter",
+          "target",
+          validTargetsForFBAttachment,
+          function(target) {
+            return gl.getFramebufferAttachmentParameter(target, gl.BACK, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE);
+          }
+      );
+      await testInvalidArgument(
+          "getFramebufferAttachmentParameter",
+          "attachment",
+          [ gl.BACK,
+            gl.DEPTH,
+            gl.STENCIL
+          ],
+          function(attachment) {
+            return gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, attachment, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE);
+          }
+      );
+    }
   }
-}
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("");
-debug("test getAttachedShaders");
-var standardVert = wtu.loadStandardVertexShader(gl);
-var standardFrag = wtu.loadStandardFragmentShader(gl);
-var standardProgram = gl.createProgram();
-gl.attachShader(standardProgram, standardVert);
-gl.attachShader(standardProgram, standardFrag);
-gl.linkProgram(standardProgram);
-var shaders = gl.getAttachedShaders(standardProgram);
-shouldBe('shaders.length', '2');
-shouldBeTrue('shaders[0] == standardVert && shaders[1] == standardFrag || shaders[1] == standardVert && shaders[0] == standardFrag');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-shouldThrow('gl.getAttachedShaders(null)');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-shouldThrow('gl.getAttachedShaders(standardVert)');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("");
-debug("Test getProgramParameter");
-shouldBe('gl.getProgramParameter(standardProgram, gl.DELETE_STATUS)', 'false');
-shouldBe('gl.getProgramParameter(standardProgram, gl.LINK_STATUS)', 'true');
-shouldBe('typeof gl.getProgramParameter(standardProgram, gl.VALIDATE_STATUS)', '"boolean"');
-shouldBe('gl.getProgramParameter(standardProgram, gl.ATTACHED_SHADERS)', '2');
-shouldBe('gl.getProgramParameter(standardProgram, gl.ACTIVE_ATTRIBUTES)', '2');
-shouldBe('gl.getProgramParameter(standardProgram, gl.ACTIVE_UNIFORMS)', '1');
-if (contextVersion > 1) {
-  var buffer = gl.createBuffer();
-  gl.bindBuffer(gl.TRANSFORM_FEEDBACK_BUFFER, buffer);
-  gl.bufferData(gl.TRANSFORM_FEEDBACK_BUFFER, 1024, gl.DYNAMIC_DRAW);
-  var uniformBlockProgram = wtu.loadUniformBlockProgram(gl);
-  var transformFeedbackVars = ["normal", "ecPosition"];
-  gl.transformFeedbackVaryings(uniformBlockProgram, transformFeedbackVars, gl.INTERLEAVED_ATTRIBS);
-  gl.linkProgram(uniformBlockProgram);
-  shouldBe('gl.getProgramParameter(uniformBlockProgram, gl.LINK_STATUS)', 'true');
-  shouldBe('gl.getError()', 'gl.NO_ERROR');
-  shouldBe('gl.getProgramParameter(uniformBlockProgram, gl.ACTIVE_UNIFORM_BLOCKS)', '1');
-  shouldBe('gl.getProgramParameter(uniformBlockProgram, gl.TRANSFORM_FEEDBACK_VARYINGS)', '2');
-  shouldBe('gl.getProgramParameter(uniformBlockProgram, gl.TRANSFORM_FEEDBACK_BUFFER_MODE)', 'gl.INTERLEAVED_ATTRIBS');
-}
-var program = standardProgram;
-var validArrayForProgramParameter = [
-    gl.DELETE_STATUS,
-    gl.LINK_STATUS,
-    gl.VALIDATE_STATUS,
-    gl.ATTACHED_SHADERS,
-    gl.ACTIVE_ATTRIBUTES,
-    gl.ACTIVE_UNIFORMS
-];
-if (contextVersion > 1) {
-  validArrayForProgramParameter = validArrayForProgramParameter.concat([
-      gl.ACTIVE_UNIFORM_BLOCKS,
-      gl.TRANSFORM_FEEDBACK_VARYINGS,
-      gl.TRANSFORM_FEEDBACK_BUFFER_MODE
-  ]);
-  program = uniformBlockProgram;
-}
-testInvalidArgument(
-    "getProgramParameter",
-    "parameter",
-    validArrayForProgramParameter,
-    function(parameter) {
-      return gl.getProgramParameter(program, parameter);
-    }
-);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("");
-debug("Test getRenderbufferParameter");
-shouldBe('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_WIDTH)', '2');
-shouldBe('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_HEIGHT)', '2');
-// Note: we can't test the actual value of the internal format since
-// the implementation is allowed to change it.
-shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_INTERNAL_FORMAT)');
-shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_DEPTH_SIZE)');
-var colorbuffer = gl.createRenderbuffer();
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-gl.bindRenderbuffer(gl.RENDERBUFFER, renderbuffer);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-gl.renderbufferStorage(gl.RENDERBUFFER, gl.RGBA4, 2, 2);
-shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_RED_SIZE)');
-shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_GREEN_SIZE)');
-shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_BLUE_SIZE)');
-shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_ALPHA_SIZE)');
-if (contextVersion > 1) {
-  gl.renderbufferStorageMultisample(gl.RENDERBUFFER, 4, gl.RGBA4, 2, 2);
-  shouldBe('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_SAMPLES)', '4');
-}
-var validArrayForRenderbuffer = new Array(
-    gl.RENDERBUFFER_WIDTH,
-    gl.RENDERBUFFER_HEIGHT,
-    gl.RENDERBUFFER_INTERNAL_FORMAT,
-    gl.RENDERBUFFER_RED_SIZE,
-    gl.RENDERBUFFER_GREEN_SIZE,
-    gl.RENDERBUFFER_BLUE_SIZE,
-    gl.RENDERBUFFER_ALPHA_SIZE,
-    gl.RENDERBUFFER_DEPTH_SIZE,
-    gl.RENDERBUFFER_STENCIL_SIZE
-);
-if (contextVersion > 1) {
-  validArrayForRenderbuffer[validArrayForRenderbuffer.length] = gl.RENDERBUFFER_SAMPLES;
-}
-testInvalidArgument(
-    "getRenderbufferParameter",
-    "parameter",
-    validArrayForRenderbuffer,
-    function(parameter) {
-      return gl.getRenderbufferParameter(gl.RENDERBUFFER, parameter);
-    });
-testInvalidArgument(
-    "getRenderbufferParameter",
-    "target",
-    [ gl.RENDERBUFFER ],
-    function(target) {
-      return gl.getRenderbufferParameter(target, gl.RENDERBUFFER_WIDTH);
-    }
-);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("");
-debug("Test getShaderParameter");
-shouldBe('gl.getShaderParameter(standardVert, gl.SHADER_TYPE)', 'gl.VERTEX_SHADER');
-shouldBe('gl.getShaderParameter(standardVert, gl.DELETE_STATUS)', 'false');
-shouldBe('gl.getShaderParameter(standardVert, gl.COMPILE_STATUS)', 'true');
-testInvalidArgument(
-    "getShaderParameter",
-    "parameter",
-    [ gl.DELETE_STATUS,
-      gl.COMPILE_STATUS,
-      gl.SHADER_TYPE
-    ],
-    function(parameter) {
-      return gl.getShaderParameter(standardVert, parameter);
-    }
-);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("");
-debug("Test getTexParameter");
-gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);
-gl.bindTexture(gl.TEXTURE_2D, texture);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER)', 'gl.NEAREST');
-shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER)', 'gl.NEAREST');
-shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S)', 'gl.CLAMP_TO_EDGE');
-shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T)', 'gl.CLAMP_TO_EDGE');
-if (contextVersion > 1) {
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_BASE_LEVEL, 0);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_COMPARE_FUNC, gl.LEQUAL);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_COMPARE_MODE, gl.COMPARE_REF_TO_TEXTURE);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAX_LEVEL, 10);
-  gl.texParameterf(gl.TEXTURE_2D, gl.TEXTURE_MAX_LOD, 10);
-  gl.texParameterf(gl.TEXTURE_2D, gl.TEXTURE_MIN_LOD, 0);
-  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_R, gl.CLAMP_TO_EDGE);
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_BASE_LEVEL)', '0');
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_COMPARE_FUNC)', 'gl.LEQUAL');
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_COMPARE_MODE)', 'gl.COMPARE_REF_TO_TEXTURE');
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MAX_LEVEL)', '10');
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MAX_LOD)', '10');
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MIN_LOD)', '0');
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_WRAP_R)', 'gl.CLAMP_TO_EDGE');
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_IMMUTABLE_FORMAT)', 'false');
-  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_IMMUTABLE_LEVELS)', '0');
-}
-var validParametersForTexture = [
-    gl.TEXTURE_MAG_FILTER,
-    gl.TEXTURE_MIN_FILTER,
-    gl.TEXTURE_WRAP_S,
-    gl.TEXTURE_WRAP_T,
-];
-if (contextVersion > 1) {
-  validParametersForTexture = validParametersForTexture.concat([
-      gl.TEXTURE_BASE_LEVEL,
-      gl.TEXTURE_COMPARE_FUNC,
-      gl.TEXTURE_COMPARE_MODE,
-      gl.TEXTURE_MAX_LEVEL,
-      gl.TEXTURE_MAX_LOD,
-      gl.TEXTURE_MIN_LOD,
-      gl.TEXTURE_WRAP_R,
-      gl.TEXTURE_IMMUTABLE_FORMAT,
-      gl.TEXTURE_IMMUTABLE_LEVELS,
-  ]);
-}
-testInvalidArgument(
-    "getTexParameter",
-    "parameter",
-    validParametersForTexture,
-    function(parameter) {
-      return gl.getTexParameter(gl.TEXTURE_2D, parameter);
-    }
-);
-var validTargetsForTexture = [ gl.TEXTURE_2D, gl.TEXTURE_CUBE_MAP];
-if (contextVersion > 1) {
-  validTargetsForTexture = validTargetsForTexture.concat([ gl.TEXTURE_3D, gl.TEXTURE_2D_ARRAY]);
-}
-testInvalidArgument(
-    "getTexParameter",
-    "target",
-    validTargetsForTexture,
-    function(target) {
-      return gl.getTexParameter(target, gl.TEXTURE_MAG_FILTER);
-    }
-);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("");
-debug("Test getUniform with all variants of data types");
-debug("Boolean uniform variables");
-var boolProgram = wtu.loadProgramFromFile(gl, "../../resources/boolUniformShader.vert", "../../resources/noopUniformShader.frag");
-shouldBe('gl.getProgramParameter(boolProgram, gl.LINK_STATUS)', 'true');
-var bvalLoc = gl.getUniformLocation(boolProgram, "bval");
-var bval2Loc = gl.getUniformLocation(boolProgram, "bval2");
-var bval3Loc = gl.getUniformLocation(boolProgram, "bval3");
-var bval4Loc = gl.getUniformLocation(boolProgram, "bval4");
-gl.useProgram(boolProgram);
-gl.uniform1i(bvalLoc, 1);
-gl.uniform2i(bval2Loc, 1, 0);
-gl.uniform3i(bval3Loc, 1, 0, 1);
-gl.uniform4i(bval4Loc, 1, 0, 1, 0);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-shouldBe('gl.getUniform(boolProgram, bvalLoc)', 'true');
-shouldBe('gl.getUniform(boolProgram, bval2Loc)', '[true, false]');
-shouldBe('gl.getUniform(boolProgram, bval3Loc)', '[true, false, true]');
-shouldBe('gl.getUniform(boolProgram, bval4Loc)', '[true, false, true, false]');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("Integer uniform variables");
-var intProgram = wtu.loadProgramFromFile(gl, "../../resources/intUniformShader.vert", "../../resources/noopUniformShader.frag");
-shouldBe('gl.getProgramParameter(intProgram, gl.LINK_STATUS)', 'true');
-var ivalLoc = gl.getUniformLocation(intProgram, "ival");
-var ival2Loc = gl.getUniformLocation(intProgram, "ival2");
-var ival3Loc = gl.getUniformLocation(intProgram, "ival3");
-var ival4Loc = gl.getUniformLocation(intProgram, "ival4");
-gl.useProgram(intProgram);
-gl.uniform1i(ivalLoc, 1);
-gl.uniform2i(ival2Loc, 2, 3);
-gl.uniform3i(ival3Loc, 4, 5, 6);
-gl.uniform4i(ival4Loc, 7, 8, 9, 10);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-shouldBe('gl.getUniform(intProgram, ivalLoc)', '1');
-shouldBe('gl.getUniform(intProgram, ival2Loc)', '[2, 3]');
-shouldBe('gl.getUniform(intProgram, ival3Loc)', '[4, 5, 6]');
-shouldBe('gl.getUniform(intProgram, ival4Loc)', '[7, 8, 9, 10]');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("Float uniform variables");
-var floatProgram = wtu.loadProgramFromFile(gl, "../../resources/floatUniformShader.vert", "../../resources/noopUniformShader.frag");
-shouldBe('gl.getProgramParameter(floatProgram, gl.LINK_STATUS)', 'true');
-var fvalLoc = gl.getUniformLocation(floatProgram, "fval");
-var fval2Loc = gl.getUniformLocation(floatProgram, "fval2");
-var fval3Loc = gl.getUniformLocation(floatProgram, "fval3");
-var fval4Loc = gl.getUniformLocation(floatProgram, "fval4");
-gl.useProgram(floatProgram);
-gl.uniform1f(fvalLoc, 11);
-gl.uniform2f(fval2Loc, 12, 13);
-gl.uniform3f(fval3Loc, 14, 15, 16);
-gl.uniform4f(fval4Loc, 17, 18, 19, 20);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-shouldBe('gl.getUniform(floatProgram, fvalLoc)', '11');
-shouldBe('gl.getUniform(floatProgram, fval2Loc)', '[12, 13]');
-shouldBe('gl.getUniform(floatProgram, fval3Loc)', '[14, 15, 16]');
-shouldBe('gl.getUniform(floatProgram, fval4Loc)', '[17, 18, 19, 20]');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("Sampler uniform variables");
-var samplerProgram = wtu.loadProgramFromFile(gl, "../../resources/noopUniformShader.vert", "../../resources/samplerUniformShader.frag");
-shouldBe('gl.getProgramParameter(samplerProgram, gl.LINK_STATUS)', 'true');
-var s2DValLoc = gl.getUniformLocation(samplerProgram, "s2D");
-var sCubeValLoc = gl.getUniformLocation(samplerProgram, "sCube");
-gl.useProgram(samplerProgram);
-gl.uniform1i(s2DValLoc, 0);
-gl.uniform1i(sCubeValLoc, 1);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-shouldBe('gl.getUniform(samplerProgram, s2DValLoc)', '0');
-shouldBe('gl.getUniform(samplerProgram, sCubeValLoc)', '1');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-debug("Matrix uniform variables");
-var matProgram = wtu.loadProgramFromFile(gl, "../../resources/matUniformShader.vert", "../../resources/noopUniformShader.frag");
-shouldBe('gl.getProgramParameter(matProgram, gl.LINK_STATUS)', 'true');
-var mval2Loc = gl.getUniformLocation(matProgram, "mval2");
-var mval3Loc = gl.getUniformLocation(matProgram, "mval3");
-var mval4Loc = gl.getUniformLocation(matProgram, "mval4");
-gl.useProgram(matProgram);
-gl.uniformMatrix2fv(mval2Loc, false, [1, 2, 3, 4]);
-gl.uniformMatrix3fv(mval3Loc, false, [5, 6, 7, 8, 9, 10, 11, 12, 13]);
-gl.uniformMatrix4fv(mval4Loc, false, [14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29]);
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-shouldBe('gl.getUniform(matProgram, mval2Loc)', '[1, 2, 3, 4]');
-shouldBe('gl.getUniform(matProgram, mval3Loc)', '[5, 6, 7, 8, 9, 10, 11, 12, 13]');
-shouldBe('gl.getUniform(matProgram, mval4Loc)', '[14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29]');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-if (contextVersion > 1) {
-  debug("Unsigned Integer uniform variables");
-  var uintProgram = wtu.loadProgramFromFile(gl, "../../resources/uintUniformShader.vert", "../../resources/noopUniformShaderES3.frag");
-  shouldBe('gl.getProgramParameter(uintProgram, gl.LINK_STATUS)', 'true');
-  var uvalLoc = gl.getUniformLocation(uintProgram, "uval");
-  var uval2Loc = gl.getUniformLocation(uintProgram, "uval2");
-  var uval3Loc = gl.getUniformLocation(uintProgram, "uval3");
-  var uval4Loc = gl.getUniformLocation(uintProgram, "uval4");
-  gl.useProgram(uintProgram);
-  gl.uniform1ui(uvalLoc, 1);
-  gl.uniform2ui(uval2Loc, 2, 3);
-  gl.uniform3ui(uval3Loc, 4, 5, 6);
-  gl.uniform4ui(uval4Loc, 7, 8, 9, 10);
-  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-  shouldBe('gl.getUniform(uintProgram, uvalLoc)', '1');
-  shouldBe('gl.getUniform(uintProgram, uval2Loc)', '[2, 3]');
-  shouldBe('gl.getUniform(uintProgram, uval3Loc)', '[4, 5, 6]');
-  shouldBe('gl.getUniform(uintProgram, uval4Loc)', '[7, 8, 9, 10]');
   wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-  debug("Matrix uniform variables for WebGL 2");
+  debug("");
+  debug("test getAttachedShaders");
+  window.standardVert = wtu.loadStandardVertexShader(gl);
+  window.standardFrag = wtu.loadStandardFragmentShader(gl);
+  window.standardProgram = gl.createProgram();
+  gl.attachShader(standardProgram, standardVert);
+  gl.attachShader(standardProgram, standardFrag);
+  gl.linkProgram(standardProgram);
+  window.shaders = gl.getAttachedShaders(standardProgram);
+  shouldBe('shaders.length', '2');
+  shouldBeTrue('shaders[0] == standardVert && shaders[1] == standardFrag || shaders[1] == standardVert && shaders[0] == standardFrag');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  shouldThrow('gl.getAttachedShaders(null)');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  shouldThrow('gl.getAttachedShaders(standardVert)');
   wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-  var matForWebGL2Program = wtu.loadProgramFromFile(gl, "../../resources/matForWebGL2UniformShader.vert", "../../resources/noopUniformShaderES3.frag");
-  shouldBe('gl.getProgramParameter(matForWebGL2Program, gl.LINK_STATUS)', 'true');
-  var mval2x3Loc = gl.getUniformLocation(matForWebGL2Program, "mval2x3");
-  var mval2x4Loc = gl.getUniformLocation(matForWebGL2Program, "mval2x4");
-  var mval3x2Loc = gl.getUniformLocation(matForWebGL2Program, "mval3x2");
-  var mval3x4Loc = gl.getUniformLocation(matForWebGL2Program, "mval3x4");
-  var mval4x2Loc = gl.getUniformLocation(matForWebGL2Program, "mval4x2");
-  var mval4x3Loc = gl.getUniformLocation(matForWebGL2Program, "mval4x3");
-  gl.useProgram(matForWebGL2Program);
-  gl.uniformMatrix2x3fv(mval2x3Loc, false, [1, 2, 3, 4, 5, 6]);
-  gl.uniformMatrix2x4fv(mval2x4Loc, false, [7, 8, 9, 10, 11, 12, 13, 14]);
-  gl.uniformMatrix3x2fv(mval3x2Loc, false, [15, 16, 17, 18, 19, 20]);
-  gl.uniformMatrix3x4fv(mval3x4Loc, false, [21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32]);
-  gl.uniformMatrix4x2fv(mval4x2Loc, false, [33, 34, 35, 36, 37, 38, 39, 40]);
-  gl.uniformMatrix4x3fv(mval4x3Loc, false, [41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52]);
-  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-  shouldBe('gl.getUniform(matForWebGL2Program, mval2x3Loc)', '[1, 2, 3, 4, 5, 6]');
-  shouldBe('gl.getUniform(matForWebGL2Program, mval2x4Loc)', '[7, 8, 9, 10, 11, 12, 13, 14]');
-  shouldBe('gl.getUniform(matForWebGL2Program, mval3x2Loc)', '[15, 16, 17, 18, 19, 20]');
-  shouldBe('gl.getUniform(matForWebGL2Program, mval3x4Loc)', '[21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32]');
-  shouldBe('gl.getUniform(matForWebGL2Program, mval4x2Loc)', '[33, 34, 35, 36, 37, 38, 39, 40]');
-  shouldBe('gl.getUniform(matForWebGL2Program, mval4x3Loc)', '[41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52]');
-  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-  debug("Sampler uniform variables for WebGL2");
-  var samplerForWebGL2Program = wtu.loadProgramFromFile(gl, "../../resources/noopUniformShaderES3.vert", "../../resources/samplerForWebGL2UniformShader.frag");
-  shouldBe('gl.getProgramParameter(samplerForWebGL2Program, gl.LINK_STATUS)', 'true');
-  var s3DValLoc = gl.getUniformLocation(samplerForWebGL2Program, "s3D");
-  var s2DArrayValLoc = gl.getUniformLocation(samplerForWebGL2Program, "s2DArray");
-  gl.useProgram(samplerForWebGL2Program);
-  gl.uniform1i(s3DValLoc, 0);
-  gl.uniform1i(s2DArrayValLoc, 1);
-  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-  shouldBe('gl.getUniform(samplerForWebGL2Program, s3DValLoc)', '0');
-  shouldBe('gl.getUniform(samplerForWebGL2Program, s2DArrayValLoc)', '1');
-  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-}
-
-debug("");
-debug("test getVertexAttrib");
-var array = new Float32Array([1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]);
-var buffer = gl.createBuffer();
-gl.bindBuffer(gl.ARRAY_BUFFER, buffer);
-gl.bufferData(gl.ARRAY_BUFFER, array, gl.DYNAMIC_DRAW);
-// Vertex attribute 0 is special in that it has no current state, so
-// fetching GL_CURRENT_VERTEX_ATTRIB generates an error. Use attribute
-// 1 for these tests instead.
-gl.enableVertexAttribArray(1);
-gl.vertexAttribPointer(1, 4, gl.FLOAT, false, 0, 0);
-shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING)', 'buffer');
-shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_ENABLED)', 'true');
-shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_SIZE)', '4');
-// Stride MUST be the value the user put in.
-shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_STRIDE)', '0');
-shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_TYPE)', 'gl.FLOAT');
-shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_NORMALIZED)', 'false');
-if (contextVersion > 1) {
-  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_DIVISOR)', '0');
-  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_INTEGER)', 'false');
-  gl.vertexAttribDivisor(1, 2);
-  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_DIVISOR)', '2');
-}
-gl.vertexAttribPointer(1, 4, gl.FLOAT, false, 36, 12);
-shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_STRIDE)', '36');
-shouldBe('gl.getVertexAttribOffset(1, gl.VERTEX_ATTRIB_ARRAY_POINTER)', '12');
-gl.disableVertexAttribArray(1);
-shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_ENABLED)', 'false');
-gl.vertexAttrib4f(1, 5, 6, 7, 8);
-shouldBe('gl.getVertexAttrib(1, gl.CURRENT_VERTEX_ATTRIB)', '[5, 6, 7, 8]');
-if (contextVersion > 1) {
-  var intArray = new Int32Array([1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]);
-  gl.bufferData(gl.ARRAY_BUFFER, intArray, gl.DYNAMIC_DRAW);
-  gl.enableVertexAttribArray(1);
-  // feed fixed-point data to buffer
-  gl.vertexAttribIPointer(1, 4, gl.INT, false, 0, 0);
-  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_TYPE)', 'gl.INT');
-  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_INTEGER)', 'true');
-}
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-var validArrayForVertexAttrib = new Array(
-    gl.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING,
-    gl.VERTEX_ATTRIB_ARRAY_ENABLED,
-    gl.VERTEX_ATTRIB_ARRAY_SIZE,
-    gl.VERTEX_ATTRIB_ARRAY_STRIDE,
-    gl.VERTEX_ATTRIB_ARRAY_TYPE,
-    gl.VERTEX_ATTRIB_ARRAY_NORMALIZED,
-    gl.CURRENT_VERTEX_ATTRIB
-);
-if (contextVersion > 1) {
-  validArrayForVertexAttrib[validArrayForVertexAttrib.length] = gl.VERTEX_ATTRIB_ARRAY_DIVISOR;
-  validArrayForVertexAttrib[validArrayForVertexAttrib.length] = gl.VERTEX_ATTRIB_ARRAY_INTEGER;
-}
-testInvalidArgument(
-    "getVertexAttrib",
-    "parameter",
-    validArrayForVertexAttrib,
-    function(parameter) {
-      return gl.getVertexAttrib(1, parameter);
-    }
-);
-var numVertexAttribs = gl.getParameter(gl.MAX_VERTEX_ATTRIBS);
-wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, 'gl.getVertexAttrib(' + numVertexAttribs + ', gl.CURRENT_VERTEX_ATTRIB)');
-
-debug("");
-debug("Test cases where name == 0");
-gl.deleteTexture(texture);
-shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.NONE');
-gl.deleteRenderbuffer(renderbuffer);
-gl.bindRenderbuffer(gl.RENDERBUFFER, renderbuffer);
-wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION);
-shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.NONE');
-gl.deleteBuffer(buffer);
-shouldBeNull('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING)');
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-if (contextVersion > 1) {
-    debug("");
-    debug("Test getInternalformatParameter")
-
-    shouldBeNonNull('gl.getInternalformatParameter(gl.RENDERBUFFER, gl.R32I, gl.SAMPLES)');
-    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
-
-    testInvalidArgument(
-        "getInternalformatParameter",
-        "target",
-        [ gl.RENDERBUFFER ],
-        function(target) {
-            return gl.getInternalformatParameter(target, gl.R32I, gl.SAMPLES);
-    });
-
-    testInvalidArgument(
-        "getInternalformatParameter",
-        "pname",
-        [ gl.SAMPLES ],
-        function(pname) {
-            return gl.getInternalformatParameter(gl.RENDERBUFFER, gl.RGBA4, pname);
-    });
-
-    var validArrayForInterformat = new Array(
-        gl.R8, gl.R8_SNORM, gl.RG8, gl.RG8_SNORM,
-        gl.RGB8, gl.RGB8_SNORM, gl.RGB565, gl.RGBA4,
-        gl.RGB5_A1, gl.RGBA8, gl.RGBA8_SNORM, gl.RGB10_A2,
-        gl.RGB10_A2UI, gl.SRGB8, gl.SRGB8_ALPHA8, gl.R16F,
-        gl.RG16F, gl.RGB16F, gl.RGBA16F, gl.R32F,
-        gl.RG32F, gl.RGB32F, gl.RGBA32F, gl.R11F_G11F_B10F,
-        gl.RGB9_E5, gl.R8I, gl.R8UI, gl.R16I,
-        gl.R16UI, gl.R32I, gl.R32UI, gl.RG8I,
-        gl.RG8UI, gl.RG16I, gl.RG16UI, gl.RG32I,
-        gl.RG32UI, gl.RGB8I, gl.RGB8UI, gl.RGB16I,
-        gl.RGB16UI, gl.RGB32I, gl.RGB32UI, gl.RGBA8I,
-        gl.RGBA8UI, gl.RGBA16I, gl.RGBA16UI, gl.RGBA32I,
-        gl.RGBA32UI, gl.RGB, gl.RGBA, gl.DEPTH_STENCIL, gl.DEPTH_COMPONENT16,
-        gl.DEPTH_COMPONENT24, gl.DEPTH_COMPONENT32F, gl.DEPTH24_STENCIL8,
-        gl.DEPTH32F_STENCIL8, gl.STENCIL_INDEX8
-    );
-    testInvalidArgument(
-        "getInternalformatParameter",
-        "internalformat",
-        validArrayForInterformat,
-        function(internalformat) {
-            return gl.getInternalformatParameter(gl.RENDERBUFFER, internalformat, gl.SAMPLES);
-    });
-
-
-    debug("");
-    debug("Test getIndexedParameter");
-    var buffer = gl.createBuffer();
+  debug("");
+  debug("Test getProgramParameter");
+  shouldBe('gl.getProgramParameter(standardProgram, gl.DELETE_STATUS)', 'false');
+  shouldBe('gl.getProgramParameter(standardProgram, gl.LINK_STATUS)', 'true');
+  shouldBe('typeof gl.getProgramParameter(standardProgram, gl.VALIDATE_STATUS)', '"boolean"');
+  shouldBe('gl.getProgramParameter(standardProgram, gl.ATTACHED_SHADERS)', '2');
+  shouldBe('gl.getProgramParameter(standardProgram, gl.ACTIVE_ATTRIBUTES)', '2');
+  shouldBe('gl.getProgramParameter(standardProgram, gl.ACTIVE_UNIFORMS)', '1');
+  if (contextVersion > 1) {
+    let buffer = gl.createBuffer();
     gl.bindBuffer(gl.TRANSFORM_FEEDBACK_BUFFER, buffer);
-    gl.bufferData(gl.TRANSFORM_FEEDBACK_BUFFER, 64, gl.DYNAMIC_DRAW);
-    gl.bindBufferRange(gl.TRANSFORM_FEEDBACK_BUFFER, 0, buffer, 4, 8);
-    shouldBe('gl.getIndexedParameter(gl.TRANSFORM_FEEDBACK_BUFFER_BINDING, 0)', 'buffer');
-    shouldBe('gl.getIndexedParameter(gl.TRANSFORM_FEEDBACK_BUFFER_SIZE, 0)', '8');
-    shouldBe('gl.getIndexedParameter(gl.TRANSFORM_FEEDBACK_BUFFER_START, 0)', '4');
-    var buffer1 = gl.createBuffer();
-    gl.bindBuffer(gl.UNIFORM_BUFFER, buffer1);
-    gl.bufferData(gl.UNIFORM_BUFFER, 64, gl.DYNAMIC_DRAW);
-    var offsetUniform = gl.getParameter(gl.UNIFORM_BUFFER_OFFSET_ALIGNMENT);
-    gl.bindBufferRange(gl.UNIFORM_BUFFER, 1, buffer1, offsetUniform, 8);
-    shouldBe('gl.getIndexedParameter(gl.UNIFORM_BUFFER_BINDING, 1)', 'buffer1');
-    shouldBe('gl.getIndexedParameter(gl.UNIFORM_BUFFER_SIZE, 1)', '8');
-    shouldBe('gl.getIndexedParameter(gl.UNIFORM_BUFFER_START, 1)', 'offsetUniform');
+    gl.bufferData(gl.TRANSFORM_FEEDBACK_BUFFER, 1024, gl.DYNAMIC_DRAW);
+    window.uniformBlockProgram = wtu.loadUniformBlockProgram(gl);
+    let transformFeedbackVars = ["normal", "ecPosition"];
+    gl.transformFeedbackVaryings(uniformBlockProgram, transformFeedbackVars, gl.INTERLEAVED_ATTRIBS);
+    gl.linkProgram(uniformBlockProgram);
+    shouldBe('gl.getProgramParameter(uniformBlockProgram, gl.LINK_STATUS)', 'true');
+    shouldBe('gl.getError()', 'gl.NO_ERROR');
+    shouldBe('gl.getProgramParameter(uniformBlockProgram, gl.ACTIVE_UNIFORM_BLOCKS)', '1');
+    shouldBe('gl.getProgramParameter(uniformBlockProgram, gl.TRANSFORM_FEEDBACK_VARYINGS)', '2');
+    shouldBe('gl.getProgramParameter(uniformBlockProgram, gl.TRANSFORM_FEEDBACK_BUFFER_MODE)', 'gl.INTERLEAVED_ATTRIBS');
+  }
+  window.program = standardProgram;
+  let validArrayForProgramParameter = [
+      gl.DELETE_STATUS,
+      gl.LINK_STATUS,
+      gl.VALIDATE_STATUS,
+      gl.ATTACHED_SHADERS,
+      gl.ACTIVE_ATTRIBUTES,
+      gl.ACTIVE_UNIFORMS
+  ];
+  if (contextVersion > 1) {
+    validArrayForProgramParameter = validArrayForProgramParameter.concat([
+        gl.ACTIVE_UNIFORM_BLOCKS,
+        gl.TRANSFORM_FEEDBACK_VARYINGS,
+        gl.TRANSFORM_FEEDBACK_BUFFER_MODE
+    ]);
+    program = uniformBlockProgram;
+  }
+  await testInvalidArgument(
+      "getProgramParameter",
+      "parameter",
+      validArrayForProgramParameter,
+      function(parameter) {
+        return gl.getProgramParameter(program, parameter);
+      }
+  );
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    gl.bindBufferBase(gl.UNIFORM_BUFFER, 1, null);
-    shouldBe('gl.getIndexedParameter(gl.UNIFORM_BUFFER_BINDING, 1)', 'null');
+  debug("");
+  debug("Test getRenderbufferParameter");
+  shouldBe('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_WIDTH)', '2');
+  shouldBe('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_HEIGHT)', '2');
+  // Note: we can't test the actual value of the internal format since
+  // the implementation is allowed to change it.
+  shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_INTERNAL_FORMAT)');
+  shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_DEPTH_SIZE)');
+  let colorbuffer = gl.createRenderbuffer();
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  gl.bindRenderbuffer(gl.RENDERBUFFER, renderbuffer);
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  gl.renderbufferStorage(gl.RENDERBUFFER, gl.RGBA4, 2, 2);
+  shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_RED_SIZE)');
+  shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_GREEN_SIZE)');
+  shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_BLUE_SIZE)');
+  shouldBeNonZero('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_ALPHA_SIZE)');
+  if (contextVersion > 1) {
+    gl.renderbufferStorageMultisample(gl.RENDERBUFFER, 4, gl.RGBA4, 2, 2);
+    shouldBe('gl.getRenderbufferParameter(gl.RENDERBUFFER, gl.RENDERBUFFER_SAMPLES)', '4');
+  }
+  let validArrayForRenderbuffer = new Array(
+      gl.RENDERBUFFER_WIDTH,
+      gl.RENDERBUFFER_HEIGHT,
+      gl.RENDERBUFFER_INTERNAL_FORMAT,
+      gl.RENDERBUFFER_RED_SIZE,
+      gl.RENDERBUFFER_GREEN_SIZE,
+      gl.RENDERBUFFER_BLUE_SIZE,
+      gl.RENDERBUFFER_ALPHA_SIZE,
+      gl.RENDERBUFFER_DEPTH_SIZE,
+      gl.RENDERBUFFER_STENCIL_SIZE
+  );
+  if (contextVersion > 1) {
+    validArrayForRenderbuffer[validArrayForRenderbuffer.length] = gl.RENDERBUFFER_SAMPLES;
+  }
+  await testInvalidArgument(
+      "getRenderbufferParameter",
+      "parameter",
+      validArrayForRenderbuffer,
+      function(parameter) {
+        return gl.getRenderbufferParameter(gl.RENDERBUFFER, parameter);
+      });
+  await testInvalidArgument(
+      "getRenderbufferParameter",
+      "target",
+      [ gl.RENDERBUFFER ],
+      function(target) {
+        return gl.getRenderbufferParameter(target, gl.RENDERBUFFER_WIDTH);
+      }
+  );
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    var validArrayForTarget = new Array(
-        gl.TRANSFORM_FEEDBACK_BUFFER_BINDING,
-        gl.TRANSFORM_FEEDBACK_BUFFER_SIZE,
-        gl.TRANSFORM_FEEDBACK_BUFFER_START,
-        gl.UNIFORM_BUFFER_BINDING,
-        gl.UNIFORM_BUFFER_SIZE,
-        gl.UNIFORM_BUFFER_START
-    );
-    testInvalidArgument(
-        "getIndexedParameter",
-        "target",
-        validArrayForTarget,
-        function(target) {
-            return gl.getIndexedParameter(target, 0);
-    });
+  debug("");
+  debug("Test getShaderParameter");
+  shouldBe('gl.getShaderParameter(standardVert, gl.SHADER_TYPE)', 'gl.VERTEX_SHADER');
+  shouldBe('gl.getShaderParameter(standardVert, gl.DELETE_STATUS)', 'false');
+  shouldBe('gl.getShaderParameter(standardVert, gl.COMPILE_STATUS)', 'true');
+  await testInvalidArgument(
+      "getShaderParameter",
+      "parameter",
+      [ gl.DELETE_STATUS,
+        gl.COMPILE_STATUS,
+        gl.SHADER_TYPE
+      ],
+      function(parameter) {
+        return gl.getShaderParameter(standardVert, parameter);
+      }
+  );
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    debug("");
-    debug("Test getSamplerParameter");
-    var sampler = gl.createSampler();
-    gl.samplerParameteri(sampler, gl.TEXTURE_COMPARE_FUNC, gl.LEQUAL);
-    gl.samplerParameteri(sampler, gl.TEXTURE_COMPARE_MODE, gl.COMPARE_REF_TO_TEXTURE);
-    gl.samplerParameteri(sampler, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
-    gl.samplerParameterf(sampler, gl.TEXTURE_MAX_LOD, 10);
-    gl.samplerParameteri(sampler, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
-    gl.samplerParameterf(sampler, gl.TEXTURE_MIN_LOD, 0);
-    gl.samplerParameteri(sampler, gl.TEXTURE_WRAP_R, gl.CLAMP_TO_EDGE);
-    gl.samplerParameteri(sampler, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
-    gl.samplerParameteri(sampler, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_COMPARE_FUNC)', 'gl.LEQUAL');
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_COMPARE_MODE)', 'gl.COMPARE_REF_TO_TEXTURE');
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_MAG_FILTER)', 'gl.NEAREST');
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_MAX_LOD)', '10');
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_MIN_FILTER)', 'gl.NEAREST');
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_MIN_LOD)', '0');
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_WRAP_R)', 'gl.CLAMP_TO_EDGE');
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_WRAP_S)', 'gl.CLAMP_TO_EDGE');
-    shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_WRAP_T)', 'gl.CLAMP_TO_EDGE');
-    var validArrayForSamplerParameter = new Array(
+  debug("");
+  debug("Test getTexParameter");
+  gl.bindTexture(gl.TEXTURE_2D, texture);
+  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
+  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
+  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
+  gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
+  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER)', 'gl.NEAREST');
+  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER)', 'gl.NEAREST');
+  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S)', 'gl.CLAMP_TO_EDGE');
+  shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T)', 'gl.CLAMP_TO_EDGE');
+  if (contextVersion > 1) {
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_BASE_LEVEL, 0);
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_COMPARE_FUNC, gl.LEQUAL);
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_COMPARE_MODE, gl.COMPARE_REF_TO_TEXTURE);
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAX_LEVEL, 10);
+    gl.texParameterf(gl.TEXTURE_2D, gl.TEXTURE_MAX_LOD, 10);
+    gl.texParameterf(gl.TEXTURE_2D, gl.TEXTURE_MIN_LOD, 0);
+    gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_R, gl.CLAMP_TO_EDGE);
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_BASE_LEVEL)', '0');
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_COMPARE_FUNC)', 'gl.LEQUAL');
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_COMPARE_MODE)', 'gl.COMPARE_REF_TO_TEXTURE');
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MAX_LEVEL)', '10');
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MAX_LOD)', '10');
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_MIN_LOD)', '0');
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_WRAP_R)', 'gl.CLAMP_TO_EDGE');
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_IMMUTABLE_FORMAT)', 'false');
+    shouldBe('gl.getTexParameter(gl.TEXTURE_2D, gl.TEXTURE_IMMUTABLE_LEVELS)', '0');
+  }
+  let validParametersForTexture = [
+      gl.TEXTURE_MAG_FILTER,
+      gl.TEXTURE_MIN_FILTER,
+      gl.TEXTURE_WRAP_S,
+      gl.TEXTURE_WRAP_T,
+  ];
+  if (contextVersion > 1) {
+    validParametersForTexture = validParametersForTexture.concat([
+        gl.TEXTURE_BASE_LEVEL,
         gl.TEXTURE_COMPARE_FUNC,
         gl.TEXTURE_COMPARE_MODE,
-        gl.TEXTURE_MAG_FILTER,
+        gl.TEXTURE_MAX_LEVEL,
         gl.TEXTURE_MAX_LOD,
-        gl.TEXTURE_MIN_FILTER,
         gl.TEXTURE_MIN_LOD,
         gl.TEXTURE_WRAP_R,
-        gl.TEXTURE_WRAP_S,
-        gl.TEXTURE_WRAP_T
-    );
-    testInvalidArgument(
-        "getSamplerParameter",
-        "pname",
-        validArrayForSamplerParameter,
-        function(pname) {
-            return gl.getSamplerParameter(sampler, pname);
-    });
+        gl.TEXTURE_IMMUTABLE_FORMAT,
+        gl.TEXTURE_IMMUTABLE_LEVELS,
+    ]);
+  }
+  await testInvalidArgument(
+      "getTexParameter",
+      "parameter",
+      validParametersForTexture,
+      function(parameter) {
+        return gl.getTexParameter(gl.TEXTURE_2D, parameter);
+      }
+  );
+  let validTargetsForTexture = [ gl.TEXTURE_2D, gl.TEXTURE_CUBE_MAP];
+  if (contextVersion > 1) {
+    validTargetsForTexture = validTargetsForTexture.concat([ gl.TEXTURE_3D, gl.TEXTURE_2D_ARRAY]);
+  }
+  await testInvalidArgument(
+      "getTexParameter",
+      "target",
+      validTargetsForTexture,
+      function(target) {
+        return gl.getTexParameter(target, gl.TEXTURE_MAG_FILTER);
+      }
+  );
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    debug("");
-    debug("Test getSyncParameter");
-    var sync = gl.fenceSync(gl.SYNC_GPU_COMMANDS_COMPLETE, 0);
-    shouldBe('gl.getSyncParameter(sync, gl.OBJECT_TYPE)', 'gl.SYNC_FENCE');
-    var sync_status = gl.getSyncParameter(sync, gl.SYNC_STATUS);
-    switch (sync_status) {
-      case gl.UNSIGNALED:
-        testPassed('gl.getSyncParameter(sync, gl.SYNC_CONDITION) is gl.UNSIGNALED');
-        break;
-      case gl.SIGNALED:
-        testPassed('gl.getSyncParameter(sync, gl.SYNC_CONDITION) is gl.SIGNALED');
-        break;
-      default:
-        testFailed('gl.getSyncParameter(sync, gl.SYNC_CONDITION) was ' + sync_status +
-                   ', expected gl.UNSIGNALED or gl.SIGNALED');
-        break;
-    }
-    shouldBe('gl.getSyncParameter(sync, gl.SYNC_CONDITION)', 'gl.SYNC_GPU_COMMANDS_COMPLETE');
-    shouldBe('gl.getSyncParameter(sync, gl.SYNC_FLAGS)', '0');
-    var validArrayForSyncParameter = new Array(
-        gl.OBJECT_TYPE,
-        gl.SYNC_STATUS,
-        gl.SYNC_CONDITION,
-        gl.SYNC_FLAGS
-    );
-    testInvalidArgument(
-        "getSyncParameter",
-        "pname",
-        validArrayForSyncParameter,
-        function(pname) {
-            return gl.getSyncParameter(sync, pname);
-    });
+  debug("");
+  debug("Test getUniform with all variants of data types");
+  debug("Boolean uniform variables");
+  window.boolProgram = wtu.loadProgramFromFile(gl, "../../resources/boolUniformShader.vert", "../../resources/noopUniformShader.frag");
+  shouldBe('gl.getProgramParameter(boolProgram, gl.LINK_STATUS)', 'true');
+  window.bvalLoc = gl.getUniformLocation(boolProgram, "bval");
+  window.bval2Loc = gl.getUniformLocation(boolProgram, "bval2");
+  window.bval3Loc = gl.getUniformLocation(boolProgram, "bval3");
+  window.bval4Loc = gl.getUniformLocation(boolProgram, "bval4");
+  gl.useProgram(boolProgram);
+  gl.uniform1i(bvalLoc, 1);
+  gl.uniform2i(bval2Loc, 1, 0);
+  gl.uniform3i(bval3Loc, 1, 0, 1);
+  gl.uniform4i(bval4Loc, 1, 0, 1, 0);
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  shouldBe('gl.getUniform(boolProgram, bvalLoc)', 'true');
+  shouldBe('gl.getUniform(boolProgram, bval2Loc)', '[true, false]');
+  shouldBe('gl.getUniform(boolProgram, bval3Loc)', '[true, false, true]');
+  shouldBe('gl.getUniform(boolProgram, bval4Loc)', '[true, false, true, false]');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    debug("");
-    debug("Test getQueryParameter");
-    var query = gl.createQuery();
-    gl.beginQuery(gl.TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN, query);
-    gl.endQuery(gl.TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN);
-    shouldBe('gl.getQueryParameter(query, gl.QUERY_RESULT_AVAILABLE)', 'false');
-    // Queries' results are tested elsewhere in the conformance suite. It's complicated
-    // to wait for this query's result to become available and verify it.
-    var validArrayForPname = new Array(
-        gl.QUERY_RESULT,
-        gl.QUERY_RESULT_AVAILABLE
-    );
-    testInvalidArgument(
-        "getQueryParameter",
-        "pname",
-        validArrayForPname,
-        function(pname) {
-            return gl.getQueryParameter(query, pname);
-        }
-    );
+  debug("Integer uniform variables");
+  window.intProgram = wtu.loadProgramFromFile(gl, "../../resources/intUniformShader.vert", "../../resources/noopUniformShader.frag");
+  shouldBe('gl.getProgramParameter(intProgram, gl.LINK_STATUS)', 'true');
+  window.ivalLoc = gl.getUniformLocation(intProgram, "ival");
+  window.ival2Loc = gl.getUniformLocation(intProgram, "ival2");
+  window.ival3Loc = gl.getUniformLocation(intProgram, "ival3");
+  window.ival4Loc = gl.getUniformLocation(intProgram, "ival4");
+  gl.useProgram(intProgram);
+  gl.uniform1i(ivalLoc, 1);
+  gl.uniform2i(ival2Loc, 2, 3);
+  gl.uniform3i(ival3Loc, 4, 5, 6);
+  gl.uniform4i(ival4Loc, 7, 8, 9, 10);
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  shouldBe('gl.getUniform(intProgram, ivalLoc)', '1');
+  shouldBe('gl.getUniform(intProgram, ival2Loc)', '[2, 3]');
+  shouldBe('gl.getUniform(intProgram, ival3Loc)', '[4, 5, 6]');
+  shouldBe('gl.getUniform(intProgram, ival4Loc)', '[7, 8, 9, 10]');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    debug("");
-    debug("Test getFragDataLocation");
-    var baseVertShader = '' +
-    '#version 300 es\n' +
-    'uniform mat4 modelViewMatrix;\n' +
-    'uniform mat4 projectionMatrix;\n' +
-    'in vec4 vertex;\n' +
-    'out vec4 position;\n' +
-    'void main (void)\n' +
-    '{\n' +
-    '       position = modelViewMatrix * vertex;\n' +
-    '       gl_Position = projectionMatrix * position;\n' +
-    '}\n';
-    var baseFragShader = '' +
-    '#version 300 es\n' +
-    'in lowp vec4 position;\n' +
-    'layout(location = 0) out mediump vec4 fragColor;\n' +
-    'void main (void)\n' +
-    '{\n' +
-    '       fragColor = position;\n' +
-    '}\n';
-    var vertShader = gl.createShader(gl.VERTEX_SHADER);
-    gl.shaderSource(vertShader, baseVertShader);
-    gl.compileShader(vertShader);
-    shouldBe('gl.getShaderParameter(vertShader, gl.COMPILE_STATUS)', 'true');
-    var fragShader = gl.createShader(gl.FRAGMENT_SHADER);
-    gl.shaderSource(fragShader, baseFragShader);
-    gl.compileShader(fragShader);
-    shouldBe('gl.getShaderParameter(fragShader, gl.COMPILE_STATUS)', 'true');
-    var program = gl.createProgram();
-    gl.attachShader(program, vertShader);
-    gl.attachShader(program, fragShader);
-    gl.linkProgram(program);
-    shouldBe('gl.getProgramParameter(program, gl.LINK_STATUS)','true');
-    shouldBe('gl.getFragDataLocation(program, "vertexColor")', '-1');
-    shouldBe('gl.getFragDataLocation(program, "modelViewMatrix")', '-1');
-    shouldBe('gl.getFragDataLocation(program, "projectionMatrix")', '-1');
-    shouldBe('gl.getFragDataLocation(program, "position")', '-1');
-    shouldBe('gl.getFragDataLocation(program, "fragColor")', '0');
+  debug("Float uniform variables");
+  window.floatProgram = wtu.loadProgramFromFile(gl, "../../resources/floatUniformShader.vert", "../../resources/noopUniformShader.frag");
+  shouldBe('gl.getProgramParameter(floatProgram, gl.LINK_STATUS)', 'true');
+  window.fvalLoc = gl.getUniformLocation(floatProgram, "fval");
+  window.fval2Loc = gl.getUniformLocation(floatProgram, "fval2");
+  window.fval3Loc = gl.getUniformLocation(floatProgram, "fval3");
+  window.fval4Loc = gl.getUniformLocation(floatProgram, "fval4");
+  gl.useProgram(floatProgram);
+  gl.uniform1f(fvalLoc, 11);
+  gl.uniform2f(fval2Loc, 12, 13);
+  gl.uniform3f(fval3Loc, 14, 15, 16);
+  gl.uniform4f(fval4Loc, 17, 18, 19, 20);
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  shouldBe('gl.getUniform(floatProgram, fvalLoc)', '11');
+  shouldBe('gl.getUniform(floatProgram, fval2Loc)', '[12, 13]');
+  shouldBe('gl.getUniform(floatProgram, fval3Loc)', '[14, 15, 16]');
+  shouldBe('gl.getUniform(floatProgram, fval4Loc)', '[17, 18, 19, 20]');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    debug("");
-    debug("Test getActiveUniforms");
-    var program = wtu.loadUniformBlockProgram(gl);
-    gl.linkProgram(program);
-    shouldBe('gl.getProgramParameter(program, gl.LINK_STATUS)', 'true');
-    shouldBe('gl.getError()', 'gl.NO_ERROR');
+  debug("Sampler uniform variables");
+  window.samplerProgram = wtu.loadProgramFromFile(gl, "../../resources/noopUniformShader.vert", "../../resources/samplerUniformShader.frag");
+  shouldBe('gl.getProgramParameter(samplerProgram, gl.LINK_STATUS)', 'true');
+  window.s2DValLoc = gl.getUniformLocation(samplerProgram, "s2D");
+  window.sCubeValLoc = gl.getUniformLocation(samplerProgram, "sCube");
+  gl.useProgram(samplerProgram);
+  gl.uniform1i(s2DValLoc, 0);
+  gl.uniform1i(sCubeValLoc, 1);
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  shouldBe('gl.getUniform(samplerProgram, s2DValLoc)', '0');
+  shouldBe('gl.getUniform(samplerProgram, sCubeValLoc)', '1');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    var numActiveUniforms = gl.getProgramParameter(program, gl.ACTIVE_UNIFORMS);
-    var blockIndex = gl.getUniformBlockIndex(program, "Transform");
-    var uniformIndices = [];
-    for (var i = 0; i < numActiveUniforms; i++)
-      uniformIndices.push(i);
-    var types = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_TYPE);
-    var sizes = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_SIZE);
-    var blockIndices = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_BLOCK_INDEX);
-    var offsets = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_OFFSET);
-    var arrayStrides = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_ARRAY_STRIDE);
-    var matrixStrides = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_MATRIX_STRIDE);
-    var rowMajors = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_IS_ROW_MAJOR);
-    for (var i = 0; i < numActiveUniforms; i++) {
-      if (types[i] != gl.FLOAT_MAT4 && types[i] != gl.FLOAT_MAT3)
-        testFailed("expected value: GL_FLOAT_MAT4 or GL_FLOAT_MAT3" + " actual value for UNIFORM_TYPE for uniform index[" + i + "]:" + wtu.glEnumToString(gl, types[i]));
-      if (sizes[i] != 1)
-        testFailed("expected value: 1" + " actual value for UNIFORM_SIZE for uniform index[" + i + "]:" + sizes[i]);
-      if (blockIndices[i] != blockIndex)
-        testFailed("expected value: 0" + " actual value for UNIFORM_BLOCK_INDEX for uniform index[" + i + "]:" + blockIndices[i]);
-      if (offsets[i] < 0)
-        testFailed("expected value >= 0" + " actual value for UNIFORM_OFFSET for uniform index[" + i + "]:" + offsets[i]);
-      if (arrayStrides[i] != 0)
-        testFailed("expected value: 0" + " actual value for UNIFORM_ARRAY_STRIDE for uniform index[" + i + "]:" + arrayStrides[i]);
-      if (matrixStrides[i] < 0)
-        testFailed("expected value >= 0" + " actual value for UNIFORM_MATRIX_STRIDE for uniform index[" + i + "]:" + matrixStrides[i]);
-      shouldBe('typeof rowMajors[i]', '"boolean"');
-      if (rowMajors[i] != false)
-        testFailed("expected value: 0" + " actual value for UNIFORM_IS_ROW_MAJOR for uniform index[" + i + "]:" + rowMajors[i]);
-    }
+  debug("Matrix uniform variables");
+  window.matProgram = wtu.loadProgramFromFile(gl, "../../resources/matUniformShader.vert", "../../resources/noopUniformShader.frag");
+  shouldBe('gl.getProgramParameter(matProgram, gl.LINK_STATUS)', 'true');
+  window.mval2Loc = gl.getUniformLocation(matProgram, "mval2");
+  window.mval3Loc = gl.getUniformLocation(matProgram, "mval3");
+  window.mval4Loc = gl.getUniformLocation(matProgram, "mval4");
+  gl.useProgram(matProgram);
+  gl.uniformMatrix2fv(mval2Loc, false, [1, 2, 3, 4]);
+  gl.uniformMatrix3fv(mval3Loc, false, [5, 6, 7, 8, 9, 10, 11, 12, 13]);
+  gl.uniformMatrix4fv(mval4Loc, false, [14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29]);
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  shouldBe('gl.getUniform(matProgram, mval2Loc)', '[1, 2, 3, 4]');
+  shouldBe('gl.getUniform(matProgram, mval3Loc)', '[5, 6, 7, 8, 9, 10, 11, 12, 13]');
+  shouldBe('gl.getUniform(matProgram, mval4Loc)', '[14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29]');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    var validArrayForPname = new Array(
-        gl.UNIFORM_TYPE,
-        gl.UNIFORM_SIZE,
-        gl.UNIFORM_BLOCK_INDEX,
-        gl.UNIFORM_OFFSET,
-        gl.UNIFORM_ARRAY_STRIDE,
-        gl.UNIFORM_MATRIX_STRIDE,
-        gl.UNIFORM_IS_ROW_MAJOR
-    );
-    testInvalidArgument(
-        "getActiveUniforms",
-        "pname",
-        validArrayForPname,
-        function(pname) {
-            return gl.getActiveUniforms(program, uniformIndices, pname);
-        }
-    );
+  if (contextVersion > 1) {
+    debug("Unsigned Integer uniform variables");
+    window.uintProgram = wtu.loadProgramFromFile(gl, "../../resources/uintUniformShader.vert", "../../resources/noopUniformShaderES3.frag");
+    shouldBe('gl.getProgramParameter(uintProgram, gl.LINK_STATUS)', 'true');
+    window.uvalLoc = gl.getUniformLocation(uintProgram, "uval");
+    window.uval2Loc = gl.getUniformLocation(uintProgram, "uval2");
+    window.uval3Loc = gl.getUniformLocation(uintProgram, "uval3");
+    window.uval4Loc = gl.getUniformLocation(uintProgram, "uval4");
+    gl.useProgram(uintProgram);
+    gl.uniform1ui(uvalLoc, 1);
+    gl.uniform2ui(uval2Loc, 2, 3);
+    gl.uniform3ui(uval3Loc, 4, 5, 6);
+    gl.uniform4ui(uval4Loc, 7, 8, 9, 10);
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+    shouldBe('gl.getUniform(uintProgram, uvalLoc)', '1');
+    shouldBe('gl.getUniform(uintProgram, uval2Loc)', '[2, 3]');
+    shouldBe('gl.getUniform(uintProgram, uval3Loc)', '[4, 5, 6]');
+    shouldBe('gl.getUniform(uintProgram, uval4Loc)', '[7, 8, 9, 10]');
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    debug("");
-    debug("Test getUniformBlockIndex");
-    var program = wtu.loadUniformBlockProgram(gl);
-    gl.linkProgram(program);
-    shouldBeTrue('gl.getProgramParameter(program, gl.LINK_STATUS)');
-    shouldBe('gl.getUniformBlockIndex(program, "Transform")', '0');
-    shouldBe('gl.getUniformBlockIndex(program, "u_modelViewMatrix")', 'gl.INVALID_INDEX');
-    shouldBe('gl.getUniformBlockIndex(program, "normal")', 'gl.INVALID_INDEX');
-    shouldBe('gl.getUniformBlockIndex(program, "u_normal")', 'gl.INVALID_INDEX');
-    var noUniformProgram = wtu.loadStandardProgram(gl);
-    gl.linkProgram(noUniformProgram);
-    shouldBeTrue('gl.getProgramParameter(noUniformProgram, gl.LINK_STATUS)');
-    shouldBe('gl.getUniformBlockIndex(noUniformProgram, "u_modelViewProjMatrix")', 'gl.INVALID_INDEX');
-    shouldBe('gl.getUniformBlockIndex(noUniformProgram, "u_normal")', 'gl.INVALID_INDEX');
+    debug("Matrix uniform variables for WebGL 2");
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    debug("");
-    debug("Test getActiveUniformBlockName");
-    var program = wtu.loadUniformBlockProgram(gl);
-    gl.linkProgram(program);
-    shouldBeTrue('gl.getProgramParameter(program, gl.LINK_STATUS)');
-    shouldBeEqualToString('gl.getActiveUniformBlockName(program, 0)', 'Transform');
-    shouldBeNull('gl.getActiveUniformBlockName(program, -1)');
-    wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
-    shouldBeNull('gl.getActiveUniformBlockName(program, 1)');
-    wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
-    shouldBeNull('gl.getActiveUniformBlockName(program, gl.INVALID_INDEX)');
-    wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
-    var noLinkProgram = gl.createProgram();
-    shouldBeFalse('gl.getProgramParameter(noLinkProgram, gl.LINK_STATUS)');
-    wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getActiveUniformBlockName(noLinkProgram, 0)');
-    var noUniformProgram = wtu.loadStandardProgram(gl);
-    gl.linkProgram(noUniformProgram);
-    shouldBeTrue('gl.getProgramParameter(noUniformProgram, gl.LINK_STATUS)');
-    shouldBeNull('gl.getActiveUniformBlockName(noUniformProgram, -1)');
-    wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
-    shouldBeNull('gl.getActiveUniformBlockName(noUniformProgram, 0)');
-    wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
-    shouldBeNull('gl.getActiveUniformBlockName(noUniformProgram, gl.INVALID_INDEX)');
-    wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
+    window.matForWebGL2Program = wtu.loadProgramFromFile(gl, "../../resources/matForWebGL2UniformShader.vert", "../../resources/noopUniformShaderES3.frag");
+    shouldBe('gl.getProgramParameter(matForWebGL2Program, gl.LINK_STATUS)', 'true');
+    window.mval2x3Loc = gl.getUniformLocation(matForWebGL2Program, "mval2x3");
+    window.mval2x4Loc = gl.getUniformLocation(matForWebGL2Program, "mval2x4");
+    window.mval3x2Loc = gl.getUniformLocation(matForWebGL2Program, "mval3x2");
+    window.mval3x4Loc = gl.getUniformLocation(matForWebGL2Program, "mval3x4");
+    window.mval4x2Loc = gl.getUniformLocation(matForWebGL2Program, "mval4x2");
+    window.mval4x3Loc = gl.getUniformLocation(matForWebGL2Program, "mval4x3");
+    gl.useProgram(matForWebGL2Program);
+    gl.uniformMatrix2x3fv(mval2x3Loc, false, [1, 2, 3, 4, 5, 6]);
+    gl.uniformMatrix2x4fv(mval2x4Loc, false, [7, 8, 9, 10, 11, 12, 13, 14]);
+    gl.uniformMatrix3x2fv(mval3x2Loc, false, [15, 16, 17, 18, 19, 20]);
+    gl.uniformMatrix3x4fv(mval3x4Loc, false, [21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32]);
+    gl.uniformMatrix4x2fv(mval4x2Loc, false, [33, 34, 35, 36, 37, 38, 39, 40]);
+    gl.uniformMatrix4x3fv(mval4x3Loc, false, [41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52]);
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+    shouldBe('gl.getUniform(matForWebGL2Program, mval2x3Loc)', '[1, 2, 3, 4, 5, 6]');
+    shouldBe('gl.getUniform(matForWebGL2Program, mval2x4Loc)', '[7, 8, 9, 10, 11, 12, 13, 14]');
+    shouldBe('gl.getUniform(matForWebGL2Program, mval3x2Loc)', '[15, 16, 17, 18, 19, 20]');
+    shouldBe('gl.getUniform(matForWebGL2Program, mval3x4Loc)', '[21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32]');
+    shouldBe('gl.getUniform(matForWebGL2Program, mval4x2Loc)', '[33, 34, 35, 36, 37, 38, 39, 40]');
+    shouldBe('gl.getUniform(matForWebGL2Program, mval4x3Loc)', '[41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52]');
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
 
-    debug("");
-    debug("Test getActiveUniformBlockParameter");
-    var program = wtu.loadUniformBlockProgram(gl);
-    gl.linkProgram(program);
-    shouldBeTrue('gl.getProgramParameter(program, gl.LINK_STATUS)');
-    shouldBe('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_BINDING)', '0');
-    gl.uniformBlockBinding(program, 0, 1);
-    shouldBe('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_BINDING)', '1');
-    // The actual block data size can be bigger than 164, depending on the uniform block layout.
-    shouldBeTrue('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_DATA_SIZE) >= 164');
-    shouldBe('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_ACTIVE_UNIFORMS)', '3');
-    shouldBeTrue('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER)');
-    shouldBeFalse('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER)');
-    var indices = gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES);
-    for (var i = 0; i < 3; i++) {
-      if (indices[i] < 0)
-        testFailed("expected value >= 0" + " actual value for UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES for uniform index[" + i + "]:" + indices[i]);
-    }
-    var validArrayForPname = new Array(
-        gl.UNIFORM_BLOCK_BINDING,
-        gl.UNIFORM_BLOCK_DATA_SIZE,
-        gl.UNIFORM_BLOCK_ACTIVE_UNIFORMS,
-        gl.UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES,
-        gl.UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER,
-        gl.UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER
-    );
-    testInvalidArgument(
-        "getActiveUniformBlockParameter",
-        "pname",
-        validArrayForPname,
-        function(pname) {
-            return gl.getActiveUniformBlockParameter(program, 0, pname);
-        }
-    );
-}
+    debug("Sampler uniform variables for WebGL2");
+    window.samplerForWebGL2Program = wtu.loadProgramFromFile(gl, "../../resources/noopUniformShaderES3.vert", "../../resources/samplerForWebGL2UniformShader.frag");
+    shouldBe('gl.getProgramParameter(samplerForWebGL2Program, gl.LINK_STATUS)', 'true');
+    window.s3DValLoc = gl.getUniformLocation(samplerForWebGL2Program, "s3D");
+    window.s2DArrayValLoc = gl.getUniformLocation(samplerForWebGL2Program, "s2DArray");
+    gl.useProgram(samplerForWebGL2Program);
+    gl.uniform1i(s3DValLoc, 0);
+    gl.uniform1i(s2DArrayValLoc, 1);
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+    shouldBe('gl.getUniform(samplerForWebGL2Program, s3DValLoc)', '0');
+    shouldBe('gl.getUniform(samplerForWebGL2Program, s2DArrayValLoc)', '1');
+    wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  }
 
-wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  debug("");
+  debug("test getVertexAttrib");
+  let array = new Float32Array([1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]);
+  window.buffer = gl.createBuffer();
+  gl.bindBuffer(gl.ARRAY_BUFFER, buffer);
+  gl.bufferData(gl.ARRAY_BUFFER, array, gl.DYNAMIC_DRAW);
+  // Vertex attribute 0 is special in that it has no current state, so
+  // fetching GL_CURRENT_VERTEX_ATTRIB generates an error. Use attribute
+  // 1 for these tests instead.
+  gl.enableVertexAttribArray(1);
+  gl.vertexAttribPointer(1, 4, gl.FLOAT, false, 0, 0);
+  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING)', 'buffer');
+  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_ENABLED)', 'true');
+  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_SIZE)', '4');
+  // Stride MUST be the value the user put in.
+  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_STRIDE)', '0');
+  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_TYPE)', 'gl.FLOAT');
+  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_NORMALIZED)', 'false');
+  if (contextVersion > 1) {
+    shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_DIVISOR)', '0');
+    shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_INTEGER)', 'false');
+    gl.vertexAttribDivisor(1, 2);
+    shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_DIVISOR)', '2');
+  }
+  gl.vertexAttribPointer(1, 4, gl.FLOAT, false, 36, 12);
+  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_STRIDE)', '36');
+  shouldBe('gl.getVertexAttribOffset(1, gl.VERTEX_ATTRIB_ARRAY_POINTER)', '12');
+  gl.disableVertexAttribArray(1);
+  shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_ENABLED)', 'false');
+  gl.vertexAttrib4f(1, 5, 6, 7, 8);
+  shouldBe('gl.getVertexAttrib(1, gl.CURRENT_VERTEX_ATTRIB)', '[5, 6, 7, 8]');
+  if (contextVersion > 1) {
+    let intArray = new Int32Array([1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]);
+    gl.bufferData(gl.ARRAY_BUFFER, intArray, gl.DYNAMIC_DRAW);
+    gl.enableVertexAttribArray(1);
+    // feed fixed-point data to buffer
+    gl.vertexAttribIPointer(1, 4, gl.INT, false, 0, 0);
+    shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_TYPE)', 'gl.INT');
+    shouldBe('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_INTEGER)', 'true');
+  }
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+  let validArrayForVertexAttrib = new Array(
+      gl.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING,
+      gl.VERTEX_ATTRIB_ARRAY_ENABLED,
+      gl.VERTEX_ATTRIB_ARRAY_SIZE,
+      gl.VERTEX_ATTRIB_ARRAY_STRIDE,
+      gl.VERTEX_ATTRIB_ARRAY_TYPE,
+      gl.VERTEX_ATTRIB_ARRAY_NORMALIZED,
+      gl.CURRENT_VERTEX_ATTRIB
+  );
+  if (contextVersion > 1) {
+    validArrayForVertexAttrib[validArrayForVertexAttrib.length] = gl.VERTEX_ATTRIB_ARRAY_DIVISOR;
+    validArrayForVertexAttrib[validArrayForVertexAttrib.length] = gl.VERTEX_ATTRIB_ARRAY_INTEGER;
+  }
+  await testInvalidArgument(
+      "getVertexAttrib",
+      "parameter",
+      validArrayForVertexAttrib,
+      function(parameter) {
+        return gl.getVertexAttrib(1, parameter);
+      }
+  );
+  let numVertexAttribs = gl.getParameter(gl.MAX_VERTEX_ATTRIBS);
+  wtu.shouldGenerateGLError(gl, gl.INVALID_VALUE, 'gl.getVertexAttrib(' + numVertexAttribs + ', gl.CURRENT_VERTEX_ATTRIB)');
 
-var successfullyParsed = true;
+  debug("");
+  debug("Test cases where name == 0");
+  gl.bindFramebuffer(gl.FRAMEBUFFER, framebuffer);
+
+  shouldNotBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.NONE');
+  gl.deleteTexture(texture);
+  shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.NONE');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+
+  shouldNotBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.NONE');
+  gl.deleteRenderbuffer(renderbuffer);
+  shouldBe('gl.getFramebufferAttachmentParameter(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)', 'gl.NONE');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+
+  gl.deleteBuffer(buffer);
+  shouldBeNull('gl.getVertexAttrib(1, gl.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING)');
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+
+  if (contextVersion > 1) {
+      debug("");
+      debug("Test getInternalformatParameter")
+
+      shouldBeNonNull('gl.getInternalformatParameter(gl.RENDERBUFFER, gl.R32I, gl.SAMPLES)');
+      wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+
+      await testInvalidArgument(
+          "getInternalformatParameter",
+          "target",
+          [ gl.RENDERBUFFER ],
+          function(target) {
+              return gl.getInternalformatParameter(target, gl.R32I, gl.SAMPLES);
+      });
+
+      await testInvalidArgument(
+          "getInternalformatParameter",
+          "pname",
+          [ gl.SAMPLES ],
+          function(pname) {
+              return gl.getInternalformatParameter(gl.RENDERBUFFER, gl.RGBA4, pname);
+      });
+
+      let validArrayForInterformat = new Array(
+          gl.R8, gl.R8_SNORM, gl.RG8, gl.RG8_SNORM,
+          gl.RGB8, gl.RGB8_SNORM, gl.RGB565, gl.RGBA4,
+          gl.RGB5_A1, gl.RGBA8, gl.RGBA8_SNORM, gl.RGB10_A2,
+          gl.RGB10_A2UI, gl.SRGB8, gl.SRGB8_ALPHA8, gl.R16F,
+          gl.RG16F, gl.RGB16F, gl.RGBA16F, gl.R32F,
+          gl.RG32F, gl.RGB32F, gl.RGBA32F, gl.R11F_G11F_B10F,
+          gl.RGB9_E5, gl.R8I, gl.R8UI, gl.R16I,
+          gl.R16UI, gl.R32I, gl.R32UI, gl.RG8I,
+          gl.RG8UI, gl.RG16I, gl.RG16UI, gl.RG32I,
+          gl.RG32UI, gl.RGB8I, gl.RGB8UI, gl.RGB16I,
+          gl.RGB16UI, gl.RGB32I, gl.RGB32UI, gl.RGBA8I,
+          gl.RGBA8UI, gl.RGBA16I, gl.RGBA16UI, gl.RGBA32I,
+          gl.RGBA32UI, gl.RGB, gl.RGBA, gl.DEPTH_STENCIL, gl.DEPTH_COMPONENT16,
+          gl.DEPTH_COMPONENT24, gl.DEPTH_COMPONENT32F, gl.DEPTH24_STENCIL8,
+          gl.DEPTH32F_STENCIL8, gl.STENCIL_INDEX8
+      );
+      await testInvalidArgument(
+          "getInternalformatParameter",
+          "internalformat",
+          validArrayForInterformat,
+          function(internalformat) {
+              return gl.getInternalformatParameter(gl.RENDERBUFFER, internalformat, gl.SAMPLES);
+      });
+
+
+      debug("");
+      debug("Test getIndexedParameter");
+      window.buffer = gl.createBuffer();
+      gl.bindBuffer(gl.TRANSFORM_FEEDBACK_BUFFER, buffer);
+      gl.bufferData(gl.TRANSFORM_FEEDBACK_BUFFER, 64, gl.DYNAMIC_DRAW);
+      gl.bindBufferRange(gl.TRANSFORM_FEEDBACK_BUFFER, 0, buffer, 4, 8);
+      shouldBe('gl.getIndexedParameter(gl.TRANSFORM_FEEDBACK_BUFFER_BINDING, 0)', 'buffer');
+      shouldBe('gl.getIndexedParameter(gl.TRANSFORM_FEEDBACK_BUFFER_SIZE, 0)', '8');
+      shouldBe('gl.getIndexedParameter(gl.TRANSFORM_FEEDBACK_BUFFER_START, 0)', '4');
+      window.buffer1 = gl.createBuffer();
+      gl.bindBuffer(gl.UNIFORM_BUFFER, buffer1);
+      gl.bufferData(gl.UNIFORM_BUFFER, 64, gl.DYNAMIC_DRAW);
+      window.offsetUniform = gl.getParameter(gl.UNIFORM_BUFFER_OFFSET_ALIGNMENT);
+      gl.bindBufferRange(gl.UNIFORM_BUFFER, 1, buffer1, offsetUniform, 8);
+      shouldBe('gl.getIndexedParameter(gl.UNIFORM_BUFFER_BINDING, 1)', 'buffer1');
+      shouldBe('gl.getIndexedParameter(gl.UNIFORM_BUFFER_SIZE, 1)', '8');
+      shouldBe('gl.getIndexedParameter(gl.UNIFORM_BUFFER_START, 1)', 'offsetUniform');
+
+      gl.bindBufferBase(gl.UNIFORM_BUFFER, 1, null);
+      shouldBe('gl.getIndexedParameter(gl.UNIFORM_BUFFER_BINDING, 1)', 'null');
+
+      let validArrayForTarget = new Array(
+          gl.TRANSFORM_FEEDBACK_BUFFER_BINDING,
+          gl.TRANSFORM_FEEDBACK_BUFFER_SIZE,
+          gl.TRANSFORM_FEEDBACK_BUFFER_START,
+          gl.UNIFORM_BUFFER_BINDING,
+          gl.UNIFORM_BUFFER_SIZE,
+          gl.UNIFORM_BUFFER_START
+      );
+      await testInvalidArgument(
+          "getIndexedParameter",
+          "target",
+          validArrayForTarget,
+          function(target) {
+              return gl.getIndexedParameter(target, 0);
+      });
+
+      debug("");
+      debug("Test getSamplerParameter");
+      window.sampler = gl.createSampler();
+      gl.samplerParameteri(sampler, gl.TEXTURE_COMPARE_FUNC, gl.LEQUAL);
+      gl.samplerParameteri(sampler, gl.TEXTURE_COMPARE_MODE, gl.COMPARE_REF_TO_TEXTURE);
+      gl.samplerParameteri(sampler, gl.TEXTURE_MAG_FILTER, gl.NEAREST);
+      gl.samplerParameterf(sampler, gl.TEXTURE_MAX_LOD, 10);
+      gl.samplerParameteri(sampler, gl.TEXTURE_MIN_FILTER, gl.NEAREST);
+      gl.samplerParameterf(sampler, gl.TEXTURE_MIN_LOD, 0);
+      gl.samplerParameteri(sampler, gl.TEXTURE_WRAP_R, gl.CLAMP_TO_EDGE);
+      gl.samplerParameteri(sampler, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);
+      gl.samplerParameteri(sampler, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_COMPARE_FUNC)', 'gl.LEQUAL');
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_COMPARE_MODE)', 'gl.COMPARE_REF_TO_TEXTURE');
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_MAG_FILTER)', 'gl.NEAREST');
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_MAX_LOD)', '10');
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_MIN_FILTER)', 'gl.NEAREST');
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_MIN_LOD)', '0');
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_WRAP_R)', 'gl.CLAMP_TO_EDGE');
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_WRAP_S)', 'gl.CLAMP_TO_EDGE');
+      shouldBe('gl.getSamplerParameter(sampler, gl.TEXTURE_WRAP_T)', 'gl.CLAMP_TO_EDGE');
+      let validArrayForSamplerParameter = new Array(
+          gl.TEXTURE_COMPARE_FUNC,
+          gl.TEXTURE_COMPARE_MODE,
+          gl.TEXTURE_MAG_FILTER,
+          gl.TEXTURE_MAX_LOD,
+          gl.TEXTURE_MIN_FILTER,
+          gl.TEXTURE_MIN_LOD,
+          gl.TEXTURE_WRAP_R,
+          gl.TEXTURE_WRAP_S,
+          gl.TEXTURE_WRAP_T
+      );
+      await testInvalidArgument(
+          "getSamplerParameter",
+          "pname",
+          validArrayForSamplerParameter,
+          function(pname) {
+              return gl.getSamplerParameter(sampler, pname);
+      });
+
+      debug("");
+      debug("Test getSyncParameter");
+      window.sync = gl.fenceSync(gl.SYNC_GPU_COMMANDS_COMPLETE, 0);
+      shouldBe('gl.getSyncParameter(sync, gl.OBJECT_TYPE)', 'gl.SYNC_FENCE');
+      let sync_status = gl.getSyncParameter(sync, gl.SYNC_STATUS);
+      switch (sync_status) {
+        case gl.UNSIGNALED:
+          testPassed('gl.getSyncParameter(sync, gl.SYNC_CONDITION) is gl.UNSIGNALED');
+          break;
+        case gl.SIGNALED:
+          testPassed('gl.getSyncParameter(sync, gl.SYNC_CONDITION) is gl.SIGNALED');
+          break;
+        default:
+          testFailed('gl.getSyncParameter(sync, gl.SYNC_CONDITION) was ' + sync_status +
+                     ', expected gl.UNSIGNALED or gl.SIGNALED');
+          break;
+      }
+      shouldBe('gl.getSyncParameter(sync, gl.SYNC_CONDITION)', 'gl.SYNC_GPU_COMMANDS_COMPLETE');
+      shouldBe('gl.getSyncParameter(sync, gl.SYNC_FLAGS)', '0');
+      let validArrayForSyncParameter = new Array(
+          gl.OBJECT_TYPE,
+          gl.SYNC_STATUS,
+          gl.SYNC_CONDITION,
+          gl.SYNC_FLAGS
+      );
+      await testInvalidArgument(
+          "getSyncParameter",
+          "pname",
+          validArrayForSyncParameter,
+          function(pname) {
+              return gl.getSyncParameter(sync, pname);
+      });
+
+      debug("");
+      debug("Test getQueryParameter");
+      window.query = gl.createQuery();
+      gl.beginQuery(gl.TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN, query);
+      gl.endQuery(gl.TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN);
+      shouldBe('gl.getQueryParameter(query, gl.QUERY_RESULT_AVAILABLE)', 'false');
+      // Queries' results are tested elsewhere in the conformance suite. It's complicated
+      // to wait for this query's result to become available and verify it.
+      let validArrayForPname = new Array(
+          gl.QUERY_RESULT,
+          gl.QUERY_RESULT_AVAILABLE
+      );
+      await testInvalidArgument(
+          "getQueryParameter",
+          "pname",
+          validArrayForPname,
+          function(pname) {
+              return gl.getQueryParameter(query, pname);
+          }
+      );
+
+      debug("");
+      debug("Test getFragDataLocation");
+      let baseVertShader = '' +
+      '#version 300 es\n' +
+      'uniform mat4 modelViewMatrix;\n' +
+      'uniform mat4 projectionMatrix;\n' +
+      'in vec4 vertex;\n' +
+      'out vec4 position;\n' +
+      'void main (void)\n' +
+      '{\n' +
+      '       position = modelViewMatrix * vertex;\n' +
+      '       gl_Position = projectionMatrix * position;\n' +
+      '}\n';
+      let baseFragShader = '' +
+      '#version 300 es\n' +
+      'in lowp vec4 position;\n' +
+      'layout(location = 0) out mediump vec4 fragColor;\n' +
+      'void main (void)\n' +
+      '{\n' +
+      '       fragColor = position;\n' +
+      '}\n';
+      window.vertShader = gl.createShader(gl.VERTEX_SHADER);
+      gl.shaderSource(vertShader, baseVertShader);
+      gl.compileShader(vertShader);
+      shouldBe('gl.getShaderParameter(vertShader, gl.COMPILE_STATUS)', 'true');
+      window.fragShader = gl.createShader(gl.FRAGMENT_SHADER);
+      gl.shaderSource(fragShader, baseFragShader);
+      gl.compileShader(fragShader);
+      shouldBe('gl.getShaderParameter(fragShader, gl.COMPILE_STATUS)', 'true');
+      window.program = gl.createProgram();
+      gl.attachShader(program, vertShader);
+      gl.attachShader(program, fragShader);
+      gl.linkProgram(program);
+      shouldBe('gl.getProgramParameter(program, gl.LINK_STATUS)','true');
+      shouldBe('gl.getFragDataLocation(program, "vertexColor")', '-1');
+      shouldBe('gl.getFragDataLocation(program, "modelViewMatrix")', '-1');
+      shouldBe('gl.getFragDataLocation(program, "projectionMatrix")', '-1');
+      shouldBe('gl.getFragDataLocation(program, "position")', '-1');
+      shouldBe('gl.getFragDataLocation(program, "fragColor")', '0');
+
+      debug("");
+      debug("Test getActiveUniforms");
+      program = wtu.loadUniformBlockProgram(gl);
+      gl.linkProgram(program);
+      shouldBe('gl.getProgramParameter(program, gl.LINK_STATUS)', 'true');
+      shouldBe('gl.getError()', 'gl.NO_ERROR');
+
+      let numActiveUniforms = gl.getProgramParameter(program, gl.ACTIVE_UNIFORMS);
+      let blockIndex = gl.getUniformBlockIndex(program, "Transform");
+      let uniformIndices = [];
+      for (let i = 0; i < numActiveUniforms; i++)
+        uniformIndices.push(i);
+      let types = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_TYPE);
+      let sizes = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_SIZE);
+      let blockIndices = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_BLOCK_INDEX);
+      let offsets = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_OFFSET);
+      let arrayStrides = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_ARRAY_STRIDE);
+      let matrixStrides = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_MATRIX_STRIDE);
+      let rowMajors = gl.getActiveUniforms(program, uniformIndices, gl.UNIFORM_IS_ROW_MAJOR);
+      for (let i = 0; i < numActiveUniforms; i++) {
+        if (types[i] != gl.FLOAT_MAT4 && types[i] != gl.FLOAT_MAT3)
+          testFailed("expected value: GL_FLOAT_MAT4 or GL_FLOAT_MAT3" + " actual value for UNIFORM_TYPE for uniform index[" + i + "]:" + wtu.glEnumToString(gl, types[i]));
+        if (sizes[i] != 1)
+          testFailed("expected value: 1" + " actual value for UNIFORM_SIZE for uniform index[" + i + "]:" + sizes[i]);
+        if (blockIndices[i] != blockIndex)
+          testFailed("expected value: 0" + " actual value for UNIFORM_BLOCK_INDEX for uniform index[" + i + "]:" + blockIndices[i]);
+        if (offsets[i] < 0)
+          testFailed("expected value >= 0" + " actual value for UNIFORM_OFFSET for uniform index[" + i + "]:" + offsets[i]);
+        if (arrayStrides[i] != 0)
+          testFailed("expected value: 0" + " actual value for UNIFORM_ARRAY_STRIDE for uniform index[" + i + "]:" + arrayStrides[i]);
+        if (matrixStrides[i] < 0)
+          testFailed("expected value >= 0" + " actual value for UNIFORM_MATRIX_STRIDE for uniform index[" + i + "]:" + matrixStrides[i]);
+        shouldBe(`"${typeof rowMajors[i]}"`, '"boolean"');
+        if (rowMajors[i] != false)
+          testFailed("expected value: 0" + " actual value for UNIFORM_IS_ROW_MAJOR for uniform index[" + i + "]:" + rowMajors[i]);
+      }
+
+      validArrayForPname = new Array(
+          gl.UNIFORM_TYPE,
+          gl.UNIFORM_SIZE,
+          gl.UNIFORM_BLOCK_INDEX,
+          gl.UNIFORM_OFFSET,
+          gl.UNIFORM_ARRAY_STRIDE,
+          gl.UNIFORM_MATRIX_STRIDE,
+          gl.UNIFORM_IS_ROW_MAJOR
+      );
+      await testInvalidArgument(
+          "getActiveUniforms",
+          "pname",
+          validArrayForPname,
+          function(pname) {
+              return gl.getActiveUniforms(program, uniformIndices, pname);
+          }
+      );
+
+      debug("");
+      debug("Test getUniformBlockIndex");
+      program = wtu.loadUniformBlockProgram(gl);
+      gl.linkProgram(program);
+      shouldBeTrue('gl.getProgramParameter(program, gl.LINK_STATUS)');
+      shouldBe('gl.getUniformBlockIndex(program, "Transform")', '0');
+      shouldBe('gl.getUniformBlockIndex(program, "u_modelViewMatrix")', 'gl.INVALID_INDEX');
+      shouldBe('gl.getUniformBlockIndex(program, "normal")', 'gl.INVALID_INDEX');
+      shouldBe('gl.getUniformBlockIndex(program, "u_normal")', 'gl.INVALID_INDEX');
+      window.noUniformProgram = wtu.loadStandardProgram(gl);
+      gl.linkProgram(noUniformProgram);
+      shouldBeTrue('gl.getProgramParameter(noUniformProgram, gl.LINK_STATUS)');
+      shouldBe('gl.getUniformBlockIndex(noUniformProgram, "u_modelViewProjMatrix")', 'gl.INVALID_INDEX');
+      shouldBe('gl.getUniformBlockIndex(noUniformProgram, "u_normal")', 'gl.INVALID_INDEX');
+
+      debug("");
+      debug("Test getActiveUniformBlockName");
+      program = wtu.loadUniformBlockProgram(gl);
+      gl.linkProgram(program);
+      shouldBeTrue('gl.getProgramParameter(program, gl.LINK_STATUS)');
+      shouldBeEqualToString('gl.getActiveUniformBlockName(program, 0)', 'Transform');
+      shouldBeNull('gl.getActiveUniformBlockName(program, -1)');
+      wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
+      shouldBeNull('gl.getActiveUniformBlockName(program, 1)');
+      wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
+      shouldBeNull('gl.getActiveUniformBlockName(program, gl.INVALID_INDEX)');
+      wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
+      window.noLinkProgram = gl.createProgram();
+      shouldBeFalse('gl.getProgramParameter(noLinkProgram, gl.LINK_STATUS)');
+      wtu.shouldGenerateGLError(gl, gl.INVALID_OPERATION, 'gl.getActiveUniformBlockName(noLinkProgram, 0)');
+      noUniformProgram = wtu.loadStandardProgram(gl);
+      gl.linkProgram(noUniformProgram);
+      shouldBeTrue('gl.getProgramParameter(noUniformProgram, gl.LINK_STATUS)');
+      shouldBeNull('gl.getActiveUniformBlockName(noUniformProgram, -1)');
+      wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
+      shouldBeNull('gl.getActiveUniformBlockName(noUniformProgram, 0)');
+      wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
+      shouldBeNull('gl.getActiveUniformBlockName(noUniformProgram, gl.INVALID_INDEX)');
+      wtu.glErrorShouldBe(gl, gl.INVALID_VALUE);
+
+      debug("");
+      debug("Test getActiveUniformBlockParameter");
+      program = wtu.loadUniformBlockProgram(gl);
+      gl.linkProgram(program);
+      shouldBeTrue('gl.getProgramParameter(program, gl.LINK_STATUS)');
+      shouldBe('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_BINDING)', '0');
+      gl.uniformBlockBinding(program, 0, 1);
+      shouldBe('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_BINDING)', '1');
+      // The actual block data size can be bigger than 164, depending on the uniform block layout.
+      shouldBeTrue('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_DATA_SIZE) >= 164');
+      shouldBe('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_ACTIVE_UNIFORMS)', '3');
+      shouldBeTrue('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER)');
+      shouldBeFalse('gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER)');
+      let indices = gl.getActiveUniformBlockParameter(program, 0, gl.UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES);
+      for (let i = 0; i < 3; i++) {
+        if (indices[i] < 0)
+          testFailed("expected value >= 0" + " actual value for UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES for uniform index[" + i + "]:" + indices[i]);
+      }
+      validArrayForPname = new Array(
+          gl.UNIFORM_BLOCK_BINDING,
+          gl.UNIFORM_BLOCK_DATA_SIZE,
+          gl.UNIFORM_BLOCK_ACTIVE_UNIFORMS,
+          gl.UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES,
+          gl.UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER,
+          gl.UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER
+      );
+      await testInvalidArgument(
+          "getActiveUniformBlockParameter",
+          "pname",
+          validArrayForPname,
+          function(pname) {
+              return gl.getActiveUniformBlockParameter(program, 0, pname);
+          }
+      );
+  }
+
+  wtu.glErrorShouldBe(gl, gl.NO_ERROR);
+
+  finishTest();
+})();
+
+let successfullyParsed = true;
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-2d-with-image-bitmap-from-video.js b/LayoutTests/webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-2d-with-image-bitmap-from-video.js
index 6d936b5..14cf462 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-2d-with-image-bitmap-from-video.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-2d-with-image-bitmap-from-video.js
@@ -71,8 +71,8 @@
             document.body.appendChild(video);
             video.type = info.type;
             video.src = info.src;
-            wtu.startPlayingAndWaitForVideo(video, function() {
-                runImageBitmapTest(video, 1, internalFormat, pixelFormat, pixelType, gl, tiu, wtu, false);
+            wtu.startPlayingAndWaitForVideo(video, async function() {
+                await runImageBitmapTest(video, 1, internalFormat, pixelFormat, pixelType, gl, tiu, wtu, false);
                 runNextVideo();
             });
         }
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-3d-with-image-bitmap-from-video.js b/LayoutTests/webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-3d-with-image-bitmap-from-video.js
index 86d76f2..a268f7d 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-3d-with-image-bitmap-from-video.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/tests/tex-image-and-sub-image-3d-with-image-bitmap-from-video.js
@@ -71,8 +71,8 @@
             document.body.appendChild(video);
             video.type = info.type;
             video.src = info.src;
-            wtu.startPlayingAndWaitForVideo(video, function() {
-                runImageBitmapTest(video, 1, internalFormat, pixelFormat, pixelType, gl, tiu, wtu, true);
+            wtu.startPlayingAndWaitForVideo(video, async function() {
+                await runImageBitmapTest(video, 1, internalFormat, pixelFormat, pixelType, gl, tiu, wtu, true);
                 runNextVideo();
             });
         }
diff --git a/LayoutTests/webgl/resources/webgl_test_files/js/webgl-test-utils.js b/LayoutTests/webgl/resources/webgl_test_files/js/webgl-test-utils.js
index 4684ea8..9affa10 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/js/webgl-test-utils.js
+++ b/LayoutTests/webgl/resources/webgl_test_files/js/webgl-test-utils.js
@@ -1733,6 +1733,10 @@
   return glErrorShouldBeImpl(gl, glErrors, true, opt_msg);
 };
 
+const glErrorAssert = function(gl, glErrors, opt_msg) {
+  return glErrorShouldBeImpl(gl, glErrors, false, opt_msg);
+};
+
 /**
  * Tests that the given framebuffer has a specific status
  * @param {!WebGLRenderingContext} gl The WebGLRenderingContext to use.
@@ -2923,14 +2927,6 @@
   _requestAnimFrame.call(window, callback);
 };
 
-/**
- * Provides video.requestVideoFrameCallback in a cross browser way.
- * Returns a property, or undefined if unsuported.
- */
-var getRequestVidFrameCallback = function() {
-  return HTMLVideoElement.prototype["requestVideoFrameCallback"];
-};
-
 var _cancelAnimFrame;
 
 /**
@@ -3099,7 +3095,11 @@
 function dispatchPromise(fn) {
   return new Promise((fn_resolve, fn_reject) => {
     setZeroTimeout(() => {
-      fn_resolve(fn());
+      let val;
+      if (fn) {
+        val = fn();
+      }
+      fn_resolve(val);
     });
   });
 }
@@ -3132,38 +3132,30 @@
  * @param {!function(!HTMLVideoElement): void} callback Function to call when
  *        video is ready.
  */
-function startPlayingAndWaitForVideo(video, callback) {
+async function startPlayingAndWaitForVideo(video, callback) {
   if (video.error) {
     testFailed('Video failed to load: ' + video.error);
     return;
   }
 
-  video.addEventListener(
-      'error', e => { testFailed('Video playback failed: ' + e.message); },
-      true);
-
-  var rvfc = getRequestVidFrameCallback();
-  if (rvfc === undefined) {
-    var timeWatcher = function() {
-      if (video.currentTime > 0) {
-        callback(video);
-      } else {
-        requestAnimFrame.call(window, timeWatcher);
-      }
-    };
-
-    timeWatcher();
-  } else {
-    // Calls video.requestVideoFrameCallback(_ => { callback(video) })
-    rvfc.call(video, _ => { callback(video) });
-  }
-
   video.loop = true;
   video.muted = true;
   // See whether setting the preload flag de-flakes video-related tests.
   video.preload = 'auto';
-  video.play();
-};
+
+  try {
+    await video.play();
+  } catch (e) {
+    testFailed('video.play failed: ' + e);
+    return;
+  }
+
+  if (video.requestVideoFrameCallback) {
+    await new Promise(go => video.requestVideoFrameCallback(go));
+  }
+
+  callback(video);
+}
 
 var getHost = function(url) {
   url = url.replace("\\", "/");
@@ -3453,6 +3445,7 @@
   getAttribMap: getAttribMap,
   getUniformMap: getUniformMap,
   glEnumToString: glEnumToString,
+  glErrorAssert: glErrorAssert,
   glErrorShouldBe: glErrorShouldBe,
   glTypeToTypedArrayType: glTypeToTypedArrayType,
   hasAttributeCaseInsensitive: hasAttributeCaseInsensitive,
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/red-green.webmvp8.webm b/LayoutTests/webgl/resources/webgl_test_files/resources/red-green.webmvp8.webm
index 1d9d603..fde59a1 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/red-green.webmvp8.webm
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/red-green.webmvp8.webm
Binary files differ
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-0.mp4 b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-0.mp4
index ae7eef1..8f47100 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-0.mp4
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-0.mp4
Binary files differ
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-0.vp9.mp4 b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-0.vp9.mp4
index ec4990e..bae85cd 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-0.vp9.mp4
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-0.vp9.mp4
Binary files differ
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-180.mp4 b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-180.mp4
index 5a4d6e5..7c5fe8e 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-180.mp4
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-180.mp4
Binary files differ
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-180.vp9.mp4 b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-180.vp9.mp4
index 9ee8608..6bb57d5 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-180.vp9.mp4
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-180.vp9.mp4
Binary files differ
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-270.mp4 b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-270.mp4
index 213418c..5dfb886 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-270.mp4
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-270.mp4
Binary files differ
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-270.vp9.mp4 b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-270.vp9.mp4
index 060332a..d945c3b 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-270.vp9.mp4
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-270.vp9.mp4
Binary files differ
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-90.mp4 b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-90.mp4
index 279f09b..41e3c36 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-90.mp4
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-90.mp4
Binary files differ
diff --git a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-90.vp9.mp4 b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-90.vp9.mp4
index 3a66083..b4a4be9 100644
--- a/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-90.vp9.mp4
+++ b/LayoutTests/webgl/resources/webgl_test_files/resources/video-rotation-90.vp9.mp4
Binary files differ
diff --git a/Tools/ChangeLog b/Tools/ChangeLog
index a35b268..32901c0 100644
--- a/Tools/ChangeLog
+++ b/Tools/ChangeLog
@@ -1,3 +1,19 @@
+2022-01-27  Kimmo Kinnunen  <kkinnunen@apple.com>
+
+        Update WebGL conformance test suite to 2022-01-12
+        https://bugs.webkit.org/show_bug.cgi?id=235563
+
+        Reviewed by Dean Jackson.
+
+        Add functionality to Tools/Scripts/update-webgl-conformance-tests:
+         - Copy http-only tests to http/tests/webgl
+         - Add template to js-test-pre.js
+
+        * Scripts/webkitpy/update_webgl_conformance_tests_lib/js-test-pre-template.js: Renamed from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js.
+        * Scripts/webkitpy/update_webgl_conformance_tests_lib/main.py:
+        (_copy_tree):
+        (main):
+
 2022-01-26  ChangSeok Oh  <changseok@webkit.org>
 
         [GTK] WTR: Native HTML form validation popover is not supported
diff --git a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js b/Tools/Scripts/webkitpy/update_webgl_conformance_tests_lib/js-test-pre-template.js
similarity index 88%
copy from LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js
copy to Tools/Scripts/webkitpy/update_webgl_conformance_tests_lib/js-test-pre-template.js
index 184956e..ffd42e5 100644
--- a/LayoutTests/http/tests/webgl/1.0.2/resources/webgl_test_files/resources/js-test-pre.js
+++ b/Tools/Scripts/webkitpy/update_webgl_conformance_tests_lib/js-test-pre-template.js
@@ -24,7 +24,7 @@
 (function() {
   var testHarnessInitialized = false;
 
-  var initNonKhronosFramework = function(waitUntilDone) {
+  var initNonKhronosFramework = function() {
     if (testHarnessInitialized) {
       return;
     }
@@ -58,12 +58,8 @@
     /* -- end platform specific code --*/
   }
 
-  this.initTestingHarnessWaitUntilDone = function() {
-    initNonKhronosFramework(true);
-  }
-
   this.initTestingHarness = function() {
-    initNonKhronosFramework(false);
+    initNonKhronosFramework();
   }
 }());
 
@@ -89,6 +85,19 @@
   }
 }
 
+function _logToConsole(msg)
+{
+    if (window.console)
+      window.console.log(msg);
+}
+
+var _jsTestPreVerboseLogging = false;
+
+function enableJSTestPreVerboseLogging()
+{
+    _jsTestPreVerboseLogging = true;
+}
+
 function description(msg)
 {
     initTestingHarness();
@@ -103,13 +112,24 @@
         description.replaceChild(span, description.firstChild);
     else
         description.appendChild(span);
+    if (_jsTestPreVerboseLogging) {
+        _logToConsole(msg);
+    }
+}
+
+function _addSpan(contents)
+{
+    var span = document.createElement("span");
+    document.getElementById("console").appendChild(span); // insert it first so XHTML knows the namespace
+    span.innerHTML = contents + '<br />';
 }
 
 function debug(msg)
 {
-    var span = document.createElement("span");
-    document.getElementById("console").appendChild(span); // insert it first so XHTML knows the namespace
-    span.innerHTML = msg + '<br />';
+    _addSpan(msg);
+    if (_jsTestPreVerboseLogging) {
+        _logToConsole(msg);
+    }
 }
 
 function escapeHTML(text)
@@ -120,13 +140,17 @@
 function testPassed(msg)
 {
     reportTestResultsToHarness(true, msg);
-    debug('<span><span class="pass">PASS</span> ' + escapeHTML(msg) + '</span>');
+    _addSpan('<span><span class="pass">PASS</span> ' + escapeHTML(msg) + '</span>');
+    if (_jsTestPreVerboseLogging) {
+        _logToConsole('PASS ' + msg);
+    }
 }
 
 function testFailed(msg)
 {
     reportTestResultsToHarness(false, msg);
-    debug('<span><span class="fail">FAIL</span> ' + escapeHTML(msg) + '</span>');
+    _addSpan('<span><span class="fail">FAIL</span> ' + escapeHTML(msg) + '</span>');
+    _logToConsole('FAIL ' + msg);
 }
 
 function areArraysEqual(_a, _b)
@@ -410,21 +434,32 @@
 }
 
 function shouldBeType(_a, _type) {
-	var exception;
-	var _av;
-	try {
-		_av = eval(_a);
-	} catch (e) {
-		exception = e;
-	}
+    var exception;
+    var _av;
+    try {
+        _av = eval(_a);
+    } catch (e) {
+        exception = e;
+    }
 
-	var _typev = eval(_type);
+    var _typev = eval(_type);
 
-	if (_av instanceof _typev) {
-		testPassed(_a + " is an instance of " + _type);
-	} else {
-		testFailed(_a + " is not an instance of " + _type);
-	}
+    if(_typev === Number){
+        if(_av instanceof Number){
+            testPassed(_a + " is an instance of Number");
+        }
+        else if(typeof(_av) === 'number'){
+            testPassed(_a + " is an instance of Number");
+        }
+        else{
+            testFailed(_a + " is not an instance of Number");
+        }
+    }
+    else if (_av instanceof _typev) {
+        testPassed(_a + " is an instance of " + _type);
+    } else {
+        testFailed(_a + " is not an instance of " + _type);
+    }
 }
 
 function assertMsg(assertion, msg) {
@@ -467,7 +502,6 @@
 function finishTest() {
   successfullyParsed = true;
   var epilogue = document.createElement("script");
-
   var basePath = "";
   var expectedBase = "js-test-pre.js";
   var scripts = document.getElementsByTagName('script');
diff --git a/Tools/Scripts/webkitpy/update_webgl_conformance_tests_lib/main.py b/Tools/Scripts/webkitpy/update_webgl_conformance_tests_lib/main.py
index c610563..59a0c7c 100755
--- a/Tools/Scripts/webkitpy/update_webgl_conformance_tests_lib/main.py
+++ b/Tools/Scripts/webkitpy/update_webgl_conformance_tests_lib/main.py
@@ -34,8 +34,8 @@
    cd ~/temp
    git clone git://github.com/KhronosGroup/WebGL.git
    mkdir backup
-   mv ~/WebKit/LayoutTests/webgl/{1.0.x,2.0.y,resources/webgl_test_files} backup
-   generate-webgl-tests ~/temp/WebGL
+   mv ~/WebKit/LayoutTests/{http/,}webgl/{1.0.x,2.0.y,resources/webgl_test_files} backup
+   update-webgl-conformance-tests -c ~/temp/WebGL
    run-webkit-tests --debug --webgl --order=random webgl
    run-webkit-tests --release --webgl --order=random webgl
    check-for-duplicated-platform-test-results -n 2>&1 | grep webgl
@@ -64,6 +64,8 @@
 
 _use_verbose_output = False
 
+_clean_target_dirs = False
+
 _IgnoredFilenameMatcher = Callable[[Path], bool]
 
 
@@ -84,7 +86,7 @@
     return match_rules
 
 
-_conformance_patterns = _make_ignore_fnmatch_rule_matcher(
+_file_patterns = _make_ignore_fnmatch_rule_matcher(
     [
         ".git",
         "*.pyc",
@@ -104,6 +106,31 @@
         "*/deqp/temp_externs*",
         "*/deqp/test-webgl2.js",
         "*/deqp/test-webgl2.sh",
+        "*/textures/misc/origin-clean-conformance-offscreencanvas.html",
+        "*/textures/misc/origin-clean-conformance.html",
+        "*/more/functions/readPixelsBadArgs.html",
+        "*/more/functions/texImage2DHTML.html",
+        "*/more/functions/texSubImage2DHTML.html",
+    ]
+)
+
+_http_file_patterns = _make_ignore_fnmatch_rule_matcher(
+    [
+        "*",
+        ("*/textures/misc/origin-clean-conformance-offscreencanvas.html", ),
+        ("*/textures/misc/origin-clean-conformance.html", ),
+        ("*/more/functions/readPixelsBadArgs.html", ),
+        ("*/more/functions/texImage2DHTML.html", ),
+        ("*/more/functions/texSubImage2DHTML.html", ),
+        ("*/more/unit.css", ),
+        ("*/more/unit.js", ),
+        ("*/more/util.js", ),
+        ("*/js/js-test-post.js", ),
+        ("*/js/js-test-pre.js", ),
+        ("*/js/webgl-test-utils.js", ),
+        ("*/resources/js-test-style.css", ),
+        ("*/resources/opengl_logo.jpg", ),
+        ("*/resources/thunderbird-logo-64x64.png", ),
     ]
 )
 
@@ -120,7 +147,7 @@
         else:
             if ignore is not None and ignore(src_name):
                 if _use_verbose_output:
-                    print("Ignoring: %s" % (src_name))
+                    print("Ignoring: %s, matches ignore filter" % (src_name))
                 continue
             if _use_verbose_output:
                 print("Copying: %s -> %s" % (src_name, dst_name))
@@ -187,6 +214,8 @@
     target_dir: Path,
 ):
     target_test_files_dir = target_dir / "resources" / "webgl_test_files"
+    if _clean_target_dirs:
+        shutil.rmtree(target_test_files_dir)
     _copy_tree(source_tests_dir, target_test_files_dir, source_patterns)
 
 
@@ -203,6 +232,9 @@
     target_js_test_harness = target_dir / "resources" / "webkit-webgl-test-harness.js"
     target_js_test_harness.parent.mkdir(parents=True, exist_ok=True)
     shutil.copyfile(source_js_test_harness, target_js_test_harness)
+    source_js_test_harness = _tool_dir / "js-test-pre-template.js"
+    target_js_test_harness = target_dir / "resources" / "js-test-pre.js"
+    shutil.copyfile(source_js_test_harness, target_js_test_harness)
 
     test_template = (_tool_dir / "webgl-test-driver-template.html").read_text()
     expectation_template = (_tool_dir / "webgl-expectation-template.txt").read_text()
@@ -210,6 +242,9 @@
     tests = _parse_webgl_tests(source_tests_dir, (source_tests_dir / "00_test_list.txt"), suite_version, suite_version)
 
     target_tests_dir = target_dir / target_version_name
+    if _clean_target_dirs:
+        shutil.rmtree(target_tests_dir)
+
     for test_path in _filter_webgl_test_paths_for_suite_version(tests, suite_version):
         target_test = target_tests_dir / test_path
         target_test_impl = target_test_files_dir / test_path
@@ -252,6 +287,7 @@
 def main():
     parser = argparse.ArgumentParser(description=__doc__, formatter_class=argparse.RawTextHelpFormatter)
     parser.add_argument("-v", "--verbose", action="store_true", help="print verbose output.")
+    parser.add_argument("-c", "--clean-target-dirs", action="store_true", help="remove all files from target subdirectories before updating them.")
     parser.add_argument("webgl_repository", help="path to WebGL conformance test repository root.")
     parser.add_argument(
         "-l",
@@ -263,14 +299,23 @@
     options = parser.parse_args()
     global _use_verbose_output
     _use_verbose_output = options.verbose or False
+    global _clean_target_dirs
+    _clean_target_dirs = options.clean_target_dirs or False
     source_dir = Path(options.webgl_repository)
     target_dir = Path(options.layout_tests_dir) / "webgl"
 
-    _copy_webgl_test_files(source_tests_dir=source_dir / "sdk" / "tests", source_patterns=_conformance_patterns, target_dir=target_dir)
+    _copy_webgl_test_files(source_tests_dir=source_dir / "sdk" / "tests", source_patterns=_file_patterns, target_dir=target_dir)
     _generate_webkit_webgl_tests(source_tests_dir=source_dir / "sdk" / "tests", suite_version=Version("1.0.4"), use_webgl2_context=False, target_dir=target_dir, target_version_name="1.0.x")
     _generate_webkit_webgl_tests(source_tests_dir=source_dir / "sdk" / "tests", suite_version=Version("2.0.1"), use_webgl2_context=True, target_dir=target_dir, target_version_name="2.0.y")
-    layout_tests_dir = Path(options.layout_tests_dir)
 
+    if _use_verbose_output:
+        print("Updating http tests")
+    http_target_dir = Path(options.layout_tests_dir) / "http" / "tests" / "webgl"
+    _copy_webgl_test_files(source_tests_dir=source_dir / "sdk" / "tests", source_patterns=_http_file_patterns, target_dir=http_target_dir)
+    _generate_webkit_webgl_tests(source_tests_dir=source_dir / "sdk" / "tests", suite_version=Version("1.0.4"), use_webgl2_context=False, target_dir=http_target_dir, target_version_name="1.0.x")
+    _generate_webkit_webgl_tests(source_tests_dir=source_dir / "sdk" / "tests", suite_version=Version("2.0.1"), use_webgl2_context=True, target_dir=http_target_dir, target_version_name="2.0.y")
+
+    layout_tests_dir = Path(options.layout_tests_dir)
     old_expectations = _find_expectations_for_removed_tests(layout_tests_dir)
     old_expectations = [e for e in old_expectations if "webgl" in str(e)]
     if old_expectations: