Bug 734423 - Upgrade WebGL conformance test suite to 1.0.1 in-principle-final (r17063) - no review
authorBenoit Jacob <bjacob@mozilla.com>
Mon, 26 Mar 2012 15:10:40 -0400
changeset 93657 f9585cefcf568dbc2a6ce81f16a2048365af7ed2
parent 93656 331ff4b8e009b27dda1da7ed9ebf4dc965730d55
child 93658 acb20ce6ec61a88304d1b371cb084016862afdca
push id886
push userlsblakk@mozilla.com
push dateMon, 04 Jun 2012 19:57:52 +0000
treeherdermozilla-beta@bbd8d5efd6d1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs734423
milestone14.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 734423 - Upgrade WebGL conformance test suite to 1.0.1 in-principle-final (r17063) - no review 1.0.1 is in principle a done thing. This is also the occasion to do a clean upgrade, by rm and cp, instead of applying a diff. Upstream: https://cvs.khronos.org/svn/repos/registry/trunk/public/webgl/conformance-suites/1.0.1/
content/canvas/test/webgl/00_test_list.txt
content/canvas/test/webgl/README.mozilla
content/canvas/test/webgl/README.txt
content/canvas/test/webgl/conformance/00_readme.txt
content/canvas/test/webgl/conformance/LICENSE_CHROMIUM
content/canvas/test/webgl/conformance/attribs/gl-vertex-attrib-zero-issues.html
content/canvas/test/webgl/conformance/canvas/buffer-offscreen-test.html
content/canvas/test/webgl/conformance/canvas/buffer-preserve-test.html
content/canvas/test/webgl/conformance/canvas/drawingbuffer-static-canvas-test.html
content/canvas/test/webgl/conformance/canvas/drawingbuffer-test.html
content/canvas/test/webgl/conformance/context/constants.html
content/canvas/test/webgl/conformance/context/context-attribute-preserve-drawing-buffer.html
content/canvas/test/webgl/conformance/extensions/00_test_list.txt
content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgb.dxt1.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgba.dxt1.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgba.dxt3.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgba.dxt5.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgba.raw.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgb.dxt1.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.dxt1.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.dxt3.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.dxt5.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.pvrtc4bpp.js
content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.raw.js
content/canvas/test/webgl/conformance/extensions/oes-standard-derivatives.html
content/canvas/test/webgl/conformance/extensions/oes-texture-float.html
content/canvas/test/webgl/conformance/extensions/webgl-compressed-texture-s3tc.html
content/canvas/test/webgl/conformance/extensions/webgl-debug-renderer-info.html
content/canvas/test/webgl/conformance/extensions/webgl-debug-shaders.html
content/canvas/test/webgl/conformance/extensions/webgl-experimental-compressed-textures.html
content/canvas/test/webgl/conformance/glsl/functions/glsl-function-acos.html
content/canvas/test/webgl/conformance/glsl/functions/glsl-function-asin.html
content/canvas/test/webgl/conformance/glsl/functions/glsl-function-atan-xy.html
content/canvas/test/webgl/conformance/glsl/functions/glsl-function-atan.html
content/canvas/test/webgl/conformance/glsl/functions/glsl-function-cos.html
content/canvas/test/webgl/conformance/glsl/functions/glsl-function-sin.html
content/canvas/test/webgl/conformance/glsl/implicit/add_int_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_ivec2_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_ivec3_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/add_ivec4_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/assign_int_to_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec2_to_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec3_to_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec4_to_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/construct_struct.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_int_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec2_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec3_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec4_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/equal_int_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec2_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec3_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec4_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/function_int_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/function_ivec2_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/function_ivec3_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/function_ivec4_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/greater_than.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/greater_than_equal.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/less_than.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/less_than_equal.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec2_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec3_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec4_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/not_equal_int_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec2_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec3_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec4_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec2_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec3_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec4_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/ternary_int_float.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec2_vec2.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec3_vec3.vert.html
content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec4_vec4.vert.html
content/canvas/test/webgl/conformance/glsl/misc/00_test_list.txt
content/canvas/test/webgl/conformance/glsl/misc/attrib-location-length-limits.html
content/canvas/test/webgl/conformance/glsl/misc/embedded-struct-definitions-forbidden.html
content/canvas/test/webgl/conformance/glsl/misc/glsl-function-nodes.html
content/canvas/test/webgl/conformance/glsl/misc/glsl-vertex-branch.html
content/canvas/test/webgl/conformance/glsl/misc/non-ascii-comments.vert.html
content/canvas/test/webgl/conformance/glsl/misc/non-ascii.vert.html
content/canvas/test/webgl/conformance/glsl/misc/re-compile-re-link.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-256-character-identifier.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-257-character-identifier.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-_webgl-identifier.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-arbitrary-indexing.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-arbitrary-indexing.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-attrib-array.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-attrib-struct.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-clipvertex.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-comma-assignment.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-comma-conditional-assignment.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-conditional-scoping.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-default-precision.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-default-precision.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-define-line-continuation.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-dfdx-no-ext.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-dfdx.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-do-scoping.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-error-directive.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-explicit-int-cast.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-float-return-value.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-for-loop.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-for-scoping.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-frag-depth.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-function-recursion.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-function-scoped-struct.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-functional-scoping.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-glcolor.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-gles-1.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-gles-symbol.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-glprojectionmatrix.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-hex-int-constant-macro.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-implicit-vec3-to-vec4-cast.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-include.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-int-return-value.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-invalid-identifier.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec2-return-value.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec3-return-value.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec4-return-value.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-limited-indexing.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-line-directive.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-long-line.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-non-ascii-error.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-precision.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-quoted-error.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-undefined-preprocessor-symbol.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-uniform-in-loop-condition.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec2-return-value.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec3-return-value.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec4-return-value.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec4-vec3-vec4-conditional.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-100.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-100.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-120.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-130.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-with-webgl-identifier.vert.html
content/canvas/test/webgl/conformance/glsl/misc/shader-without-precision.frag.html
content/canvas/test/webgl/conformance/glsl/misc/shared.html
content/canvas/test/webgl/conformance/glsl/misc/struct-nesting-exceeds-maximum.html
content/canvas/test/webgl/conformance/glsl/misc/struct-nesting-under-maximum.html
content/canvas/test/webgl/conformance/glsl/misc/uniform-location-length-limits.html
content/canvas/test/webgl/conformance/glsl/reserved/_webgl_field.vert.html
content/canvas/test/webgl/conformance/glsl/reserved/_webgl_function.vert.html
content/canvas/test/webgl/conformance/glsl/reserved/_webgl_struct.vert.html
content/canvas/test/webgl/conformance/glsl/reserved/_webgl_variable.vert.html
content/canvas/test/webgl/conformance/glsl/reserved/webgl_field.vert.html
content/canvas/test/webgl/conformance/glsl/reserved/webgl_function.vert.html
content/canvas/test/webgl/conformance/glsl/reserved/webgl_struct.vert.html
content/canvas/test/webgl/conformance/glsl/reserved/webgl_variable.vert.html
content/canvas/test/webgl/conformance/glsl/samplers/glsl-function-texture2d-bias.html
content/canvas/test/webgl/conformance/glsl/samplers/glsl-function-texture2dlod.html
content/canvas/test/webgl/conformance/glsl/samplers/glsl-function-texture2dproj.html
content/canvas/test/webgl/conformance/limits/gl-max-texture-dimensions.html
content/canvas/test/webgl/conformance/limits/gl-min-attribs.html
content/canvas/test/webgl/conformance/limits/gl-min-textures.html
content/canvas/test/webgl/conformance/limits/gl-min-uniforms.html
content/canvas/test/webgl/conformance/misc/delayed-drawing.html
content/canvas/test/webgl/conformance/misc/functions-returning-strings.html
content/canvas/test/webgl/conformance/misc/instanceof-test.html
content/canvas/test/webgl/conformance/misc/is-object.html
content/canvas/test/webgl/conformance/misc/shader-precision-format.html
content/canvas/test/webgl/conformance/misc/uninitialized-test.html
content/canvas/test/webgl/conformance/more/conformance/constants.html
content/canvas/test/webgl/conformance/more/conformance/quickCheckAPI.html
content/canvas/test/webgl/conformance/more/conformance/quickCheckAPI.js
content/canvas/test/webgl/conformance/more/util.js
content/canvas/test/webgl/conformance/programs/gl-get-active-attribute.html
content/canvas/test/webgl/conformance/programs/gl-get-active-uniform.html
content/canvas/test/webgl/conformance/programs/gl-getshadersource.html
content/canvas/test/webgl/conformance/programs/invalid-UTF-16.html
content/canvas/test/webgl/conformance/renderbuffers/renderbuffer-initialization.html
content/canvas/test/webgl/conformance/rendering/gl-clear.html
content/canvas/test/webgl/conformance/resources/glsl-conformance-test.js
content/canvas/test/webgl/conformance/resources/glsl-generator.js
content/canvas/test/webgl/conformance/resources/webgl-test-utils.js
content/canvas/test/webgl/conformance/resources/webgl-test.js
content/canvas/test/webgl/conformance/shaders/00_shaders.txt
content/canvas/test/webgl/conformance/shaders/00_test_list.txt
content/canvas/test/webgl/conformance/shaders/glsl-features/00_test_list.txt
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec2-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec2-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec2.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec2.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec3-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec3-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec3.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec3.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec4-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec4-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec4.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/abs-vec4.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/abs.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/abs.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/base.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/base.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec2-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec2-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec2.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec2.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec3-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec3-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec3.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec3.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec4-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec4-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec4.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil-vec4.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/ceil.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec2-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec2-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec2.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec2.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec3-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec3-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec3.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec3.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec4-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec4-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec4.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/floor-vec4.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/floor.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/floor.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec2-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec2-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec2.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec2.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec3-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec3-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec3.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec3.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec4-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec4-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec4.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/fract-vec4.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/fract.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/fract.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec2-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec2-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec2.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec2.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec3-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec3-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec3.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec3.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec4-ref.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec4-ref.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec4.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/sign-vec4.vert
content/canvas/test/webgl/conformance/shaders/glsl-features/sign.frag
content/canvas/test/webgl/conformance/shaders/glsl-features/sign.vert
content/canvas/test/webgl/conformance/shaders/implicit/00_shaders.txt
content/canvas/test/webgl/conformance/shaders/implicit/add_int_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_int_mat2.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_int_mat3.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_int_mat4.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_int_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_int_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_int_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_ivec2_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_ivec3_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/add_ivec4_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/assign_int_to_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/assign_ivec2_to_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/assign_ivec3_to_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/assign_ivec4_to_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/construct_struct.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_int_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_int_mat2.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_int_mat3.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_int_mat4.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_int_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_int_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_int_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_ivec2_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_ivec3_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/divide_ivec4_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/equal_int_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/equal_ivec2_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/equal_ivec3_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/equal_ivec4_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/function_int_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/function_ivec2_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/function_ivec3_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/function_ivec4_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/greater_than.vert
content/canvas/test/webgl/conformance/shaders/implicit/greater_than_equal.vert
content/canvas/test/webgl/conformance/shaders/implicit/less_than.vert
content/canvas/test/webgl/conformance/shaders/implicit/less_than_equal.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_int_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_int_mat2.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_int_mat3.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_int_mat4.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_int_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_int_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_int_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_ivec2_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_ivec3_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/multiply_ivec4_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/not_equal_int_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/not_equal_ivec2_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/not_equal_ivec3_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/not_equal_ivec4_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_int_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_int_mat2.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_int_mat3.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_int_mat4.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_int_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_int_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_int_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_ivec2_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_ivec3_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/subtract_ivec4_vec4.vert
content/canvas/test/webgl/conformance/shaders/implicit/ternary_int_float.vert
content/canvas/test/webgl/conformance/shaders/implicit/ternary_ivec2_vec2.vert
content/canvas/test/webgl/conformance/shaders/implicit/ternary_ivec3_vec3.vert
content/canvas/test/webgl/conformance/shaders/implicit/ternary_ivec4_vec4.vert
content/canvas/test/webgl/conformance/shaders/misc/00_shaders.txt
content/canvas/test/webgl/conformance/shaders/misc/non-ascii-comments.vert
content/canvas/test/webgl/conformance/shaders/misc/non-ascii.vert
content/canvas/test/webgl/conformance/shaders/misc/shared-a.frag
content/canvas/test/webgl/conformance/shaders/misc/shared-b.frag
content/canvas/test/webgl/conformance/shaders/misc/shared.vert
content/canvas/test/webgl/conformance/shaders/reserved/00_shaders.txt
content/canvas/test/webgl/conformance/shaders/reserved/_webgl_field.vert
content/canvas/test/webgl/conformance/shaders/reserved/_webgl_function.vert
content/canvas/test/webgl/conformance/shaders/reserved/_webgl_struct.vert
content/canvas/test/webgl/conformance/shaders/reserved/_webgl_variable.vert
content/canvas/test/webgl/conformance/shaders/reserved/webgl_field.vert
content/canvas/test/webgl/conformance/shaders/reserved/webgl_function.vert
content/canvas/test/webgl/conformance/shaders/reserved/webgl_struct.vert
content/canvas/test/webgl/conformance/shaders/reserved/webgl_variable.vert
content/canvas/test/webgl/conformance/state/gl-get-calls.html
content/canvas/test/webgl/conformance/state/gl-geterror.html
content/canvas/test/webgl/conformance/textures/00_test_list.txt
content/canvas/test/webgl/conformance/textures/compressed-tex-image.html
content/canvas/test/webgl/conformance/textures/gl-teximage.html
content/canvas/test/webgl/conformance/textures/tex-image-and-sub-image-2d-with-array-buffer-view.html
content/canvas/test/webgl/conformance/textures/tex-image-and-sub-image-2d-with-image.html
content/canvas/test/webgl/conformance/textures/tex-image-and-sub-image-2d-with-video.html
content/canvas/test/webgl/conformance/textures/tex-sub-image-2d-bad-args.html
content/canvas/test/webgl/conformance/textures/tex-sub-image-2d.html
content/canvas/test/webgl/conformance/textures/texture-active-bind.html
content/canvas/test/webgl/conformance/textures/texture-clear.html
content/canvas/test/webgl/conformance/textures/texture-mips.html
content/canvas/test/webgl/conformance/textures/texture-npot.html
content/canvas/test/webgl/conformance/textures/texture-size-cube-maps.html
content/canvas/test/webgl/conformance/textures/texture-size.html
content/canvas/test/webgl/conformance/textures/texture-transparent-pixels-initialized.html
content/canvas/test/webgl/conformance/uniforms/uniform-samplers-test.html
content/canvas/test/webgl/dont-load-image-from-internet.patch
content/canvas/test/webgl/ext-texture-filter-anisotropic.patch
content/canvas/test/webgl/extra/offscreen-issue.html
content/canvas/test/webgl/extra/out-of-bounds-uniform-array-access.html
content/canvas/test/webgl/extra/out-of-memory.html
content/canvas/test/webgl/failing_tests_linux.txt
content/canvas/test/webgl/failing_tests_mac.txt
content/canvas/test/webgl/failing_tests_windows.txt
content/canvas/test/webgl/log-more-info-about-test-failures.patch
content/canvas/test/webgl/reference-cycle-test.patch
content/canvas/test/webgl/remove-uniqueObjectTest.patch
content/canvas/test/webgl/resources/webgl-logo.png
content/canvas/test/webgl/webgl-conformance-tests.html
--- a/content/canvas/test/webgl/00_test_list.txt
+++ b/content/canvas/test/webgl/00_test_list.txt
@@ -1,6 +1,6 @@
-// files that end in .txt list other tests
-// other lines are assumed to be .html files
-
-conformance/00_test_list.txt
-conformance/more/00_test_list.txt
-
+// files that end in .txt list other tests
+// other lines are assumed to be .html files
+
+conformance/00_test_list.txt
+conformance/more/00_test_list.txt
+
--- a/content/canvas/test/webgl/README.mozilla
+++ b/content/canvas/test/webgl/README.mozilla
@@ -1,14 +1,28 @@
-This is a local copy of the WebGL conformance suite, SVN revision 16776
+This is a local copy of the WebGL conformance suite, version 1.0.1, SVN revision 17036 (on the 1.0.1 branch, not on trunk)
+
+The canonical location for this 1.0.1 test suite is:
 
-The canonical location for this testsuite is:
+  https://cvs.khronos.org/svn/repos/registry/trunk/public/webgl/conformance-suites/1.0.1
+
+The canonical location of the development tree is:
 
   https://cvs.khronos.org/svn/repos/registry/trunk/public/webgl/sdk/tests
 
 All files and directories in this directory, with the exceptions listed below, come from
 upstream and should not be modified without corresponding upstream fixes and/or a
 patch file in this directory. The exceptions (the Mozilla-specific files) are:
  * README.mozilla (this file)
  * failing_tests_*.txt
  * Makefile.in
  * *.patch files, if any
 
+How to do an update:
+ 1. unapply local patches (the .patch files here)
+ 2. perform the update:
+   * method A: apply diff with new version
+   * method B: erase all files here, import copy of new version.
+ 3. edit CONFORMANCE_TEST_VERSION in test_webgl_conformance_test_suite.html. That's what
+    determines with tests to run, as some tests are only enabled in some not-yet-released
+    version.
+ 4. reapply local patches.
+ 5. update this readme and the .patch files
--- a/content/canvas/test/webgl/README.txt
+++ b/content/canvas/test/webgl/README.txt
@@ -1,28 +1,28 @@
-Welcome to the WebGL Conformance Test Suite
-===========================================
-
-This is the initial release of the WebGL conformance test suite.
-
-NOTE TO USERS: Unless you are a WebGL implementor, there is no need to submit
-a conformance result using this process.  Should you discover bugs in your
-browser's WebGL implementation, either via this test suite or otherwise,
-please report them to your browser vendor's bug tracking system.
-
-FOR WEBGL IMPLEMENTORS: Please follow the isntructions below to create
-a formal conformance submission.'
-
-1) Open webgl-conformance-tests.html in your target browser
-
-2) Press the "run tests" button
-
-3) At the end of the run, press "display text summary"
-
-4) Verify that the User Agent and WebGL renderer strings identify your browser and target correctly.
-
-5) Copy the contents of the text summary (starting with "WebGL Conformance Test Results") and send via email to
-   --- NEED ADDRESS HERE --- @khronos.org
-
-
-- Version 1.0.0
-- February 24, 2011
-
+Welcome to the WebGL Conformance Test Suite
+===========================================
+
+This is the initial release of the WebGL conformance test suite.
+
+NOTE TO USERS: Unless you are a WebGL implementor, there is no need to submit
+a conformance result using this process.  Should you discover bugs in your
+browser's WebGL implementation, either via this test suite or otherwise,
+please report them to your browser vendor's bug tracking system.
+
+FOR WEBGL IMPLEMENTORS: Please follow the isntructions below to create
+a formal conformance submission.'
+
+1) Open webgl-conformance-tests.html in your target browser
+
+2) Press the "run tests" button
+
+3) At the end of the run, press "display text summary"
+
+4) Verify that the User Agent and WebGL renderer strings identify your browser and target correctly.
+
+5) Copy the contents of the text summary (starting with "WebGL Conformance Test Results") and send via email to
+   --- NEED ADDRESS HERE --- @khronos.org
+
+
+- Version 1.0.0
+- February 24, 2011
+
--- a/content/canvas/test/webgl/conformance/00_readme.txt
+++ b/content/canvas/test/webgl/conformance/00_readme.txt
@@ -1,13 +1,13 @@
-This file "00_test_list.txt" lists which files the test harness should run.
-
-If you add new tests you can update it with
-
-on windows
-
-   dir /b *.html >00_test_list.txt
-
-on OSX / Linux
-
-   ls -1 *.html >00_test_list.txt
-
-
+This file "00_test_list.txt" lists which files the test harness should run.
+
+If you add new tests you can update it with
+
+on windows
+
+   dir /b *.html >00_test_list.txt
+
+on OSX / Linux
+
+   ls -1 *.html >00_test_list.txt
+
+
new file mode 100644
--- /dev/null
+++ b/content/canvas/test/webgl/conformance/LICENSE_CHROMIUM
@@ -0,0 +1,30 @@
+// For files copyrighted by the Chromium Authors, the following
+// license applies:
+
+// Copyright (c) 2012 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.
--- a/content/canvas/test/webgl/conformance/attribs/gl-vertex-attrib-zero-issues.html
+++ b/content/canvas/test/webgl/conformance/attribs/gl-vertex-attrib-zero-issues.html
@@ -32,25 +32,21 @@
         gl_FragColor = vec4(0.0,0.0,0.0,0.0);
     }
 </script>
 
 <script>
 description("Test some of the issues of the difference between attrib 0 on OpenGL vs WebGL");
 debug("");
 var wtu = WebGLTestUtils;
-var canvas = document.getElementById("example");
-var gl = wtu.create3DContext(canvas);
+var gl = wtu.create3DContext("example");
 
 function setup(numVerts, attribIndex) {
   var program = wtu.setupProgram(
-      gl,
-      [wtu.loadShaderFromScript(gl, 'vshader', gl.VERTEX_SHADER),
-       wtu.loadShaderFromScript(gl, 'fshader', gl.FRAGMENT_SHADER)],
-      ['vPosition'], [attribIndex]);
+      gl, ['vshader', 'fshader'], ['vPosition'], [attribIndex]);
   // draw with something on attrib zero with a small number of vertices
   var vertexObject = gl.createBuffer();
   g_program = program;
   g_attribLocation = attribIndex;
   shouldBe("g_attribLocation", "gl.getAttribLocation(g_program, 'vPosition')");
   gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
   gl.bufferData(
       gl.ARRAY_BUFFER, new Float32Array(numVerts * 3), gl.STATIC_DRAW);
--- a/content/canvas/test/webgl/conformance/canvas/buffer-offscreen-test.html
+++ b/content/canvas/test/webgl/conformance/canvas/buffer-offscreen-test.html
@@ -48,19 +48,18 @@ function timer() {
     }
 }
 
 function go() {
     description("This test ensures WebGL implementations correctly clear the drawing buffer on composite if preserveDrawingBuffer is false.");
 
     debug("");
 
-    gl1 = create3DContext(document.getElementById("c"));
-    c2 = document.createElement('canvas');
-    gl2 = create3DContext(c2);
+    gl1 = wtu.create3DContext("c");
+    gl2 = create3DContext();
     shouldBeTrue("gl1 != null");
     shouldBeTrue("gl2 != null");
 
     shouldBeTrue('gl1.getContextAttributes().preserveDrawingBuffer == false');
     shouldBeTrue('gl2.getContextAttributes().preserveDrawingBuffer == false');
 
     function init(gl) {
         gl.clearColor(1, 0, 0, 1);
--- a/content/canvas/test/webgl/conformance/canvas/buffer-preserve-test.html
+++ b/content/canvas/test/webgl/conformance/canvas/buffer-preserve-test.html
@@ -54,17 +54,17 @@ function timer() {
     setTimeout(timer, 500);
 }
 
 function go() {
     description("This test ensures WebGL implementations correctly clear the drawing buffer on composite if preserveDrawingBuffer is false.");
 
     debug("");
 
-    gl1 = create3DContext(document.getElementById("c"));
+    gl1 = wtu.create3DContext("c");
     if (!gl1) {
         finishTest();
         return;
     }
 
     shouldBeTrue("gl1 != null");
     shouldBeTrue('gl1.getContextAttributes().preserveDrawingBuffer == false');
 
--- a/content/canvas/test/webgl/conformance/canvas/drawingbuffer-static-canvas-test.html
+++ b/content/canvas/test/webgl/conformance/canvas/drawingbuffer-static-canvas-test.html
@@ -89,18 +89,17 @@ function drawTriangleTest(gl)
 
 description("This test ensures WebGL implementations correctly implement drawingbufferWidth/Height with compositing.");
 
 debug("");
 
 var wtu = WebGLTestUtils;
 var err;
 var maxSize;
-var canvas = document.getElementById("canvas");
-var gl =  wtu.create3DContext(canvas);
+var gl =  wtu.create3DContext("canvas");
 if (!gl) {
   testFailed("context does not exist");
 } else {
   testPassed("context exists");
 
   gl.program = createProgram(gl, "vshader", "fshader", ["vPosition"]);
   shouldBeNonNull("gl.program");
   gl.useProgram(gl.program);
@@ -109,37 +108,37 @@ if (!gl) {
   gl.clearColor(0, 0, 0, 1);
   gl.clearDepth(1);
   shouldBe('gl.getError()', 'gl.NO_ERROR');
 
   debug("");
   debug("Checking drawingBufferWidth/drawingBufferHeight");
 
   // Check that a canvas with no width or height is 300x150 pixels
-  shouldBe('gl.drawingBufferWidth', 'canvas.width');
-  shouldBe('gl.drawingBufferHeight', 'canvas.height');
+  shouldBe('gl.drawingBufferWidth', 'gl.canvas.width');
+  shouldBe('gl.drawingBufferHeight', 'gl.canvas.height');
 
   // Check that changing the canvas size to something too large falls back to reasonable values.
   maxSize = gl.getParameter(gl.MAX_VIEWPORT_DIMS);
   shouldBeTrue('maxSize[0] > 0');
   shouldBeTrue('maxSize[1] > 0');
 
   // debug("MAX_VIEWPORT_DIMS = " + maxSize[0] + "x" + maxSize[1]);
-  canvas.width = maxSize[0] * 4;
-  canvas.height = maxSize[1] * 4;
+  gl.canvas.width = maxSize[0] * 4;
+  gl.canvas.height = maxSize[1] * 4;
   shouldBeTrue('gl.drawingBufferWidth > 0');
   shouldBeTrue('gl.drawingBufferHeight > 0');
   shouldBeTrue('gl.drawingBufferWidth <= maxSize[0]');
   shouldBeTrue('gl.drawingBufferHeight <= maxSize[1]');
   shouldBe('gl.getError()', 'gl.NO_ERROR');
 
   debug("");
   debug("Checking scaling up then back down to 50/50, drawing still works.");
-  canvas.width = 50;
-  canvas.height = 50;
+  gl.canvas.width = 50;
+  gl.canvas.height = 50;
   shouldBeTrue('gl.drawingBufferWidth == 50');
   shouldBeTrue('gl.drawingBufferHeight == 50');
   shouldBe('gl.getError()', 'gl.NO_ERROR');
   drawTriangleTest(gl);
   shouldBe('gl.getError()', 'gl.NO_ERROR');
 }
 debug("")
 successfullyParsed = true;
--- a/content/canvas/test/webgl/conformance/canvas/drawingbuffer-test.html
+++ b/content/canvas/test/webgl/conformance/canvas/drawingbuffer-test.html
@@ -88,18 +88,17 @@ function drawTriangleTest(gl)
 
 description("This test ensures WebGL implementations correctly implement drawingbufferWidth/Height.");
 
 debug("");
 
 var wtu = WebGLTestUtils;
 var err;
 var maxSize;
-var canvas = document.createElement("canvas");
-var gl = create3DContext(canvas);
+var gl = wtu.create3DContext();
 if (!gl) {
   testFailed("context does not exist");
 } else {
   testPassed("context exists");
 
   gl.program = createProgram(gl, "vshader", "fshader", ["vPosition"]);
   shouldBeNonNull("gl.program");
   gl.useProgram(gl.program);
@@ -108,37 +107,37 @@ if (!gl) {
   gl.clearColor(0, 0, 0, 1);
   gl.clearDepth(1);
   shouldBe('gl.getError()', 'gl.NO_ERROR');
 
   debug("");
   debug("Checking drawingBufferWidth/drawingBufferHeight");
 
   // Check that a canvas with no width or height is 300x150 pixels
-  shouldBe('gl.drawingBufferWidth', 'canvas.width');
-  shouldBe('gl.drawingBufferHeight', 'canvas.height');
+  shouldBe('gl.drawingBufferWidth', 'gl.canvas.width');
+  shouldBe('gl.drawingBufferHeight', 'gl.canvas.height');
 
   // Check that changing the canvas size to something too large falls back to reasonable values.
   maxSize = gl.getParameter(gl.MAX_VIEWPORT_DIMS);
   shouldBeTrue('maxSize[0] > 0');
   shouldBeTrue('maxSize[1] > 0');
 
   // debug("MAX_VIEWPORT_DIMS = " + maxSize[0] + "x" + maxSize[1]);
-  canvas.width = maxSize[0] * 4;
-  canvas.height = maxSize[1] * 4;
+  gl.canvas.width = maxSize[0] * 4;
+  gl.canvas.height = maxSize[1] * 4;
   shouldBeTrue('gl.drawingBufferWidth > 0');
   shouldBeTrue('gl.drawingBufferHeight > 0');
   shouldBeTrue('gl.drawingBufferWidth <= maxSize[0]');
   shouldBeTrue('gl.drawingBufferHeight <= maxSize[1]');
   shouldBe('gl.getError()', 'gl.NO_ERROR');
 
   debug("");
   debug("Checking scaling up then back down to 50/50, drawing still works.");
-  canvas.width = 50;
-  canvas.height = 50;
+  gl.canvas.width = 50;
+  gl.canvas.height = 50;
   shouldBeTrue('gl.drawingBufferWidth == 50');
   shouldBeTrue('gl.drawingBufferHeight == 50');
   shouldBe('gl.getError()', 'gl.NO_ERROR');
   drawTriangleTest(gl);
   shouldBe('gl.getError()', 'gl.NO_ERROR');
 }
 debug("")
 successfullyParsed = true;
--- a/content/canvas/test/webgl/conformance/context/constants.html
+++ b/content/canvas/test/webgl/conformance/context/constants.html
@@ -191,17 +191,16 @@ SAMPLE_COVERAGE_VALUE          : 0x80AA,
 SAMPLE_COVERAGE_INVERT         : 0x80AB,
     
     /* GetTextureParameter */
     /*      TEXTURE_MAG_FILTER */
     /*      TEXTURE_MIN_FILTER */
     /*      TEXTURE_WRAP_S */
     /*      TEXTURE_WRAP_T */
     
-NUM_COMPRESSED_TEXTURE_FORMATS : 0x86A2,
 COMPRESSED_TEXTURE_FORMATS     : 0x86A3,
     
     /* HintMode */
 DONT_CARE                      : 0x1100,
 FASTEST                        : 0x1101,
 NICEST                         : 0x1102,
     
     /* HintTarget */
new file mode 100644
--- /dev/null
+++ b/content/canvas/test/webgl/conformance/context/context-attribute-preserve-drawing-buffer.html
@@ -0,0 +1,113 @@
+<!--
+Copyright (C) 2012 Opera Software ASA.  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 OPERA SOFTWARE ASA. ''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 COMPUTER, 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.
+ -->
+<!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>
+        <style>
+            canvas {
+                width:50px;
+                height:50px;
+            }
+            .square {
+                display:inline-block;
+                width:50px;
+                height:50px;
+                background-color:red;
+            }
+        </style>
+        <script>
+            function checkResult(ctx1, ctx2, preserve) {
+                var imgData1 = ctx1.getImageData(0,0,1,1);
+                var imgData2 = ctx2.getImageData(0,0,1,1);
+                var correct1 = [255,0,0,255];
+                var correct2 = preserve ? [255,0,0,255] : [0,0,0,255];
+                var ok1 = true;
+                var ok2 = true;
+                for (var p = 0; p < 4; ++p) {
+                    if (imgData1.data[p] != correct1[p])
+                        ok1 = false;
+                    if (imgData2.data[p] != correct2[p])
+                        ok2 = false;
+                }
+                if (ok1 && ok2)
+                    testPassed('Rendered ok with preserveDrawingBuffer ' + preserve +'.');
+                else
+                    testFailed('Did not render ok with preserveDrawingBuffer ' + preserve + '.');
+                if (preserve) {
+                    debug('<br /><span class="pass">TEST COMPLETE</span>');
+                    notifyFinishedToHarness()
+                } else {
+                    runTest(true);
+                }
+            }
+
+            function runTest(preserve) {
+                var c1 = document.getElementById('c' + (preserve * 3 + 1));
+                var c2 = document.getElementById('c' + (preserve * 3 + 2));
+                var c3 = document.getElementById('c' + (preserve * 3 + 3));
+                var ctx1 = c1.getContext('2d');
+                var ctx2 = c2.getContext('2d');
+                var gl = c3.getContext('experimental-webgl', { alpha:false, preserveDrawingBuffer:preserve });
+                gl.clearColor(1, 0, 0, 1);
+                gl.clear(gl.COLOR_BUFFER_BIT);
+                ctx1.drawImage(c3, 0, 0);
+                setTimeout(function() { ctx2.drawImage(c3, 0, 0); checkResult(ctx1, ctx2, preserve); }, 100);
+
+            }
+        </script>
+    </head>
+    <body>
+        <div>
+            <canvas id='c1'></canvas>
+            <canvas id='c2'></canvas>
+            <canvas id='c3'></canvas>
+            <span>should look as right pattern</span>
+            <div class='square'></div>
+            <div class='square' style='background-color:black'></div>
+            <div class='square'></div>
+        </div>
+        <div>
+            <canvas id='c4'></canvas>
+            <canvas id='c5'></canvas>
+            <canvas id='c6'></canvas>
+            <span>should look as right pattern</span>
+            <div class='square'></div>
+            <div class='square'></div>
+            <div class='square'></div>
+        </div>
+        <div id="description"></div>
+        <div id="console"></div>
+        <script>
+            description('Verify that preserveDrawingBuffer attribute is honored.');
+            runTest(false);
+            successfullyParsed = true;
+            shouldBeTrue("successfullyParsed");
+        </script>
+    </body>
+</html>
--- a/content/canvas/test/webgl/conformance/extensions/00_test_list.txt
+++ b/content/canvas/test/webgl/conformance/extensions/00_test_list.txt
@@ -1,8 +1,8 @@
 oes-standard-derivatives.html
 ext-texture-filter-anisotropic.html
 oes-texture-float.html
 oes-vertex-array-object.html
 webgl-debug-renderer-info.html
 webgl-debug-shaders.html
---min-version 1.0.2 webgl-experimental-compressed-textures.html
+--min-version 1.0.2 webgl-compressed-texture-s3tc.html
 
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgb.dxt1.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_4x4_rgb_dxt1 = [
-0xe0,0x07,0x00,0xf8,0x11,0x10,0x15,0x00,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgba.dxt1.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_4x4_rgba_dxt1 = [
-0xe0,0x07,0x00,0xf8,0x13,0x10,0x15,0x00,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgba.dxt3.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_4x4_rgba_dxt3 = [
-0xf6,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x00,0xf8,0xe0,0x07,0x44,0x45,0x40,0x55,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgba.dxt5.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_4x4_rgba_dxt5 = [
-0xf6,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x00,0xf8,0xe0,0x07,0x44,0x45,0x40,0x55,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/4x4.rgba.raw.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_4x4_rgba_raw = [
-0xff,0x00,0x00,0x69,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgb.dxt1.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_8x8_rgb_dxt1 = [
-0xe0,0x07,0x00,0xf8,0x11,0x10,0x15,0x00,0x1f,0x00,0xe0,0xff,0x11,0x10,0x15,0x00,0xe0,0x07,0x1f,0xf8,0x44,0x45,0x40,0x55,0x1f,0x00,0xff,0x07,0x44,0x45,0x40,0x55,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.dxt1.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_8x8_rgba_dxt1 = [
-0xe0,0x07,0x00,0xf8,0x13,0x13,0x15,0x00,0x1f,0x00,0xe0,0xff,0x11,0x10,0x15,0x00,0xe0,0x07,0x1f,0xf8,0x44,0x45,0x43,0x57,0x1f,0x00,0xff,0x07,0x44,0x45,0x40,0x55,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.dxt3.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_8x8_rgba_dxt3 = [
-0xf6,0xff,0xf6,0xff,0xff,0xff,0xff,0xff,0x00,0xf8,0xe0,0x07,0x44,0x45,0x40,0x55,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xe0,0xff,0x1f,0x00,0x44,0x45,0x40,0x55,0xff,0xff,0xff,0xff,0xf6,0xff,0xf6,0xff,0x1f,0xf8,0xe0,0x07,0x11,0x10,0x15,0x00,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x07,0x1f,0x00,0x11,0x10,0x15,0x00,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.dxt5.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_8x8_rgba_dxt5 = [
-0xff,0x69,0x01,0x10,0x00,0x00,0x00,0x00,0x00,0xf8,0xe0,0x07,0x44,0x45,0x40,0x55,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0x1f,0x00,0x44,0x45,0x40,0x55,0xff,0x69,0x00,0x00,0x00,0x01,0x10,0x00,0x1f,0xf8,0xe0,0x07,0x11,0x10,0x15,0x00,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x07,0x1f,0x00,0x11,0x10,0x15,0x00,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.pvrtc4bpp.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_8x8_rgba_pvrtc4bpp = [
-0x33,0x30,0x3f,0x00,0xe0,0x83,0x00,0xfc,0xcc,0xcf,0xc0,0xff,0xe0,0x83,0x1f,0xfc,0xcc,0xcf,0xc0,0xff,0xe0,0xff,0x1f,0x80,0x33,0x30,0x3f,0x00,0xfe,0x83,0x1f,0x80,
-];
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/compressed-textures/8x8.rgba.raw.js
+++ /dev/null
@@ -1,3 +0,0 @@
-var img_8x8_rgba_raw = [
-0xff,0x00,0x00,0x69,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0xff,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0x00,0x69,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0xff,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0x00,0x69,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0xff,0x00,0xff,0x69,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,
-];
--- a/content/canvas/test/webgl/conformance/extensions/oes-standard-derivatives.html
+++ b/content/canvas/test/webgl/conformance/extensions/oes-standard-derivatives.html
@@ -115,18 +115,18 @@ if (!gl) {
     } else {
         testPassed("Successfully enabled OES_standard_derivatives extension");
 
         runSupportedTest(true);
 
         runHintTestEnabled();
         runShaderTests(true);
         runOutputTests();
-      // similar to bug 683216, see the discussion in bug 630672
-      // runUniqueObjectTest();
+        runUniqueObjectTest();
+        runReferenceCycleTest();
     }
 }
 
 function runSupportedTest(extensionEnabled) {
     var supported = gl.getSupportedExtensions();
     if (supported.indexOf("OES_standard_derivatives") >= 0) {
         if (extensionEnabled) {
             testPassed("OES_standard_derivatives listed as supported and getExtension succeeded");
@@ -252,21 +252,17 @@ function runOutputTests() {
     var e = 2; // Amount of variance to allow in result pixels - may need to be tweaked higher
 
     debug("Testing various draws for valid built-in function behavior");
 
     canvas.width = 50; canvas.height = 50;
     gl.viewport(0, 0, canvas.width, canvas.height);
     gl.hint(ext.FRAGMENT_SHADER_DERIVATIVE_HINT_OES, gl.NICEST);
 
-    var shaders = [
-        wtu.loadShaderFromScript(gl, "outputVertexShader"),
-        wtu.loadShaderFromScript(gl, "outputFragmentShader")
-    ];
-    var program = wtu.setupProgram(gl, shaders, ['vPosition', 'texCoord0'], [0, 1]);
+    var program = wtu.setupProgram(gl, ["outputVertexShader", "outputFragmentShader"], ['vPosition', 'texCoord0'], [0, 1]);
     var quadParameters = wtu.setupUnitQuad(gl, 0, 1);
 
     function readLocation(x, y) {
         var pixels = new Uint8Array(1 * 1 * 4);
         var px = Math.floor(x * canvas.width);
         var py = Math.floor(y * canvas.height);
         gl.readPixels(px, py, 1, 1, gl.RGBA, gl.UNSIGNED_BYTE, pixels);
         return pixels;
@@ -370,16 +366,30 @@ function runUniqueObjectTest()
     } else if (window.opera && window.opera.collect) {
         window.opera.collect();
     } else {
         attemptToForceGC();
     }
     shouldBe('gl.getExtension("OES_standard_derivatives").myProperty', '2');
 }
 
+function runReferenceCycleTest()
+{
+    // create some reference cycles. The goal is to see if they cause leaks. The point is that
+    // some browser test runners have instrumentation to detect leaked refcounted objects.
+
+    debug("Testing reference cycles between context and extension objects");
+    var ext = gl.getExtension("OES_standard_derivatives");
+
+    // create cycle between extension and context, since the context has to hold a reference to the extension
+    ext.context = gl;
+
+    // create a self-cycle on the extension object
+    ext.ext = ext;
+}
 
 debug("");
 successfullyParsed = true;
 </script>
 <script src="../../resources/js-test-post.js"></script>
 
 </body>
 </html>
--- a/content/canvas/test/webgl/conformance/extensions/oes-texture-float.html
+++ b/content/canvas/test/webgl/conformance/extensions/oes-texture-float.html
@@ -61,17 +61,17 @@ var gl = create3DContext(canvas);
 
 if (!gl) {
   testFailed("WebGL context does not exist");
 } else {
   testPassed("WebGL context exists");
 
   var texturedShaders = [
       wtu.setupSimpleTextureVertexShader(gl),
-      wtu.loadShaderFromScript(gl, "testFragmentShader")
+      "testFragmentShader"
   ];
   var testProgram =
       wtu.setupProgram(gl,
                        texturedShaders,
                        ['vPosition', 'texCoord0'],
                        [0, 1]);
   var quadParameters = wtu.setupUnitQuad(gl, 0, 1);
 
@@ -80,18 +80,18 @@ if (!gl) {
   runTextureCreationTest(testProgram, false);
 
   if (!gl.getExtension("OES_texture_float")) {
       testPassed("No OES_texture_float support -- this is legal");
   } else {
       testPassed("Successfully enabled OES_texture_float extension");
       runTextureCreationTest(testProgram, true);
       runRenderTargetTest(testProgram);
-      // bug 683216, see the discussion in bug 630672
-      // runUniqueObjectTest();
+      runUniqueObjectTest();
+      runReferenceCycleTest();
   }
 }
 
 // Needs to be global for shouldBe to see it.
 var pixels;
 
 function allocateTexture()
 {
@@ -160,23 +160,19 @@ function runRenderTargetTest(testProgram
     // While strictly speaking it is probably legal for a WebGL implementation to support
     // floating-point textures but not as attachments to framebuffer objects, any such
     // implementation is so poor that it arguably should not advertise support for the
     // OES_texture_float extension. For this reason the conformance test requires that the
     // framebuffer is complete here.
     if (gl.checkFramebufferStatus(gl.FRAMEBUFFER) != gl.FRAMEBUFFER_COMPLETE)
         return;
 
-    var shaders = [
-        wtu.loadShaderFromScript(gl, "positionVertexShader"),
-        wtu.loadShaderFromScript(gl, "floatingPointFragmentShader")
-    ];
     var renderProgram =
         wtu.setupProgram(gl,
-                         shaders,
+                         ["positionVertexShader", "floatingPointFragmentShader"],
                          ['vPosition'],
                          [0]);
     wtu.drawQuad(gl);
     glErrorShouldBe(gl, gl.NO_ERROR, "rendering to floating-point texture should succeed");
 
     // Now sample from the floating-point texture and verify we got the correct values.
     gl.bindFramebuffer(gl.FRAMEBUFFER, null);
     gl.bindTexture(gl.TEXTURE_2D, texture);
@@ -211,16 +207,30 @@ function runUniqueObjectTest()
     } else if (window.opera && window.opera.collect) {
         window.opera.collect();
     } else {
         attemptToForceGC();
     }
     shouldBe('gl.getExtension("OES_texture_float").myProperty', '2');
 }
 
+function runReferenceCycleTest()
+{
+    // create some reference cycles. The goal is to see if they cause leaks. The point is that
+    // some browser test runners have instrumentation to detect leaked refcounted objects.
+
+    debug("Testing reference cycles between context and extension objects");
+    var ext = gl.getExtension("OES_texture_float");
+
+    // create cycle between extension and context, since the context has to hold a reference to the extension
+    ext.context = gl;
+
+    // create a self-cycle on the extension object
+    ext.ext = ext;
+}
 
 debug("");
 successfullyParsed = true;
 </script>
 <script src="../../resources/js-test-post.js"></script>
 
 </body>
 </html>
new file mode 100644
--- /dev/null
+++ b/content/canvas/test/webgl/conformance/extensions/webgl-compressed-texture-s3tc.html
@@ -0,0 +1,614 @@
+<!--
+Copyright (c) 2012 The Chromium Authors. All rights reserved.
+Use of this source code is governed by a BSD-style license that can be
+found in the LICENSE file.
+ -->
+<!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>
+<title>WebGL WEBGL_compressed_texture_s3tc Conformance Tests</title>
+<style>
+img {
+ border: 1px solid black;
+ margin-right: 1em;
+}
+.testimages {
+}
+
+.testimages br {
+  clear: both;
+}
+
+.testimages > div {
+  float: left;
+  margin: 1em;
+}
+</style>
+</head>
+<body>
+<div id="description"></div>
+<canvas id="canvas" width="8" height="8" style="width: 8px; height: 8px;"></canvas>
+<div id="console"></div>
+<script>
+description("This test verifies the functionality of the WEBGL_compressed_texture_s3tc extension, if it is available.");
+
+debug("");
+
+var img_4x4_rgba_raw = new Uint8Array([
+    0xff,0x00,0x00,0x69,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,
+]);
+var img_4x4_rgb_dxt1 = new Uint8Array([
+    0xe0,0x07,0x00,0xf8,0x11,0x10,0x15,0x00,
+]);
+var img_4x4_rgba_dxt1 = new Uint8Array([
+    0xe0,0x07,0x00,0xf8,0x13,0x10,0x15,0x00,
+]);
+var img_4x4_rgba_dxt3 = new Uint8Array([
+    0xf6,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x00,0xf8,0xe0,0x07,0x44,0x45,0x40,0x55,
+]);
+var img_4x4_rgba_dxt5 = new Uint8Array([
+    0xf6,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x00,0xf8,0xe0,0x07,0x44,0x45,0x40,0x55,
+]);
+var img_8x8_rgba_raw = new Uint8Array([
+    0xff,0x00,0x00,0x69,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0xff,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0x00,0x69,0x00,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0xff,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0x00,0x69,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0xff,0x00,0xff,0x69,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,0x00,0xff,0xff,0xff,
+]);
+var img_8x8_rgb_dxt1 = new Uint8Array([
+    0xe0,0x07,0x00,0xf8,0x11,0x10,0x15,0x00,0x1f,0x00,0xe0,0xff,0x11,0x10,0x15,0x00,0xe0,0x07,0x1f,0xf8,0x44,0x45,0x40,0x55,0x1f,0x00,0xff,0x07,0x44,0x45,0x40,0x55,
+]);
+var img_8x8_rgba_dxt1 = new Uint8Array([
+    0xe0,0x07,0x00,0xf8,0x13,0x13,0x15,0x00,0x1f,0x00,0xe0,0xff,0x11,0x10,0x15,0x00,0xe0,0x07,0x1f,0xf8,0x44,0x45,0x43,0x57,0x1f,0x00,0xff,0x07,0x44,0x45,0x40,0x55,
+]);
+var img_8x8_rgba_dxt3 = new Uint8Array([
+    0xf6,0xff,0xf6,0xff,0xff,0xff,0xff,0xff,0x00,0xf8,0xe0,0x07,0x44,0x45,0x40,0x55,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xe0,0xff,0x1f,0x00,0x44,0x45,0x40,0x55,0xff,0xff,0xff,0xff,0xf6,0xff,0xf6,0xff,0x1f,0xf8,0xe0,0x07,0x11,0x10,0x15,0x00,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x07,0x1f,0x00,0x11,0x10,0x15,0x00,
+]);
+var img_8x8_rgba_dxt5 = new Uint8Array([
+    0xff,0x69,0x01,0x10,0x00,0x00,0x00,0x00,0x00,0xf8,0xe0,0x07,0x44,0x45,0x40,0x55,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0x1f,0x00,0x44,0x45,0x40,0x55,0xff,0x69,0x00,0x00,0x00,0x01,0x10,0x00,0x1f,0xf8,0xe0,0x07,0x11,0x10,0x15,0x00,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x07,0x1f,0x00,0x11,0x10,0x15,0x00,
+]);
+
+var wtu = WebGLTestUtils;
+var canvas = document.getElementById("canvas");
+var gl = wtu.create3DContext(canvas, {antialias: false});
+var program = wtu.setupTexturedQuad(gl);
+var ext = null;
+var vao = null;
+var validFormats = {
+    COMPRESSED_RGB_S3TC_DXT1_EXT        : 0x83F0,
+    COMPRESSED_RGBA_S3TC_DXT1_EXT       : 0x83F1,
+    COMPRESSED_RGBA_S3TC_DXT3_EXT       : 0x83F2,
+    COMPRESSED_RGBA_S3TC_DXT5_EXT       : 0x83F3,
+};
+var name;
+var supportedFormats;
+
+if (!gl) {
+    testFailed("WebGL context does not exist");
+} else {
+    testPassed("WebGL context exists");
+
+    // Run tests with extension disabled
+    runTestDisabled();
+
+    // Query the extension and store globally so shouldBe can access it
+    ext = gl.getExtension("WEBGL_compressed_texture_s3tc");
+    if (!ext) {
+        ext = gl.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");
+    }
+    if (!ext) {
+        testPassed("No WEBGL_compressed_texture_s3tc support -- this is legal");
+        runSupportedTest(false);
+    } else {
+        testPassed("Successfully enabled WEBGL_compressed_texture_s3tc extension");
+
+        runSupportedTest(true);
+        runTestExtension();
+    }
+}
+
+function runSupportedTest(extensionEnabled) {
+    var supported = gl.getSupportedExtensions();
+    if (supported.indexOf("WEBGL_compressed_texture_s3tc") >= 0 ||
+        supported.indexOf("WEBKIT_WEBGL_compressed_texture_s3tc") >= 0) {
+        if (extensionEnabled) {
+            testPassed("WEBGL_compressed_texture_s3tc listed as supported and getExtension succeeded");
+        } else {
+            testFailed("WEBGL_compressed_texture_s3tc listed as supported but getExtension failed");
+        }
+    } else {
+        if (extensionEnabled) {
+            testFailed("WEBGL_compressed_texture_s3tc not listed as supported but getExtension succeeded");
+        } else {
+            testPassed("WEBGL_compressed_texture_s3tc not listed as supported and getExtension failed -- this is legal");
+        }
+    }
+}
+
+
+function runTestDisabled() {
+    debug("Testing binding enum with extension disabled");
+
+    shouldBe('gl.getParameter(gl.COMPRESSED_TEXTURE_FORMATS)', '[]');
+}
+
+function formatExists(format, supportedFormats) {
+    for (var ii = 0; ii < supportedFormats.length; ++ii) {
+        if (format == supportedFormats[ii]) {
+            testPassed("supported format " + formatToString(format) + " is exists");
+            return;
+        }
+    }
+    testFailed("supported format " + formatToString(format) + " does not exist");
+}
+
+function formatToString(format) {
+    for (var p in ext) {
+        if (ext[p] == format) {
+            return p;
+        }
+    }
+    return "0x" + format.toString(16);
+}
+
+function runTestExtension() {
+    debug("Testing WEBGL_compressed_texture_s3tc");
+
+    // check that all format enums exist.
+    for (name in validFormats) {
+        var expected = "0x" + validFormats[name].toString(16);
+        var actual = "ext['" + name + "']";
+        shouldBe(actual, expected);
+    }
+
+    supportedFormats = gl.getParameter(gl.COMPRESSED_TEXTURE_FORMATS);
+    // There should be exactly 4 formats
+    shouldBe("supportedFormats.length", "4");
+
+    // check that all 4 formats exist
+    for (var name in validFormats.length) {
+        formatExists(validFormats[name], supportedFormats);
+    }
+
+    // Test each format
+    testDXT1_RGB();
+    testDXT1_RGBA();
+    testDXT3_RGBA();
+    testDXT5_RGBA();
+}
+
+function testDXT1_RGB() {
+    var tests = [
+        {   width: 4,
+            height: 4,
+            channels: 3,
+            data: img_4x4_rgb_dxt1,
+            format: ext.COMPRESSED_RGB_S3TC_DXT1_EXT
+        },
+        {   width: 8,
+            height: 8,
+            channels: 3,
+            data: img_8x8_rgb_dxt1,
+            format: ext.COMPRESSED_RGB_S3TC_DXT1_EXT
+        }
+    ];
+    testDXTTextures(tests);
+}
+
+function testDXT1_RGBA() {
+    var tests = [
+        {   width: 4,
+            height: 4,
+            channels: 4,
+            data: img_4x4_rgba_dxt1,
+            format: ext.COMPRESSED_RGBA_S3TC_DXT1_EXT
+        },
+        {   width: 8,
+            height: 8,
+            channels: 4,
+            data: img_8x8_rgba_dxt1,
+            format: ext.COMPRESSED_RGBA_S3TC_DXT1_EXT
+        }
+    ];
+    testDXTTextures(tests);
+}
+
+function testDXT3_RGBA() {
+    var tests = [
+        {   width: 4,
+            height: 4,
+            channels: 4,
+            data: img_4x4_rgba_dxt3,
+            format: ext.COMPRESSED_RGBA_S3TC_DXT3_EXT
+        },
+        {   width: 8,
+            height: 8,
+            channels: 4,
+            data: img_8x8_rgba_dxt3,
+            format: ext.COMPRESSED_RGBA_S3TC_DXT3_EXT
+        }
+    ];
+    testDXTTextures(tests);
+}
+
+function testDXT5_RGBA() {
+    var tests = [
+        {   width: 4,
+            height: 4,
+            channels: 4,
+            data: img_4x4_rgba_dxt5,
+            format: ext.COMPRESSED_RGBA_S3TC_DXT5_EXT
+        },
+        {   width: 8,
+            height: 8,
+            channels: 4,
+            data: img_8x8_rgba_dxt5,
+            format: ext.COMPRESSED_RGBA_S3TC_DXT5_EXT
+        }
+    ];
+    testDXTTextures(tests);
+}
+
+function testDXTTextures(tests) {
+    debug("<hr/>");
+    for (var ii = 0; ii < tests.length; ++ii) {
+        testDXTTexture(tests[ii]);
+    }
+}
+
+function uncompressDXTBlock(
+    destBuffer, destX, destY, destWidth, src, srcOffset, format) {
+    function make565(src, offset) {
+        return src[offset + 0] + src[offset + 1] * 256;
+    }
+    function make8888From565(c) {
+        return [
+                Math.floor(((c >> 11) & 0x1F) * 255 / 31),
+                Math.floor(((c >>    5) & 0x3F) * 255 / 63),
+                Math.floor(((c >>    0) & 0x1F) * 255 / 31),
+                255
+            ];
+    }
+    function mix(mult, c0, c1, div) {
+        var r = [];
+        for (var ii = 0; ii < c0.length; ++ii) {
+            r[ii] = Math.floor((c0[ii] * mult + c1[ii]) / div);
+        }
+        return r;
+    }
+    var isDXT1 = format == ext.COMPRESSED_RGB_S3TC_DXT1_EXT ||
+                 format == ext.COMPRESSED_RGBA_S3TC_DXT1_EXT;
+    var colorOffset = srcOffset + (isDXT1 ? 0 : 8);
+    var color0 = make565(src, colorOffset + 0);
+    var color1 = make565(src, colorOffset + 2);
+    var c0gtc1 = color0 > color1 || !isDXT1;
+    var rgba0 = make8888From565(color0);
+    var rgba1 = make8888From565(color1);
+    var colors = [
+            rgba0,
+            rgba1,
+            c0gtc1 ? mix(2, rgba0, rgba1, 3) : mix(1, rgba0, rgba1, 2),
+            c0gtc1 ? mix(2, rgba1, rgba0, 3) : [0, 0, 0, 255]
+        ];
+
+    // yea I know there is a lot of math in this inner loop.
+    // so sue me.
+    for (var yy = 0; yy < 4; ++yy) {
+        var pixels = src[colorOffset + 4 + yy];
+        for (var xx = 0; xx < 4; ++xx) {
+            var dstOff = ((destY + yy) * destWidth + destX + xx) * 4;
+            var code = (pixels >> (xx * 2)) & 0x3;
+            var srcColor = colors[code];
+            var alpha;
+            switch (format) {
+            case ext.COMPRESSED_RGB_S3TC_DXT1_EXT:
+                alpha = 255;
+                break;
+            case ext.COMPRESSED_RGBA_S3TC_DXT1_EXT:
+                alpha = (code == 3 && !c0gtc1) ? 0 : 255;
+                break;
+            case ext.COMPRESSED_RGBA_S3TC_DXT3_EXT:
+                {
+                    var alpha0 = src[srcOffset + yy * 2 + Math.floor(xx / 2)];
+                    var alpha1 = (alpha0 >> ((xx % 2) * 4)) & 0xF;
+                    alpha = alpha1 | (alpha1 << 4);
+                }
+                break;
+            case ext.COMPRESSED_RGBA_S3TC_DXT5_EXT:
+                {
+                    var alpha0 = src[srcOffset + 0];
+                    var alpha1 = src[srcOffset + 1];
+                    var alphaOff = Math.floor(yy / 2) * 3 + 2;
+                    var alphaBits =
+                         src[srcOffset + alphaOff + 0] +
+                         src[srcOffset + alphaOff + 1] * 256 +
+                         src[srcOffset + alphaOff + 2] * 65536;
+                    var alphaShift = (yy % 2) * 12 + xx * 3;
+                    var alphaCode = (alphaBits >> alphaShift) & 0x7;
+                    if (alpha0 > alpha1) {
+                        switch (alphaCode) {
+                        case 0:
+                            alpha = alpha0;
+                            break;
+                        case 1:
+                            alpha = alpha1;
+                            break;
+                        default:
+                            alpha = ((8 - alphaCode) * alpha0 + (alphaCode - 1) * alpha1) / 7;
+                            break;
+                        }
+                    } else {
+                        switch (alphaCode) {
+                        case 0:
+                            alpha = alpha0;
+                            break;
+                        case 1:
+                            alpha = alpha1;
+                            break;
+                        case 6:
+                            alpha = 0;
+                            break;
+                        case 7:
+                            alpha = 255;
+                            break;
+                        default:
+                            alpha = ((6 - alphaCode) * alpha0 + (alphaCode - 1) * alpha1) / 5;
+                            break;
+                        }
+                    }
+                }
+                break;
+            default:
+                throw "bad format";
+            }
+            destBuffer[dstOff + 0] = srcColor[0];
+            destBuffer[dstOff + 1] = srcColor[1];
+            destBuffer[dstOff + 2] = srcColor[2];
+            destBuffer[dstOff + 3] = alpha;
+        }
+    }
+}
+
+function getBlockSize(format) {
+  var isDXT1 = format == ext.COMPRESSED_RGB_S3TC_DXT1_EXT ||
+               format == ext.COMPRESSED_RGBA_S3TC_DXT1_EXT;
+  return isDXT1 ? 8 : 16;
+}
+
+function uncompressDXT(width, height, data, format) {
+    if (width % 4 || height % 4) throw "bad width or height";
+
+    var dest = new Uint8Array(width * height * 4);
+    var blocksAcross = width / 4;
+    var blocksDown = height / 4;
+    var blockSize = getBlockSize(format);
+    for (var yy = 0; yy < blocksDown; ++yy) {
+        for (var xx = 0; xx < blocksAcross; ++xx) {
+            uncompressDXTBlock(
+                dest, xx * 4, yy * 4, width, data,
+                (yy * blocksAcross + xx) * blockSize, format);
+        }
+    }
+    return dest;
+}
+
+function copyRect(data, srcX, srcY, dstX, dstY, width, height, stride) {
+  var bytesPerLine = width * 4;
+  var srcOffset = srcX * 4 + srcY * stride;
+  var dstOffset = dstX * 4 + dstY * stride;
+  for (; height > 0; --height) {
+    for (var ii = 0; ii < bytesPerLine; ++ii) {
+      data[dstOffset + ii] = data[srcOffset + ii];
+    }
+    srcOffset += stride;
+    dstOffset += stride;
+  }
+}
+
+function testDXTTexture(test) {
+    var data = new Uint8Array(test.data);
+    var width = test.width;
+    var height = test.height;
+    var format = test.format;
+
+    var uncompressedData = uncompressDXT(width, height, data, format);
+
+    canvas.width = width;
+    canvas.height = height;
+    gl.viewport(0, 0, width, height);
+    debug("testing " + formatToString(format) + " " + width + "x" + height);
+    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);
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width, height, 0, data);
+    glErrorShouldBe(gl, gl.NO_ERROR, "uploading compressed texture");
+    wtu.drawQuad(gl);
+    compareRect(width, height, test.channels, width, height, uncompressedData, data, format);
+
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width, height, 1, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "non 0 border");
+
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width + 4, height, 0, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "data size does not match dimensions");
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width, height + 4, 0, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "data size does not match dimensions");
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width - 4, height, 0, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "data size does not match dimensions");
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width, height - 4, 0, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "data size does not match dimensions");
+
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width - 1, height, 0, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width - 2, height, 0, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width, height - 1, 0, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
+    gl.compressedTexImage2D(gl.TEXTURE_2D, 0, format, width, height - 2, 0, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
+
+    if (width == 4) {
+      gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, 1, height, 0, data);
+      glErrorShouldBe(gl, gl.NO_ERROR, "valid dimensions for level > 0");
+      gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, 2, height, 0, data);
+      glErrorShouldBe(gl, gl.NO_ERROR, "valid dimensions for level > 0");
+    }
+    if (height == 4) {
+      gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, width, 1, 0, data);
+      glErrorShouldBe(gl, gl.NO_ERROR, "valid dimensions for level > 0");
+      gl.compressedTexImage2D(gl.TEXTURE_2D, 1, format, width, 2, 0, data);
+      glErrorShouldBe(gl, gl.NO_ERROR, "valid dimensions for level > 0");
+    }
+
+    // pick a wrong format that uses the same amount of data.
+    var wrongFormat;
+    switch (format) {
+    case ext.COMPRESSED_RGB_S3TC_DXT1_EXT:
+      wrongFormat = ext.COMPRESSED_RGBA_S3TC_DXT1_EXT;
+      break;
+    case ext.COMPRESSED_RGBA_S3TC_DXT1_EXT:
+      wrongFormat = ext.COMPRESSED_RGB_S3TC_DXT1_EXT;
+      break;
+    case ext.COMPRESSED_RGBA_S3TC_DXT3_EXT:
+      wrongFormat = ext.COMPRESSED_RGBA_S3TC_DXT5_EXT;
+      break;
+    case ext.COMPRESSED_RGBA_S3TC_DXT5_EXT:
+      wrongFormat = ext.COMPRESSED_RGBA_S3TC_DXT3_EXT;
+      break;
+    }
+
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width, height, wrongFormat, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "format does not match");
+
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width + 4, height, format, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "data size does not match dimensions");
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width, height + 4, format, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "data size does not match dimensions");
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width - 4, height, format, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "data size does not match dimensions");
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width, height - 4, format, data);
+    glErrorShouldBe(gl, gl.INVALID_VALUE, "data size does not match dimensions");
+
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width - 1, height, format, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width - 2, height, format, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width, height - 1, format, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
+    gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 0, width, height - 2, format, data);
+    glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid dimensions");
+
+    var subData = new Uint8Array(data.buffer, 0, getBlockSize(format));
+
+    if (width == 8 && height == 8) {
+        gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 1, 0, 4, 4, format, subData);
+        glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid offset");
+        gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, 0, 1, 4, 4, format, subData);
+        glErrorShouldBe(gl, gl.INVALID_OPERATION, "invalid offset");
+    }
+
+    var stride = width * 4;
+    for (var yoff = 0; yoff < height; yoff += 4) {
+        for (var xoff = 0; xoff < width; xoff += 4) {
+            copyRect(uncompressedData, 0, 0, xoff, yoff, 4, 4, stride);
+            gl.compressedTexSubImage2D(gl.TEXTURE_2D, 0, xoff, yoff, 4, 4, format, subData);
+            glErrorShouldBe(gl, gl.NO_ERROR, "uploading compressed texture");
+            wtu.drawQuad(gl);
+            compareRect(width, height, test.channels, width, height, uncompressedData, data, format);
+        }
+    }
+}
+
+function insertImg(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);
+}
+
+function makeImage(imageWidth, imageHeight, dataWidth, data, alpha) {
+    var scale = 8;
+    var c = document.createElement("canvas");
+    c.width = imageWidth * scale;
+    c.height = imageHeight * scale;
+    var ctx = c.getContext("2d");
+    for (var yy = 0; yy < imageWidth; ++yy) {
+        for (var xx = 0; xx < imageHeight; ++xx) {
+            var offset = (yy * dataWidth + xx) * 4;
+            ctx.fillStyle = "rgba(" +
+                    data[offset + 0] + "," +
+                    data[offset + 1] + "," +
+                    data[offset + 2] + "," +
+                    (alpha ? data[offset + 3] / 255 : 1) + ")";
+            ctx.fillRect(xx * scale, yy * scale, scale, scale);
+        }
+    }
+    var img = document.createElement("img");
+    img.src = c.toDataURL();
+    return img;
+}
+function compareRect(
+        actualWidth, actualHeight, actualChannels,
+        dataWidth, dataHeight, expectedData,
+        testData, testFormat) {
+    var actual = new Uint8Array(actualWidth * actualHeight * 4);
+    gl.readPixels(
+            0, 0, actualWidth, actualHeight, gl.RGBA, gl.UNSIGNED_BYTE, actual);
+
+    var div = document.createElement("div");
+    div.className = "testimages";
+    insertImg(div, "expected", makeImage(
+            actualWidth, actualHeight, dataWidth, expectedData,
+            actualChannels == 4));
+    insertImg(div, "actual", makeImage(
+            actualWidth, actualHeight, actualWidth, actual,
+            actualChannels == 4));
+    div.appendChild(document.createElement('br'));
+    document.getElementById("console").appendChild(div);
+
+    var failed = false;
+    for (var yy = 0; yy < actualHeight; ++yy) {
+        for (var xx = 0; xx < actualWidth; ++xx) {
+            var actualOffset = (yy * actualWidth + xx) * 4;
+            var expectedOffset = (yy * dataWidth + xx) * 4;
+            var expected = [
+                    expectedData[expectedOffset + 0],
+                    expectedData[expectedOffset + 1],
+                    expectedData[expectedOffset + 2],
+                    (actualChannels == 3 ? 255 : expectedData[expectedOffset + 3])
+            ];
+            for (var jj = 0; jj < 4; ++jj) {
+                if (actual[actualOffset + jj] != expected[jj]) {
+                    failed = true;
+                    var was = actual[actualOffset + 0].toString();
+                    for (j = 1; j < 4; ++j) {
+                        was += "," + actual[actualOffset + j];
+                    }
+                    testFailed('at (' + xx + ', ' + yy +
+                                         ') expected: ' + expected + ' was ' + was);
+                }
+            }
+        }
+    }
+    if (!failed) {
+        testPassed("texture rendered correctly");
+    }
+}
+
+function testPVRTCTextures() {
+    testFailed("PVRTC test not yet implemented");
+}
+
+debug("");
+successfullyParsed = true;
+</script>
+<script src="../../resources/js-test-post.js"></script>
+
+</body>
+</html>
--- a/content/canvas/test/webgl/conformance/extensions/webgl-debug-renderer-info.html
+++ b/content/canvas/test/webgl/conformance/extensions/webgl-debug-renderer-info.html
@@ -21,18 +21,17 @@ found in the LICENSE file.
 <!-- Shaders for testing standard derivatives -->
 
 <script>
 description("This test verifies the functionality of the WEBGL_debug_renderer_info extension, if it is available.");
 
 debug("");
 
 var wtu = WebGLTestUtils;
-var canvas = document.getElementById("canvas");
-var gl = create3DContext(canvas);
+var gl = wtu.create3DContext("canvas");
 var ext = null;
 var vao = null;
 
 if (!gl) {
     testFailed("WebGL context does not exist");
 } else {
     testPassed("WebGL context exists");
 
--- a/content/canvas/test/webgl/conformance/extensions/webgl-debug-shaders.html
+++ b/content/canvas/test/webgl/conformance/extensions/webgl-debug-shaders.html
@@ -21,18 +21,17 @@ found in the LICENSE file.
 <!-- Shaders for testing standard derivatives -->
 
 <script>
 description("This test verifies the functionality of the WEBGL_debug_shaders extension, if it is available.");
 
 debug("");
 
 var wtu = WebGLTestUtils;
-var canvas = document.getElementById("canvas");
-var gl = create3DContext(canvas);
+var gl = wtu.create3DContext("canvas");
 var ext = null;
 var shader = null;
 
 if (!gl) {
     testFailed("WebGL context does not exist");
 } else {
     testPassed("WebGL context exists");
 
deleted file mode 100644
--- a/content/canvas/test/webgl/conformance/extensions/webgl-experimental-compressed-textures.html
+++ /dev/null
@@ -1,520 +0,0 @@
-<!--
-Copyright (c) 2011 The Chromium Authors. All rights reserved.
-Use of this source code is governed by a BSD-style license that can be
-found in the LICENSE file.
- -->
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="utf-8">
-<title>WebGL WEBGL_EXPERIMENTAL_compressed_textures Conformance Tests</title>
-<link rel="stylesheet" href="../../resources/js-test-style.css"/>
-<style>
-img {
- border: 1px solid black;
- margin-right: 1em;
-}
-.testimages {
-}
-
-.testimages br {
-  clear: both;
-}
-
-.testimages > div {
-  float: left;
-  margin: 1em;
-}
-</style>
-<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 src="compressed-textures/4x4.rgb.dxt1.js"></script>
-<script src="compressed-textures/4x4.rgba.dxt1.js"></script>
-<script src="compressed-textures/4x4.rgba.dxt5.js"></script>
-<script src="compressed-textures/8x8.rgb.dxt1.js"></script>
-<script src="compressed-textures/8x8.rgba.dxt1.js"></script>
-<script src="compressed-textures/8x8.rgba.dxt5.js"></script>
-<script src="compressed-textures/8x8.rgba.pvrtc4bpp.js"></script>
-</head>
-<body>
-<div id="description"></div>
-<canvas id="canvas" width="8" height="8" style="width: 8px; height: 8px;"></canvas>
-<div id="console"></div>
-<!-- Shaders for testing standard derivatives -->
-<script>
-description("This test verifies the functionality of the OES_vertex_array_object extension, if it is available.");
-
-debug("");
-
-var wtu = WebGLTestUtils;
-var canvas = document.getElementById("canvas");
-var gl = wtu.create3DContext(canvas, {antialias: false});
-var program = wtu.setupTexturedQuad(gl);
-var ext = null;
-var vao = null;
-var validFormats = {
-  COMPRESSED_RGB_S3TC_DXT1_EXT        : 0x83F0,
-  COMPRESSED_RGBA_S3TC_DXT1_EXT       : 0x83F1,
-  COMPRESSED_RGBA_S3TC_DXT5_EXT       : 0x83F3,
-  ETC1_RGB8_OES                       : 0x8D64,
-  COMPRESSED_RGB_PVRTC_4BPPV1_IMG     : 0x8C00,
-  COMPRESSED_RGBA_PVRTC_4BPPV1_IMG    : 0x8C02
-};
-var name;
-var supportedFormats;
-
-if (!gl) {
-  testFailed("WebGL context does not exist");
-} else {
-  testPassed("WebGL context exists");
-
-  // Run tests with extension disabled
-  runTestDisabled();
-
-  // Query the extension and store globally so shouldBe can access it
-  ext = gl.getExtension("WEBGL_EXPERIMENTAL_compressed_textures");
-  if (!ext) {
-    testPassed("No WEBGL_EXPERIMENTAL_compressed_textures support -- this is legal");
-    runSupportedTest(false);
-  } else {
-    testPassed("Successfully enabled WEBGL_EXPERIMENTAL_compressed_textures extension");
-
-    runSupportedTest(true);
-    runTestExtension();
-  }
-}
-
-function runSupportedTest(extensionEnabled) {
-  var supported = gl.getSupportedExtensions();
-  if (supported.indexOf("WEBGL_EXPERIMENTAL_compressed_textures") >= 0) {
-    if (extensionEnabled) {
-      testPassed("WEBGL_EXPERIMENTAL_compressed_textures listed as supported and getExtension succeeded");
-    } else {
-      testFailed("WEBGL_EXPERIMENTAL_compressed_textures listed as supported but getExtension failed");
-    }
-  } else {
-    if (extensionEnabled) {
-      testFailed("WEBGL_EXPERIMENTAL_compressed_textures not listed as supported but getExtension succeeded");
-    } else {
-      testPassed("WEBGL_EXPERIMENTAL_compressed_textures not listed as supported and getExtension failed -- this is legal");
-    }
-  }
-}
-
-
-function runTestDisabled() {
-  debug("Testing binding enum with extension disabled");
-
-  // Default value is null
-  if (gl.getParameter(gl.COMPRESSED_TEXTURE_FORMATS) === null) {
-    testPassed("Default value of COMPRESSED_TEXTURE_FORMATS is null");
-  } else {
-    testFailed("Default value of COMPRESSED_TEXTURE_FORMATS is not null");
-  }
-}
-
-function checkIsValidFormat(format) {
-  for (var name in validFormats) {
-    if (format == validFormats[name]) {
-      testPassed("supported format " + formatToString(format) + " is valid");
-      return;
-    }
-  }
-  testFailed("supported format " + formatToString(format) + " is not valid");
-}
-
-function formatToString(format) {
-  for (var p in ext) {
-    if (ext[p] == format) {
-      return p;
-    }
-  }
-  return "0x" + format.toString(16);
-}
-
-function runTestExtension() {
-  debug("Testing WEBGL_EXPERIMENTAL_compressed_textures");
-
-  // check that all format enums exist.
-  for (name in validFormats) {
-    var expected = "0x" + validFormats[name].toString(16);
-    var actual = "ext['" + name + "']";
-    shouldBe(actual, expected);
-  }
-
-  supportedFormats = gl.getParameter(gl.COMPRESSED_TEXTURE_FORMATS);
-  // Even if no formats are supported this should return an array.
-  shouldBeTrue("supportedFormats.length !== undefined");
-
-  // check that each format is an allowed format
-  for (var ii = 0; ii < supportedFormats.length; ++ii) {
-    checkIsValidFormat(supportedFormats[ii]);
-  }
-
-  // Test each format
-  for (var ii = 0; ii < supportedFormats.length; ++ii) {
-    switch (supportedFormats[ii]) {
-    case ext.COMPRESSED_RGB_S3TC_DXT1_EXT:
-      testDXT1_RGB();
-      break;
-    case ext.COMPRESSED_RGBA_S3TC_DXT1_EXT:
-      testDXT1_RGBA();
-      break;
-    case ext.COMPRESSED_RGBA_S3TC_DXT5_EXT:
-      testDXT5_RGBA();
-      break;
-    case ext.ETC1_RGB8_OES:
-      testETC1_RGB8();
-      break;
-    case ext.COMPRESSED_RGB_PVRTC_4BPPV1_IMG:
-      testPVRTC_RGB_4BPPV1();
-      break;
-    case ext.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG:
-      testPVRTC_RGBA_4BPPV1();
-      break;
-    }
-  }
-}
-
-function testDXT1_RGB() {
-  var tests = [
-    { width: 4,
-      height: 4,
-      channels: 3,
-      data: img_4x4_rgb_dxt1,
-      format: ext.COMPRESSED_RGB_S3TC_DXT1_EXT
-    },
-    { width: 8,
-      height: 8,
-      channels: 3,
-      data: img_8x8_rgb_dxt1,
-      format: ext.COMPRESSED_RGB_S3TC_DXT1_EXT
-    }
-  ];
-  testDXTTextures(tests);
-}
-
-function testDXT1_RGBA() {
-  var tests = [
-    { width: 4,
-      height: 4,
-      channels: 4,
-      data: img_4x4_rgba_dxt1,
-      format: ext.COMPRESSED_RGBA_S3TC_DXT1_EXT
-    },
-    { width: 8,
-      height: 8,
-      channels: 4,
-      data: img_8x8_rgba_dxt1,
-      format: ext.COMPRESSED_RGBA_S3TC_DXT1_EXT
-    }
-  ];
-  testDXTTextures(tests);
-}
-
-function testDXT5_RGBA() {
-  var tests = [
-    { width: 4,
-      height: 4,
-      channels: 4,
-      data: img_4x4_rgba_dxt5,
-      format: ext.COMPRESSED_RGBA_S3TC_DXT5_EXT
-    },
-    { width: 8,
-      height: 8,
-      channels: 4,
-      data: img_8x8_rgba_dxt5,
-      format: ext.COMPRESSED_RGBA_S3TC_DXT5_EXT
-    }
-  ];
-  testDXTTextures(tests);
-}
-
-function testETC1_RGB8() {
-  testFailed("ETC1 test not yet implemented");
-}
-
-function testPVRTC_RGB_4BPPV1() {
-  var tests = [
-    { width: 8,
-      height: 8,
-      channels: 4,
-      data: img_8x8_rgba_pvrtc4bpp,
-      format: ext.COMPRESSED_RGB_PVRTC_4BPPV1_IMG
-    }
-  ];
-  testPVRTCTextures(tests);
-}
-
-function testPVRTC_RGB_4BPPV1() {
-  var tests = [
-    { width: 8,
-      height: 8,
-      channels: 4,
-      data: img_8x8_rgba_pvrtc4bpp,
-      format: ext.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG
-    }
-  ];
-  testPVRTCTextures(tests);
-}
-
-function testDXTTextures(tests) {
-  debug("<hr/>");
-  for (var ii = 0; ii < tests.length; ++ii) {
-    testDXTTexture(tests[ii]);
-  }
-}
-
-function uncompressDXTBlock(
-    destBuffer, destX, destY, destWidth, src, srcOffset, format) {
-  function make565(src, offset) {
-    return src[offset + 0] + src[offset + 1] * 256;
-  }
-  function make8888From565(c) {
-    return [
-        Math.floor(((c >> 11) & 0x1F) * 255 / 31),
-        Math.floor(((c >>  5) & 0x3F) * 255 / 63),
-        Math.floor(((c >>  0) & 0x1F) * 255 / 31),
-        255
-      ];
-  }
-  function mix(mult, c0, c1, div) {
-    var r = [];
-    for (var ii = 0; ii < c0.length; ++ii) {
-      r[ii] = Math.floor((c0[ii] * mult + c1[ii]) / div);
-    }
-    return r;
-  }
-  var colorOffset =
-      srcOffset + ((format == ext.COMPRESSED_RGBA_S3TC_DXT5_EXT) ? 8 : 0);
-  var color0 = make565(src, colorOffset + 0);
-  var color1 = make565(src, colorOffset + 2);
-  var c0gtc1 = color0 > color1 || format == ext.COMPRESSED_RGBA_S3TC_DXT5_EXT;
-  var rgba0 = make8888From565(color0);
-  var rgba1 = make8888From565(color1);
-  var colors = [
-      rgba0,
-      rgba1,
-      c0gtc1 ? mix(2, rgba0, rgba1, 3) : mix(1, rgba0, rgba1, 2),
-      c0gtc1 ? mix(2, rgba1, rgba0, 3) : [0, 0, 0, 255]
-    ];
-
-  // yea I know there is a lot of math in this inner loop.
-  // so sue me.
-  for (var yy = 0; yy < 4; ++yy) {
-    var pixels = src[colorOffset + 4 + yy];
-    for (var xx = 0; xx < 4; ++xx) {
-      var dstOff = ((destY + yy) * destWidth + destX + xx) * 4;
-      var code = (pixels >> (xx * 2)) & 0x3;
-      var srcColor = colors[code];
-      var alpha;
-      switch (format) {
-      case ext.COMPRESSED_RGB_S3TC_DXT1_EXT:
-        alpha = 255;
-        break;
-      case ext.COMPRESSED_RGBA_S3TC_DXT1_EXT:
-        alpha = (code == 3 && !c0gtc1) ? 0 : 255;
-        break;
-      case ext.COMPRESSED_RGBA_S3TC_DXT5_EXT:
-        {
-          var alpha0 = src[srcOffset + 0];
-          var alpha1 = src[srcOffset + 1];
-          var alphaOff = Math.floor(yy / 2) * 3 + 2;
-          var alphaBits =
-             src[srcOffset + alphaOff + 0] +
-             src[srcOffset + alphaOff + 1] * 256 +
-             src[srcOffset + alphaOff + 2] * 65536;
-          var alphaShift = (yy % 2) * 12 + xx * 3;
-          var alphaCode = (alphaBits >> alphaShift) & 0x7;
-          if (alpha0 > alpha1) {
-            switch (alphaCode) {
-            case 0:
-              alpha = alpha0;
-              break;
-            case 1:
-              alpha = alpha1;
-              break;
-            default:
-              alpha = ((8 - alphaCode) * alpha0 + (alphaCode - 1) * alpha1) / 7;
-              break;
-            }
-          } else {
-            switch (alphaCode) {
-            case 0:
-              alpha = alpha0;
-              break;
-            case 1:
-              alpha = alpha1;
-              break;
-            case 6:
-              alpha = 0;
-              break;
-            case 7:
-              alpha = 255;
-              break;
-            default:
-              alpha = ((6 - alphaCode) * alpha0 + (alphaCode - 1) * alpha1) / 5;
-              break;
-            }
-          }
-        }
-        break;
-      default:
-        throw "bad format";
-      }
-      destBuffer[dstOff + 0] = srcColor[0];
-      destBuffer[dstOff + 1] = srcColor[1];
-      destBuffer[dstOff + 2] = srcColor[2];
-      destBuffer[dstOff + 3] = alpha;
-    }
-  }
-}
-
-function uncompressDXT(width, height, data, format) {
-  if (width % 4 || height % 4) throw "bad width or height";
-
-  var dest = new Uint8Array(width * height * 4);
-  var blocksAcross = width / 4;
-  var blocksDown = height / 4;
-  var blockSize = (format == ext.COMPRESSED_RGBA_S3TC_DXT5_EXT ? 16 : 8);
-  for (var yy = 0; yy < blocksDown; ++yy) {
-    for (var xx = 0; xx < blocksAcross; ++xx) {
-      uncompressDXTBlock(
-        dest, xx * 4, yy * 4, width, data,
-        (yy * blocksAcross + xx) * blockSize, format);
-    }
-  }
-  return dest;
-}
-
-function testDXTTexture(test) {
-  var uncompressedData = uncompressDXT(
-      test.width, test.height, test.data, test.format);
-
-  var inner = 4; //test.width == 4 ? 4 : 1
-  for (var ii = 0; ii < inner; ++ii) {
-    var width = test.width - ii;
-    var height = test.height - ii;
-    canvas.width = width;
-    canvas.height = height;
-    gl.viewport(0, 0, width, height);
-    debug("testing " + formatToString(test.format) + " " +
-          width + "x" + height);
-    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);
-    ext.compressedTexImage2D(
-        gl.TEXTURE_2D, 0, test.format, width, height, 0,
-        new Uint8Array(test.data));
-    glErrorShouldBe(gl, gl.NO_ERROR, "uploading compressed texture");
-    wtu.drawQuad(gl);
-    compareRect(
-        width, height, test.channels, test.width, test.height, uncompressedData,
-        test.data, test.format);
-  }
-
-  gl.compressedTexImage2D(
-      gl.TEXTURE_2D, 0, test.format, width + 1, height, 0,
-      new Uint8Array(test.data));
-  glErrorShouldBe(
-      gl, gl.INVALID_OPERATION, "data size does not match dimensions");
-
-
-  // TODO: test compressedTexSubImage2D
-  // TODO: test invalid width, height, xoffset, yoffset
-}
-
-function insertImg(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);
-}
-
-function makeImage(imageWidth, imageHeight, dataWidth, data, alpha) {
-  var scale = 8;
-  var c = document.createElement("canvas");
-  c.width = imageWidth * scale;
-  c.height = imageHeight * scale;
-  var ctx = c.getContext("2d");
-  for (var yy = 0; yy < imageWidth; ++yy) {
-    for (var xx = 0; xx < imageHeight; ++xx) {
-      var offset = (yy * dataWidth + xx) * 4;
-      ctx.fillStyle = "rgba(" +
-          data[offset + 0] + "," +
-          data[offset + 1] + "," +
-          data[offset + 2] + "," +
-          (alpha ? data[offset + 3] / 255 : 1) + ")";
-      ctx.fillRect(xx * scale, yy * scale, scale, scale);
-    }
-  }
-  var img = document.createElement("img");
-  img.src = c.toDataURL();
-  return img;
-}
-function compareRect(
-    actualWidth, actualHeight, actualChannels,
-    dataWidth, dataHeight, expectedData,
-    testData, testFormat) {
-  var actual = new Uint8Array(actualWidth * actualHeight * 4);
-  gl.readPixels(
-      0, 0, actualWidth, actualHeight, gl.RGBA, gl.UNSIGNED_BYTE, actual);
-
-  var div = document.createElement("div");
-  div.className = "testimages";
-  insertImg(div, "expected", makeImage(
-      actualWidth, actualHeight, dataWidth, expectedData,
-      actualChannels == 4));
-  insertImg(div, "actual", makeImage(
-      actualWidth, actualHeight, actualWidth, actual,
-      actualChannels == 4));
-  div.appendChild(document.createElement('br'));
-  document.getElementById("console").appendChild(div);
-
-  var failed = false;
-  for (var yy = 0; yy < actualHeight; ++yy) {
-    for (var xx = 0; xx < actualWidth; ++xx) {
-      var actualOffset = (yy * actualWidth + xx) * 4;
-      var expectedOffset = (yy * dataWidth + xx) * 4;
-      var expected = [
-          expectedData[expectedOffset + 0],
-          expectedData[expectedOffset + 1],
-          expectedData[expectedOffset + 2],
-          (actualChannels == 3 ? 255 : expectedData[expectedOffset + 3])
-      ];
-      for (var jj = 0; jj < 4; ++jj) {
-        if (actual[actualOffset + jj] != expected[jj]) {
-          failed = true;
-          var was = actual[actualOffset + 0].toString();
-          for (j = 1; j < 4; ++j) {
-            was += "," + actual[actualOffset + j];
-          }
-          testFailed('at (' + xx + ', ' + yy +
-                     ') expected: ' + expected + ' was ' + was);
-        }
-      }
-    }
-  }
-  if (!failed) {
-    testPassed("texture rendered correctly");
-  }
-}
-
-function testPVRTCTextures() {
-  testFailed("PVRTC test not yet implemented");
-}
-
-debug("");
-successfullyParsed = true;
-</script>
-<script src="../../resources/js-test-post.js"></script>
-
-</body>
-</html>
--- a/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-acos.html
+++ b/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-acos.html
@@ -21,53 +21,74 @@ found in the LICENSE file.
 <script>
 
 var piConstants = [
   "const float kPI     = 3.14159265358979323846;",
   "const float kHalfPI = (kPI * 0.5);",
   "const float k2PI    = (kPI * 2.0);"
 ].join("\n");
 
-var asinImplementation = [
-  "float asin_impl(float v) {",
-  "  return v + (1.0 / 2.0) * pow(v, 3.0) / 3.0 +",
-  "             ((1.0 * 3.0) / (2.0 * 4.0)) * pow(v, 5.0) / 5.0 +",
-  "             ((1.0 * 3.0 * 5.0) / (2.0 * 4.0 * 6.0)) * pow(v, 7.0) / 7.0 +",
-  "             ((1.0 * 3.0 * 5.0 * 7.0) / (2.0 * 4.0 * 6.0 * 8.0)) * pow(v, 9.0) / 9.0;",
-  "}"
-].join("\n");
+var kPI = Math.PI;
+var kHalfPI = Math.PI * 0.5;
+var k2PI = Math.PI * 2.0;
+var acos = Math.acos;  // shorthand
 
-GLSLGenerator.runFeatureTest({
+GLSLGenerator.runReferenceImageTest({
   feature: "acos",
   args: "$(type) value",
-  baseArgs: "value$(field)",
   testFunc: "$(func)($(type))",
-  emuFunc: [
-    asinImplementation,
-    "float $(func)_base(float value) {",
-    "  return kHalfPI - asin_impl(value);",
-    "}"
-  ].join("\n"),
   gridRes: 8,
-  tolerance: 8,
+  tolerance: 2,
   extra: piConstants,
   tests: [
-    ["$(output) = vec4(",
-     "    $(func)($(input).x * 0.8) / kPI,",
-     "    $(func)($(input).y * 0.8) / kPI,",
-     "    0,",
-     "    1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xy * 0.8) / kPI,",
-     "    0, 1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xyz * 0.8) / kPI,",
-     "    1);"].join("\n"),
-    ["$(output) = ",
-     "    $(func)($(input) * 0.8) / kPI;",
-    ].join("\n")
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).x * 0.8) / kPI,",
+               "    $(func)($(input).y * 0.8) / kPI,",
+               "    0,",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ acos(x * 0.8) / kPI,
+                 acos(y * 0.8) / kPI,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xy * 0.8) / kPI,",
+               "    0, 1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ acos(x * 0.8) / kPI,
+                 acos(y * 0.8) / kPI,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xyz * 0.8) / kPI,",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ acos(x * 0.8) / kPI,
+                 acos(y * 0.8) / kPI,
+                 acos(z * 0.8) / kPI,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = ",
+               "    $(func)($(input) * 0.8) / kPI;",
+              ].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ acos(x * 0.8) / kPI,
+                 acos(y * 0.8) / kPI,
+                 acos(z * 0.8) / kPI,
+                 acos(w * 0.8) / kPI ];
+      },
+    },
   ]
 });
 successfullyParsed = true;
 </script>
 </body>
 </html>
 
--- a/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-asin.html
+++ b/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-asin.html
@@ -21,53 +21,74 @@ found in the LICENSE file.
 <script>
 
 var piConstants = [
   "const float kPI     = 3.14159265358979323846;",
   "const float kHalfPI = (kPI * 0.5);",
   "const float k2PI    = (kPI * 2.0);"
 ].join("\n");
 
-var asinImplementation = [
-  "float asin_impl(float v) {",
-  "  return v + (1.0 / 2.0) * pow(v, 3.0) / 3.0 +",
-  "             ((1.0 * 3.0) / (2.0 * 4.0)) * pow(v, 5.0) / 5.0 +",
-  "             ((1.0 * 3.0 * 5.0) / (2.0 * 4.0 * 6.0)) * pow(v, 7.0) / 7.0 +",
-  "             ((1.0 * 3.0 * 5.0 * 7.0) / (2.0 * 4.0 * 6.0 * 8.0)) * pow(v, 9.0) / 9.0;",
-  "}"
-].join("\n");
+var kPI = Math.PI;
+var kHalfPI = Math.PI * 0.5;
+var k2PI = Math.PI * 2.0;
+var asin = Math.asin;  // shorthand
 
-GLSLGenerator.runFeatureTest({
+GLSLGenerator.runReferenceImageTest({
   feature: "asin",
   args: "$(type) value",
-  baseArgs: "value$(field)",
   testFunc: "$(func)($(type))",
-  emuFunc: [
-    asinImplementation,
-    "float $(func)_base(float value) {",
-    "  return asin_impl(value);",
-    "}"
-  ].join("\n"),
   gridRes: 8,
   tolerance: 2,
   extra: piConstants,
   tests: [
-    ["$(output) = vec4(",
-     "    $(func)($(input).x * 0.8) / kPI + 0.5,",
-     "    $(func)($(input).y * 0.8) / kPI + 0.5,",
-     "    0,",
-     "    1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xy * 0.8) / kPI + 0.5,",
-     "    0, 1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xyz * 0.8) / kPI + 0.5,",
-     "    1);"].join("\n"),
-    ["$(output) = ",
-     "    $(func)($(input) * 0.8) / kPI + 0.5;",
-    ].join("\n")
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).x * 0.8) / kPI + 0.5,",
+               "    $(func)($(input).y * 0.8) / kPI + 0.5,",
+               "    0,",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ asin(x * 0.8) / kPI + 0.5,
+                 asin(y * 0.8) / kPI + 0.5,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xy * 0.8) / kPI + 0.5,",
+               "    0, 1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ asin(x * 0.8) / kPI + 0.5,
+                 asin(y * 0.8) / kPI + 0.5,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xyz * 0.8) / kPI + 0.5,",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ asin(x * 0.8) / kPI + 0.5,
+                 asin(y * 0.8) / kPI + 0.5,
+                 asin(z * 0.8) / kPI + 0.5,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = ",
+               "    $(func)($(input) * 0.8) / kPI + 0.5;",
+              ].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ asin(x * 0.8) / kPI + 0.5,
+                 asin(y * 0.8) / kPI + 0.5,
+                 asin(z * 0.8) / kPI + 0.5,
+                 asin(w * 0.8) / kPI + 0.5 ];
+      },
+    },
   ]
 });
 successfullyParsed = true;
 </script>
 </body>
 </html>
 
--- a/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-atan-xy.html
+++ b/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-atan-xy.html
@@ -21,84 +21,77 @@ found in the LICENSE file.
 <script>
 
 var piConstants = [
   "const float kPI     = 3.14159265358979323846;",
   "const float kHalfPI = (kPI * 0.5);",
   "const float k2PI    = (kPI * 2.0);"
 ].join("\n");
 
-var atanImplementation = [
-  "const float kEpsilon = 0.0001;",
-  "",
-  "float atan_impl(float y, float x) {",
-  "  float atan_value = 0.0;",
-  "  float scale = 1.0;",
-  "  float sign = 1.0;",
-  "",
-  "  if (x > kEpsilon || abs(y) > kEpsilon) {",
-  "    if (x < 0.0 ^^ y < 0.0) {",
-  "      sign = -1.0;",
-  "    }",
-  "",
-  "    bool y_gt_x = abs(y) < abs(x);",
-  "    float value = y_gt_x ? abs(y / x) : abs(x / y);",
-  "",
-  "    // Use Taylors series expansion for atan",
-  "    for(int ii = 1; ii < 8; ii += 2) {",
-  "      atan_value += scale * pow(value, float(ii)) / float(ii);",
-  "      scale = -scale;",
-  "    }",
-  "",
-  "    atan_value = (y_gt_x) ? sign * atan_value : sign * (kHalfPI - atan_value);",
-  "  }",
-  "",
-  "  if (x < 0.0) {",
-  "    if (y < 0.0) {",
-  "      atan_value -= kHalfPI;",
-  "    } else if (y > 0.0) {",
-  "      atan_value += kHalfPI;",
-  "    }",
-  "  }",
-  "",
-  "  return atan_value;",
-  "}"
-].join("\n");
+var kPI = Math.PI;
+var kHalfPI = Math.PI * 0.5;
+var k2PI = Math.PI * 2.0;
+var atan2 = Math.atan2;  // shorthand
 
-GLSLGenerator.runFeatureTest({
+GLSLGenerator.runReferenceImageTest({
   feature: "atan",
   args: "$(type) y, $(type) x",
-  baseArgs: "y$(field), x$(field)",
   testFunc: "$(func)($(type), $(type))",
-  emuFunc: [
-    atanImplementation,
-    "float $(func)_base(float y, float x) {",
-    "  return atan_impl(y, x);",
-    "}"
-  ].join("\n"),
   gridRes: 8,
-  tolerance: 4,
+  tolerance: 5,
   extra: piConstants,
   tests: [
-    ["$(output) = vec4(",
-     "    $(func)($(input).x + 0.1, $(input).y) / k2PI + 0.5,",
-     "    0,",
-     "    0,",
-     "    1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xy + vec2(0.1, 0.1), $(input).yx) / ",
-     "            k2PI + vec2(0.5, 0.5),",
-     "    0, 1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xyz + vec3(0.1, 0.1, 0.1), $(input).yzx) / ",
-     "            k2PI + vec3(0.5, 0.5, 0.5),",
-     "    1);"].join("\n"),
-    ["$(output) = ",
-     "    $(func)($(input) + vec4(0.1, 0.1, 0.1, 0.1), $(input).wzyx) / ",
-     "            k2PI + vec4(0.5, 0.5, 0.5, 0.5);",
-    ].join("\n")
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).x + 0.1, $(input).y) / k2PI + 0.5,",
+               "    0,",
+               "    0,",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ atan2(x + 0.1, y) / k2PI + 0.5,
+                 0,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xy + vec2(0.1, 0.1), $(input).yx) / ",
+               "            k2PI + vec2(0.5, 0.5),",
+               "    0, 1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ atan2(x + 0.1, y) / k2PI + 0.5,
+                 atan2(y + 0.1, x) / k2PI + 0.5,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xyz + vec3(0.1, 0.1, 0.1), $(input).yzx) / ",
+               "            k2PI + vec3(0.5, 0.5, 0.5),",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ atan2(x + 0.1, y) / k2PI + 0.5,
+                 atan2(y + 0.1, z) / k2PI + 0.5,
+                 atan2(z + 0.1, x) / k2PI + 0.5,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = ",
+               "    $(func)($(input) + vec4(0.1, 0.1, 0.1, 0.1), $(input).wzyx) / ",
+               "            k2PI + vec4(0.5, 0.5, 0.5, 0.5);",
+              ].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ atan2(x + 0.1, w) / k2PI + 0.5,
+                 atan2(y + 0.1, z) / k2PI + 0.5,
+                 atan2(z + 0.1, y) / k2PI + 0.5,
+                 atan2(w + 0.1, x) / k2PI + 0.5 ];
+      },
+    },
   ]
 });
 successfullyParsed = true;
 </script>
 </body>
 </html>
 
--- a/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-atan.html
+++ b/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-atan.html
@@ -21,68 +21,74 @@ found in the LICENSE file.
 <script>
 
 var piConstants = [
   "const float kPI     = 3.14159265358979323846;",
   "const float kHalfPI = (kPI * 0.5);",
   "const float k2PI    = (kPI * 2.0);"
 ].join("\n");
 
-var atanImplementation = [
-  "float atan_impl(float value) {",
-  "  float atan_value = 0.0;",
-  "  float scale = 1.0;",
-  "  float sign = 1.0;",
-  "",
-  "  if (value < 0.0) {",
-  "    sign = -1.0;",
-  "    value = -value;",
-  "  }",
-  "",
-  "  bool value_le_1 = value <= 1.0;",
-  "  value = value_le_1 ? value : 1.0 / value;",
-  "",
-  "  // Use Taylors series expansion for atan",
-  "  for(int ii = 1; ii < 8; ii += 2) {",
-  "    atan_value += scale * pow(value, float(ii)) / float(ii);",
-  "    scale = -scale;",
-  "  }",
-  "",
-  "  return value_le_1 ? sign * atan_value : sign * (kHalfPI - atan_value);",
-  "}",
-].join("\n");
+var kPI = Math.PI;
+var kHalfPI = Math.PI * 0.5;
+var k2PI = Math.PI * 2.0;
+var atan = Math.atan;  // shorthand
 
-GLSLGenerator.runFeatureTest({
+GLSLGenerator.runReferenceImageTest({
   feature: "atan",
   args: "$(type) value",
-  baseArgs: "value$(field)",
   testFunc: "$(func)($(type))",
-  emuFunc: [
-    atanImplementation,
-    "",
-    "#define $(func)_base(value) atan_impl(value)"
-  ].join("\n"),
   gridRes: 8,
   tolerance: 4,
   extra: piConstants,
   tests: [
-    ["$(output) = vec4(",
-     "    $(func)($(input).x * 8.0 - 4.0) / k2PI + 0.5,",
-     "    0.5,",
-     "    0,",
-     "    1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xy * 8.0 - vec2(4, 4)) / k2PI + vec2(0.5, 0.5),",
-     "    0, 1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xyz * 8.0 - vec3(4, 4, 4)) / k2PI + vec3(0.5, 0.5, 0.5),",
-
-     "    1);"].join("\n"),
-    ["$(output) = ",
-     "    $(func)($(input) * 8.0 - vec4(4, 4, 4, 4)) / k2PI + vec4(0.5, 0.5, 0.5, 0.5);",
-    ].join("\n")
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).x * 8.0 - 4.0) / k2PI + 0.5,",
+               "    0.5,",
+               "    0,",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ atan(x * 8.0 - 4.0) / k2PI + 0.5,
+                 0.5,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xy * 8.0 - vec2(4, 4)) / k2PI + vec2(0.5, 0.5),",
+               "    0, 1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ atan(x * 8.0 - 4) / k2PI + 0.5,
+                 atan(y * 8.0 - 4) / k2PI + 0.5,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xyz * 8.0 - vec3(4, 4, 4)) / k2PI + vec3(0.5, 0.5, 0.5),",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ atan(x * 8.0 - 4) / k2PI + 0.5,
+                 atan(y * 8.0 - 4) / k2PI + 0.5,
+                 atan(z * 8.0 - 4) / k2PI + 0.5,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = ",
+               "    $(func)($(input) * 8.0 - vec4(4, 4, 4, 4)) / k2PI + vec4(0.5, 0.5, 0.5, 0.5);",
+              ].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ atan(x * 8.0 - 4) / k2PI + 0.5,
+                 atan(y * 8.0 - 4) / k2PI + 0.5,
+                 atan(z * 8.0 - 4) / k2PI + 0.5,
+                 atan(w * 8.0 - 4) / k2PI + 0.5 ];
+      },
+    },
   ]
 });
 successfullyParsed = true;
 </script>
 </body>
 </html>
 
--- a/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-cos.html
+++ b/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-cos.html
@@ -21,62 +21,78 @@ found in the LICENSE file.
 <script>
 
 var piConstants = [
   "const float kPI     = 3.14159265358979323846;",
   "const float kHalfPI = (kPI * 0.5);",
   "const float k2PI    = (kPI * 2.0);"
 ].join("\n");
 
-var sinImplementation = [
-  "",
-  "float sin_impl(float value) {",
-  "    value = mod(value + k2PI * 10.0, k2PI);",          // only positive values for now
-  "    int quad = int(floor(value / kHalfPI));",          // figure out which quad
-  "    float p = mod(value, kHalfPI);",                   // from 0.0 to PI/2
-  "    if (quad == 1 || quad == 3) { p = kHalfPI - p; }", // backward in quads 1,3
-  "    float c = p - ",
-  "              pow(p, 3.0) / (1.0 * 2.0 * 3.0) + ",
-  "              pow(p, 5.0) / (1.0 * 2.0 * 3.0 * 4.0 * 5.0) - ",
-  "              pow(p, 7.0) / (1.0 * 2.0 * 3.0 * 4.0 * 5.0 * 6.0 * 7.0);",
-  "    if (quad == 2 || quad == 3) { c = -c; }",
-  "    return c;",
-  "}"
-].join('\n');
+var kPI = Math.PI;
+var kHalfPI = Math.PI * 0.5;
+var k2PI = Math.PI * 2.0;
+var cos = Math.cos;  // shorthand
 
-GLSLGenerator.runFeatureTest({
+GLSLGenerator.runReferenceImageTest({
   feature: "cos",
   args: "$(type) value",
-  baseArgs: "value$(field)",
   testFunc: "$(func)($(type))",
-  emuFunc: [
-    sinImplementation,
-    "float $(func)_base(float value) {",
-    "  return sin_impl(value + kHalfPI);",
-    "}"
-  ].join("\n"),
   gridRes: 8,
   tolerance: 2,
   extra: piConstants,
   tests: [
-    ["$(output) = vec4(",
-     "    $(func)($(input).x * kHalfPI + kHalfPI),",
-     "    $(func)($(input).y * kHalfPI),",
-     "    0,",
-     "    1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xy * vec2(kPI, k2PI)) * 0.5 + vec2(0.5, 0.5),",
-     "    0, 1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xyz * vec3(kPI, k2PI, 4.0)) * ",
-     "    0.5 + vec3(0.5, 0.5, 0.5),",
-     "    1);"].join("\n"),
-    ["$(output) = ",
-     "    $(func)($(input) * vec4(k2PI, 4.0, kHalfPI, kPI)) *",
-     "    0.5 + vec4(0.5, 0.5, 0.5, 1);",
-    ].join("\n")
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).x * kHalfPI + kHalfPI),",
+               "    $(func)($(input).y * kHalfPI),",
+               "    0,",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+	return [ cos(x * kHalfPI + kHalfPI),
+		 cos(y * kHalfPI),
+		 0,
+		 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+	       "    $(func)($(input).xy * vec2(kPI, k2PI)) * 0.5 + vec2(0.5, 0.5),",
+	       "    0, 1);"].join("\n"),
+      generator: function(x, y, z, w) {
+	return [ cos(x * kPI) * 0.5 + 0.5,
+		 cos(y * k2PI) * 0.5 + 0.5,
+		 0,
+		 1 ];
+      },
+    },
+    {
+      // FIXME: for some reason, this test requires a higher tolerance when run in a vertex shader.
+      source: ["$(output) = vec4(",
+	       "    $(func)($(input).xyz * vec3(kPI, k2PI, 4.0)) * ",
+	       "    0.5 + vec3(0.5, 0.5, 0.5),",
+	       "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+	return [ cos(x * kPI) * 0.5 + 0.5,
+		 cos(y * k2PI) * 0.5 + 0.5,
+		 cos(z * 4.0) * 0.5 + 0.5,
+		 1 ];
+      },
+      tolerance: 7,
+    },
+    {
+      source: ["$(output) = ",
+	       "    $(func)($(input) * vec4(k2PI, 4.0, kHalfPI, kPI)) *",
+	       "    0.5 + vec4(0.5, 0.5, 0.5, 1);",
+	      ].join("\n"),
+      generator: function(x, y, z, w) {
+	return [ cos(x * k2PI) * 0.5 + 0.5,
+		 cos(y * 4.0) * 0.5 + 0.5,
+		 cos(z * kHalfPI) * 0.5 + 0.5,
+		 cos(w * kPI) * 0.5 + 1.0 ];
+      },
+    },
   ]
 });
 successfullyParsed = true;
 </script>
 </body>
 </html>
 
--- a/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-sin.html
+++ b/content/canvas/test/webgl/conformance/glsl/functions/glsl-function-sin.html
@@ -21,62 +21,75 @@ found in the LICENSE file.
 <script>
 
 var piConstants = [
   "const float kPI     = 3.14159265358979323846;",
   "const float kHalfPI = (kPI * 0.5);",
   "const float k2PI    = (kPI * 2.0);"
 ].join("\n");
 
-var sinImplementation = [
-  "",
-  "float sin_impl(float value) {",
-  "    value = mod(value + k2PI * 10.0, k2PI);",          // only positive values for now
-  "    int quad = int(floor(value / kHalfPI));",          // figure out which quad
-  "    float p = mod(value, kHalfPI);",                   // from 0.0 to PI/2
-  "    if (quad == 1 || quad == 3) { p = kHalfPI - p; }", // backward in quads 1,3
-  "    float c = p - ",
-  "              pow(p, 3.0) / (1.0 * 2.0 * 3.0) + ",
-  "              pow(p, 5.0) / (1.0 * 2.0 * 3.0 * 4.0 * 5.0) - ",
-  "              pow(p, 7.0) / (1.0 * 2.0 * 3.0 * 4.0 * 5.0 * 6.0 * 7.0);",
-  "    if (quad == 2 || quad == 3) { c = -c; }",
-  "    return c;",
-  "}"
-].join('\n');
+var kPI = Math.PI;
+var kHalfPI = Math.PI * 0.5;
+var k2PI = Math.PI * 2.0;
+var sin = Math.sin;  // shorthand
 
-GLSLGenerator.runFeatureTest({
+GLSLGenerator.runReferenceImageTest({
   feature: "sin",
   args: "$(type) value",
-  baseArgs: "value$(field)",
   testFunc: "$(func)($(type))",
-  emuFunc: [
-    sinImplementation,
-    "float $(func)_base(float value) {",
-    "  return sin_impl(value);",
-    "}"
-  ].join("\n"),
   gridRes: 8,
-  tolerance: 2,
+  tolerance: 4,
   extra: piConstants,
   tests: [
-    ["$(output) = vec4(",
-     "    $(func)($(input).x * kHalfPI + kHalfPI),",
-     "    $(func)($(input).y * kHalfPI),",
-     "    0,",
-     "    1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xy * vec2(kPI, k2PI)) * 0.5 + vec2(0.5, 0.5),",
-     "    0, 1);"].join("\n"),
-    ["$(output) = vec4(",
-     "    $(func)($(input).xyz * vec3(kPI, k2PI, 4.0)) * ",
-     "    0.5 + vec3(0.5, 0.5, 0.5),",
-     "    1);"].join("\n"),
-    ["$(output) = ",
-     "    $(func)($(input) * vec4(k2PI, 4.0, kHalfPI, kPI)) *",
-     "    0.5 + vec4(0.5, 0.5, 0.5, 1);",
-    ].join("\n")
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).x * kHalfPI + kHalfPI),",
+               "    $(func)($(input).y * kHalfPI),",
+               "    0,",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ sin(x * kHalfPI + kHalfPI),
+                 sin(y * kHalfPI),
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xy * vec2(kPI, k2PI)) * 0.5 + vec2(0.5, 0.5),",
+               "    0, 1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ sin(x * kPI) * 0.5 + 0.5,
+                 sin(y * k2PI) * 0.5 + 0.5,
+                 0,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = vec4(",
+               "    $(func)($(input).xyz * vec3(kPI, k2PI, 4.0)) * ",
+               "    0.5 + vec3(0.5, 0.5, 0.5),",
+               "    1);"].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ sin(x * kPI) * 0.5 + 0.5,
+                 sin(y * k2PI) * 0.5 + 0.5,
+                 sin(z * 4.0) * 0.5 + 0.5,
+                 1 ];
+      },
+    },
+    {
+      source: ["$(output) = ",
+               "    $(func)($(input) * vec4(k2PI, 4.0, kHalfPI, kPI)) *",
+               "    0.5 + vec4(0.5, 0.5, 0.5, 1);",
+              ].join("\n"),
+      generator: function(x, y, z, w) {
+        return [ sin(x * k2PI) * 0.5 + 0.5,
+                 sin(y * 4.0) * 0.5 + 0.5,
+                 sin(z * kHalfPI) * 0.5 + 0.5,
+                 sin(w * kPI) * 0.5 + 1 ];
+      },
+    },
   ]
 });
 successfullyParsed = true;
 </script>
 </body>
 </html>
-
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_int_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_int_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_int_mat4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_int_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_ivec2_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_ivec2_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_ivec3_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_ivec3_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/add_ivec4_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/add_ivec4_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/assign_int_to_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/assign_int_to_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec2_to_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec2_to_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec3_to_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec3_to_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec4_to_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/assign_ivec4_to_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/construct_struct.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/construct_struct.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_mat4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_int_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec2_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec2_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec3_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec3_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec4_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/divide_ivec4_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/equal_int_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/equal_int_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec2_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec2_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec3_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec3_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec4_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/equal_ivec4_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/function_int_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/function_int_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/function_ivec2_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/function_ivec2_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/function_ivec3_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/function_ivec3_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/function_ivec4_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/function_ivec4_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/greater_than.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/greater_than.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/greater_than_equal.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/greater_than_equal.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/less_than.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/less_than.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/less_than_equal.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/less_than_equal.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_mat4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_int_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec2_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec2_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec3_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec3_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec4_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/multiply_ivec4_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/not_equal_int_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/not_equal_int_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec2_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec2_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec3_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec3_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec4_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/not_equal_ivec4_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_mat4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_int_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec2_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec2_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec3_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec3_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec4_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/subtract_ivec4_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/ternary_int_float.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/ternary_int_float.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec2_vec2.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec2_vec2.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec3_vec3.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec3_vec3.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec4_vec4.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/implicit/ternary_ivec4_vec4.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/00_test_list.txt
+++ b/content/canvas/test/webgl/conformance/glsl/misc/00_test_list.txt
@@ -1,17 +1,18 @@
 attrib-location-length-limits.html
 embedded-struct-definitions-forbidden.html
 # this test is intentionally disabled as it is too strict and to hard to simulate
 # glsl-2types-of-textures-on-same-unit.html
 glsl-function-nodes.html
+--min-version 1.0.2 glsl-vertex-branch.html
 glsl-long-variable-names.html
 non-ascii-comments.vert.html
 non-ascii.vert.html
-
+--min-version 1.0.2 re-compile-re-link.html
 shader-with-256-character-identifier.frag.html
 shader-with-257-character-identifier.frag.html
 shader-with-_webgl-identifier.vert.html
 shader-with-arbitrary-indexing.frag.html
 shader-with-arbitrary-indexing.vert.html
 shader-with-attrib-array.vert.html
 shader-with-attrib-struct.vert.html
 shader-with-clipvertex.vert.html
@@ -26,16 +27,18 @@ shader-with-error-directive.html
 shader-with-explicit-int-cast.vert.html
 shader-with-float-return-value.frag.html
 --min-version 1.0.2 shader-with-for-scoping.html
 --min-version 1.0.2 shader-with-for-loop.html
 shader-with-frag-depth.frag.html
 shader-with-function-recursion.frag.html
 --min-version 1.0.2 shader-with-function-scoped-struct.html
 --min-version 1.0.2 shader-with-functional-scoping.html
+--min-version 1.0.2 shader-with-comma-assignment.html
+--min-version 1.0.2 shader-with-comma-conditional-assignment.html
 shader-with-glcolor.vert.html
 shader-with-gles-1.frag.html
 shader-with-gles-symbol.frag.html
 shader-with-glprojectionmatrix.vert.html
 shader-with-implicit-vec3-to-vec4-cast.vert.html
 shader-with-include.vert.html
 shader-with-int-return-value.frag.html
 shader-with-invalid-identifier.frag.html
--- a/content/canvas/test/webgl/conformance/glsl/misc/attrib-location-length-limits.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/attrib-location-length-limits.html
@@ -1,14 +1,15 @@
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL attrib location length tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.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="50" height="50">
 There is supposed to be an example drawing here, but it's not important.
 </canvas>
@@ -41,17 +42,17 @@ void main() {
 </script>
 <script>
 if (window.initNonKhronosFramework) {
     window.initNonKhronosFramework(false);
 }
 description("test attrib location length limit");
 
 var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext(document.getElementById("example"));
+var gl = wtu.create3DContext("example");
 
 debug("Test attrib location underneath the length limit");
 var program = wtu.loadProgramFromScript(gl, "goodVertexShader", "fragmentShader");
 shouldBe('gl.getProgramParameter(program, gl.LINK_STATUS)', 'true');
 var attribLoc = gl.getAttribLocation(program, "vPosition0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456");
 if (attribLoc == -1) {
     testFailed("attrib location was -1, should not be");
 } else {
--- a/content/canvas/test/webgl/conformance/glsl/misc/embedded-struct-definitions-forbidden.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/embedded-struct-definitions-forbidden.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/glsl-function-nodes.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/glsl-function-nodes.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
  -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>GLSL function nodes Test</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.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="vshaderFunction", type="x-shader/x-vertex">
 attribute vec4 aPosition;
 varying vec4 vColor;
 
new file mode 100644
--- /dev/null
+++ b/content/canvas/test/webgl/conformance/glsl/misc/glsl-vertex-branch.html
@@ -0,0 +1,130 @@
+<!--
+Copyright (c) 2011 The Chromium Authors. All rights reserved.
+Use of this source code is governed by a BSD-style license that can be
+found in the LICENSE file.
+ -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>GLSL function nodes Test</title>
+<link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.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="vshaderNoBranch", type="x-shader/x-vertex">
+attribute vec3 aPosition;
+uniform float redIntensity;
+
+varying vec4 vColor;
+
+float MADBug(float paramValue) {
+  float localVar = 1.0;
+  return 0.25 * ceil(localVar) + paramValue;
+}
+
+void main(void) {
+    gl_Position = vec4(aPosition, 1.0);
+    vColor = vec4(MADBug(redIntensity), 0., 0., 1.);
+}
+</script>
+
+<script id="vshaderBranch", type="x-shader/x-vertex">
+attribute vec3 aPosition;
+uniform float redIntensity;
+
+varying vec4 vColor;
+
+float MADBug(float paramValue) {
+  float localVar = 1.0;
+  return 0.25 * ceil(localVar) + paramValue;
+}
+
+void main(void) {
+    float condition = 42.;
+    if (condition == 0.) {}
+    gl_Position = vec4(aPosition, 1.0);
+    vColor = vec4(MADBug(redIntensity), 0., 0., 1.);
+}
+</script>
+
+<script id="fshader", type="x-shader/x-fragment">
+#if defined(GL_ES)
+precision mediump float;
+#endif
+varying vec4 vColor;
+void main()
+{
+   gl_FragColor = vColor;
+}
+</script>
+</head>
+<body>
+<canvas id="canvasNoBranch" width="50" height="50"></canvas>
+<canvas id="canvasBranch" width="50" height="50"></canvas>
+<div id="description">This tests against a Mac driver bug related to branches
+ inside of Vertex Shaders.</div>
+<div id="console"></div>
+<script>
+var width = 50;
+var height = 50;
+
+function drawAndRead(canvasID, vshaderID, buffer)
+{
+    var gl = initWebGL(canvasID, vshaderID, "fshader", ["aPosition"], [0, 0, 0, 1], 1);
+    var vertexObject = gl.createBuffer();
+    gl.bindBuffer(gl.ARRAY_BUFFER, vertexObject);
+    gl.bufferData(gl.ARRAY_BUFFER, new Float32Array([ 0,0.5,0, -1,-1,0, 1,-1,0 ]), gl.STATIC_DRAW);
+    gl.enableVertexAttribArray(0);
+    gl.vertexAttribPointer(0, 3, gl.FLOAT, false, 0, 0);
+
+    var loc = gl.getUniformLocation(gl.program, "redIntensity");
+    gl.uniform1f(loc, 0.75);
+    gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);
+    gl.drawArrays(gl.TRIANGLES, 0, 3);
+    gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, buffer);
+    if (gl.getError() != gl.NO_ERROR)
+        return false;
+    return true;
+}
+
+function compareRendering(buffer1, buffer2, tol)
+{
+    for (var i = 0; i < width * height * 4; ++i) {
+        if (Math.abs(buffer1[i] - buffer2[i]) > tol)
+            return false;
+    }
+    return true;
+}
+
+function init()
+{
+    if (window.initNonKhronosFramework) {
+        window.initNonKhronosFramework(false);
+    }
+
+    description("tests vertex shader with branch");
+
+    var bufBranch = new Uint8Array(width * height * 4);
+    var bufNoBranch = new Uint8Array(width * height * 4);
+
+    if (drawAndRead("canvasBranch", "vshaderBranch", bufBranch) == false ||
+        drawAndRead("canvasNoBranch", "vshaderNoBranch", bufNoBranch) == false) {
+        testFailed("Setup failed");
+    } else {
+        if (compareRendering(bufBranch, bufNoBranch, 4) == false)
+            testFailed("Rendering results are different");
+        else
+            testPassed("Rendering results are the same");
+    }
+}
+
+init();
+successfullyParsed = true;
+</script>
+<script src="../../../resources/js-test-post.js"></script>
+</body>
+</html>
+
--- a/content/canvas/test/webgl/conformance/glsl/misc/non-ascii-comments.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/non-ascii-comments.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/non-ascii.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/non-ascii.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
new file mode 100644
--- /dev/null
+++ b/content/canvas/test/webgl/conformance/glsl/misc/re-compile-re-link.html
@@ -0,0 +1,151 @@
+<!--
+Copyright (c) 2012 The Chromium Authors. All rights reserved.
+Use of this source code is governed by a BSD-style license that can be
+found in the LICENSE file.
+ -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Re-Compile and Re-link Shader 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 float column;
+attribute float height;
+uniform float position;
+void main() {
+  gl_Position = vec4(mod(column - position, 1.0) * 2.0 - 1.0, height, 0, 1);
+}
+</script>
+
+<script id="fshader1" type="x-shader/x-fragment">
+precision mediump float;
+void main() {
+  gl_FragColor = vec4(1,0,0,1);
+}
+</script>
+<script id="fshader2" type="x-shader/x-fragment">
+precision mediump float;
+uniform float foobar;
+void main() {
+  gl_FragColor = vec4(1,0,foobar,1);
+}
+</script>
+<script id="vshaderB" type="not-js">
+attribute vec2 position;
+varying vec2 v_texCoord;
+void main() {
+  gl_Position = vec4(position, 0, 1);
+  v_texCoord = vec2(position * 0.5 + 0.5);
+}
+</script>
+<script id="fshaderB" type="not-js">
+precision mediump float;
+varying vec2 v_texCoord;
+uniform sampler2D tex;
+void main() {
+  gl_FragColor = texture2D(tex, v_texCoord);
+}
+</script>
+
+<script>
+description(document.title);
+var wtu = WebGLTestUtils;
+var gl = wtu.create3DContext("example");
+
+var vsSource = document.getElementById("vshader").text;
+var fs1Source = document.getElementById("fshader1").text;
+var fs2Source = document.getElementById("fshader2").text;
+
+var vsSourceB = document.getElementById("vshaderB").text;
+var fsSourceB = document.getElementById("fshaderB").text;
+
+var vShader = gl.createShader(gl.VERTEX_SHADER);
+var fShader = gl.createShader(gl.FRAGMENT_SHADER);
+
+var vShaderB = gl.createShader(gl.VERTEX_SHADER);
+var fShaderB = gl.createShader(gl.FRAGMENT_SHADER);
+
+var program = gl.createProgram();
+var programB = gl.createProgram();
+
+gl.attachShader(program, vShader);
+gl.attachShader(program, fShader);
+
+gl.attachShader(programB, vShaderB);
+gl.attachShader(programB, fShaderB);
+
+var success;
+var shader;
+
+function checkShaderStatus(s) {
+  shader = s;
+  shouldBeTrue("success = gl.getShaderParameter(shader, gl.COMPILE_STATUS)");
+  if (!success) {
+    debug("error: " + gl.getShaderInfoLog());
+  }
+}
+
+var prg;
+function checkProgramStatus(p) {
+  prg = p;
+  shouldBeTrue("success = gl.getProgramParameter(prg, gl.LINK_STATUS)");
+  if (!success) {
+    debug("error: " + gl.getProgramInfoLog(prg));
+  }
+}
+
+for (var i = 0; i < 10; ++i) {
+  gl.shaderSource(vShader, vsSource);
+  gl.compileShader(vShader);
+  checkShaderStatus(vShader)
+  gl.shaderSource(fShader, fs1Source);
+  gl.compileShader(fShader);
+  checkShaderStatus(fShader)
+
+  gl.linkProgram(program);
+  checkProgramStatus(program)
+  gl.useProgram(program);
+
+  gl.shaderSource(vShaderB, vsSourceB);
+  gl.compileShader(vShaderB);
+  checkShaderStatus(vShaderB)
+  gl.shaderSource(fShaderB, fsSourceB);
+  gl.compileShader(fShaderB);
+  checkShaderStatus(fShaderB)
+
+  gl.linkProgram(programB);
+  checkProgramStatus(programB)
+
+  gl.useProgram(programB);
+}
+
+for (var i = 0; i < 10; ++i) {
+  // Now change the fragment shader
+  gl.shaderSource(fShader, fs2Source);
+  gl.compileShader(fShader);
+  checkShaderStatus(fShader)
+
+  // And re-link
+  gl.linkProgram(program);
+  checkProgramStatus(program)
+}
+
+glErrorShouldBe(gl, gl.NO_ERROR, "Should be no errors");
+
+successfullyParsed = true;
+</script>
+<script src="../../../resources/js-test-post.js"></script>
+
+</body>
+</html>
+
+
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-256-character-identifier.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-256-character-identifier.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-257-character-identifier.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-257-character-identifier.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-_webgl-identifier.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-_webgl-identifier.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-arbitrary-indexing.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-arbitrary-indexing.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-arbitrary-indexing.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-arbitrary-indexing.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-attrib-array.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-attrib-array.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-attrib-struct.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-attrib-struct.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-clipvertex.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-clipvertex.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
new file mode 100644
--- /dev/null
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-comma-assignment.html
@@ -0,0 +1,41 @@
+<!--
+Copyright (c) 2011 The Chromium Authors. All rights reserved.
+Use of this source code is governed by a BSD-style license that can be
+found in the LICENSE file.
+-->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL Conformance Tests</title>
+<link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
+<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../resources/webgl-test-utils.js"></script>
+<script src="../../resources/glsl-conformance-test.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<script id="fragmentShader" type="text/something-not-javascript">
+// fragment shader with comma assignment should succeed
+precision mediump float;
+void main() {
+  float a = 0.0;
+  float b = 0.0;
+  float c = 0.0;
+  float d = 0.0;
+  a = 1.1, b = 3.1;
+  c = 2.1, d = 4.1;
+  // Output green if successful, red if not.
+  gl_FragColor = ((a + b + c + d > 10.0) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script>
+GLSLConformanceTester.runRenderTest();
+successfullyParsed = true;
+</script>
+</body>
+</html>
+
+
new file mode 100644
--- /dev/null
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-comma-conditional-assignment.html
@@ -0,0 +1,200 @@
+<!--
+Copyright (c) 2011 The Chromium Authors. All rights reserved.
+Use of this source code is governed by a BSD-style license that can be
+found in the LICENSE file.
+-->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL Conformance Tests</title>
+<link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
+<script src="../../../resources/js-test-pre.js"></script>
+<script src="../../resources/webgl-test-utils.js"></script>
+<script src="../../resources/glsl-conformance-test.js"></script>
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<script id="fragmentShaderAGreaterThanBCheckR" type="text/something-not-javascript">
+// fragment shader with for scoping should succeed
+precision mediump float;
+void main() {
+  float a = 3.0;
+  float b = 2.0;
+  float r = 0.0;
+  float r0 = 0.5;
+  float r1 = 1.0;
+  float ab = a > b ? (r = r0, a) : (r = r1, b);
+  // Output green if successful, red if not.
+  gl_FragColor = ((r == r0) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script id="fragmentShaderAGreaterThanBCheckAB" type="text/something-not-javascript">
+// fragment shader with for scoping should succeed
+precision mediump float;
+void main() {
+  float a = 3.0;
+  float b = 2.0;
+  float r = 0.0;
+  float r0 = 0.5;
+  float r1 = 1.0;
+  float ab = a > b ? (r = r0, a) : (r = r1, b);
+  // Output green if successful, red if not.
+  gl_FragColor = ((ab == a) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script id="fragmentShaderAGreaterThanBCheckT0" type="text/something-not-javascript">
+// fragment shader with for scoping should succeed
+precision mediump float;
+void main() {
+  float a = 3.0;
+  float b = 2.0;
+  float t0 = 0.0;
+  float t1 = 0.0;
+  float r0 = 0.5;
+  float r1 = 1.0;
+  float ab = a > b ? (t0 = r0, a) : (t1 = r1, b);
+  // Output green if successful, red if not.
+  gl_FragColor = ((t0 == r0) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script id="fragmentShaderAGreaterThanBCheckT1" type="text/something-not-javascript">
+// fragment shader with for scoping should succeed
+precision mediump float;
+void main() {
+  float a = 3.0;
+  float b = 2.0;
+  float t0 = 0.0;
+  float t1 = 0.0;
+  float r0 = 0.5;
+  float r1 = 1.0;
+  float ab = a > b ? (t0 = r0, a) : (t1 = r1, b);
+  // Output green if successful, red if not.
+  gl_FragColor = ((t1 == 0.0) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script id="fragmentShaderBGreaterThanACheckR" type="text/something-not-javascript">
+// fragment shader with for scoping should succeed
+precision mediump float;
+void main() {
+  float a = 2.0;
+  float b = 3.0;
+  float r = 0.0;
+  float r0 = 0.5;
+  float r1 = 1.0;
+  float ab = a > b ? (r = r0, a) : (r = r1, b);
+  // Output green if successful, red if not.
+  gl_FragColor = ((r == r1) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script id="fragmentShaderBGreaterThanACheckAB" type="text/something-not-javascript">
+// fragment shader with for scoping should succeed
+precision mediump float;
+void main() {
+  float a = 2.0;
+  float b = 3.0;
+  float r = 0.0;
+  float r0 = 0.5;
+  float r1 = 1.0;
+  float ab = a > b ? (r = r0, a) : (r = r1, b);
+  // Output green if successful, red if not.
+  gl_FragColor = ((ab == b) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script id="fragmentShaderBGreaterThanACheckT0" type="text/something-not-javascript">
+// fragment shader with for scoping should succeed
+precision mediump float;
+void main() {
+  float a = 2.0;
+  float b = 3.0;
+  float t0 = 0.0;
+  float t1 = 0.0;
+  float r0 = 0.5;
+  float r1 = 1.0;
+  float ab = a > b ? (t0 = r0, a) : (t1 = r1, b);
+  // Output green if successful, red if not.
+  gl_FragColor = ((t0 == 0.0) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script id="fragmentShaderBGreaterThanACheckT1" type="text/something-not-javascript">
+// fragment shader with for scoping should succeed
+precision mediump float;
+void main() {
+  float a = 2.0;
+  float b = 3.0;
+  float t0 = 0.0;
+  float t1 = 0.0;
+  float r0 = 0.5;
+  float r1 = 1.0;
+  float ab = a > b ? (t0 = r0, a) : (t1 = r1, b);
+  // Output green if successful, red if not.
+  gl_FragColor = ((t1 == r1) ? vec4(0,1,0,1) : vec4(1,0,0,1));
+}
+</script>
+<script>
+GLSLConformanceTester.runRenderTests([
+{ vShaderId: undefined,
+  vShaderSuccess: true,
+  fShaderId: 'fragmentShaderAGreaterThanBCheckR',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: "comma based conditional assignment works",
+},
+{ vShaderId: undefined,
+  vShaderSuccess: true,
+  fShaderId: 'fragmentShaderAGreaterThanBCheckAB',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: "comma based conditional assignment works",
+},
+{ vShaderId: undefined,
+  vShaderSuccess: true,
+  fShaderId: 'fragmentShaderAGreaterThanBCheckT0',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: "comma based conditional assignment works",
+},
+{ vShaderId: undefined,
+  vShaderSuccess: true,
+  fShaderId: 'fragmentShaderAGreaterThanBCheckT1',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: "comma based conditional assignment works",
+},
+{ vShaderId: undefined,
+  vShaderSuccess: true,
+  fShaderId: 'fragmentShaderBGreaterThanACheckR',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: "comma based conditional assignment works",
+},
+{ vShaderId: undefined,
+  vShaderSuccess: true,
+  fShaderId: 'fragmentShaderBGreaterThanACheckAB',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: "comma based conditional assignment works",
+},
+{ vShaderId: undefined,
+  vShaderSuccess: true,
+  fShaderId: 'fragmentShaderBGreaterThanACheckT0',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: "comma based conditional assignment works",
+},
+{ vShaderId: undefined,
+  vShaderSuccess: true,
+  fShaderId: 'fragmentShaderBGreaterThanACheckT1',
+  fShaderSuccess: true,
+  linkSuccess: true,
+  passMsg: "comma based conditional assignment works",
+}
+]);
+successfullyParsed = true;
+</script>
+</body>
+</html>
+
+
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-conditional-scoping.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-conditional-scoping.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-default-precision.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-default-precision.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-default-precision.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-default-precision.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-define-line-continuation.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-define-line-continuation.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-dfdx-no-ext.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-dfdx-no-ext.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-dfdx.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-dfdx.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-do-scoping.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-do-scoping.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-error-directive.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-error-directive.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.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-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-explicit-int-cast.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-explicit-int-cast.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-float-return-value.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-float-return-value.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-for-loop.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-for-loop.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-for-scoping.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-for-scoping.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-frag-depth.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-frag-depth.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-function-recursion.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-function-recursion.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-function-scoped-struct.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-function-scoped-struct.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-functional-scoping.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-functional-scoping.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-glcolor.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-glcolor.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-gles-1.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-gles-1.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-gles-symbol.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-gles-symbol.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-glprojectionmatrix.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-glprojectionmatrix.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-hex-int-constant-macro.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-hex-int-constant-macro.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-implicit-vec3-to-vec4-cast.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-implicit-vec3-to-vec4-cast.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-include.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-include.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-int-return-value.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-int-return-value.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-invalid-identifier.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-invalid-identifier.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec2-return-value.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec2-return-value.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec3-return-value.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec3-return-value.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec4-return-value.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-ivec4-return-value.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-limited-indexing.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-limited-indexing.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-line-directive.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-line-directive.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.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-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-long-line.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-long-line.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.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-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-non-ascii-error.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-non-ascii-error.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-precision.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-precision.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-quoted-error.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-quoted-error.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-undefined-preprocessor-symbol.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-undefined-preprocessor-symbol.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-uniform-in-loop-condition.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-uniform-in-loop-condition.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec2-return-value.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec2-return-value.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec3-return-value.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec3-return-value.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec4-return-value.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec4-return-value.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec4-vec3-vec4-conditional.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-vec4-vec3-vec4-conditional.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-100.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-100.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-100.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-100.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-120.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-120.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-130.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-version-130.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-with-webgl-identifier.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-with-webgl-identifier.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shader-without-precision.frag.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shader-without-precision.frag.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="fragmentShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/shared.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/shared.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="sharedVertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/struct-nesting-exceeds-maximum.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/struct-nesting-exceeds-maximum.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/struct-nesting-under-maximum.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/struct-nesting-under-maximum.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a/content/canvas/test/webgl/conformance/glsl/misc/uniform-location-length-limits.html
+++ b/content/canvas/test/webgl/conformance/glsl/misc/uniform-location-length-limits.html
@@ -1,14 +1,15 @@
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL uniform location length tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.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="50" height="50">
 There is supposed to be an example drawing here, but it's not important.
 </canvas>
@@ -55,17 +56,17 @@ void main() {
 }
 </script>
 <script>
 if (window.initNonKhronosFramework) {
     window.initNonKhronosFramework(false);
 }
 
 var wtu = WebGLTestUtils;
-var gl = wtu.create3DContext(document.getElementById("example"));
+var gl = wtu.create3DContext("example");
 
 debug("Test uniform location underneath the length limit");
 var program = wtu.loadProgramFromScript(gl, "goodVertexShader", "fragmentShader");
 shouldBe('gl.getProgramParameter(program, gl.LINK_STATUS)', 'true');
 var uniformLoc = gl.getUniformLocation(program, "identifier128CharactersLong_0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789.identifier64CharactersLong_0123456789012345678901234567890123456.identifier62CharactersLong_01234567890123456789012345678901234");
 shouldBeNonNull('uniformLoc');
 wtu.glErrorShouldBe(gl, gl.NONE);
 
--- a/content/canvas/test/webgl/conformance/glsl/reserved/_webgl_field.vert.html
+++ b/content/canvas/test/webgl/conformance/glsl/reserved/_webgl_field.vert.html
@@ -4,16 +4,17 @@ Use of this source code is governed by a
 found in the LICENSE file.
 -->
 <!DOCTYPE html>
 <html>
 <head>
 <meta charset="utf-8">
 <title>WebGL GLSL Conformance Tests</title>
 <link rel="stylesheet" href="../../../resources/js-test-style.css"/>
+<link rel="stylesheet" href="../../resources/glsl-feature-tests.css"/>
 <script src="../../../resources/js-test-pre.js"></script>
 <script src="../../resources/webgl-test-utils.js"></script>
 <script src="../../resources/glsl-conformance-test.js"></script>
 </head>
 <body>
 <div id="description"></div>
 <div id="console"></div>
 <script id="vertexShader" type="text/something-not-javascript">
--- a