Bug 1321450 - Update tests.
authorJeff Gilbert <jdashg@gmail.com>
Tue, 06 Dec 2016 14:44:36 -0800
changeset 325321 5ee72d9b8e3ef32e4dceca79a0682641b7401b83
parent 325320 0d7106de13327e1446d0034c10e7e9986a50a4e7
child 325322 1d9ec0ad1388284030757003dbffa93bcaf9c0e0
push id24
push usermaklebus@msu.edu
push dateTue, 20 Dec 2016 03:11:33 +0000
bugs1321450
milestone53.0a1
Bug 1321450 - Update tests. MozReview-Commit-ID: FNIVogqXLld
dom/canvas/test/webgl-conf/checkout/conformance2/renderbuffers/invalidate-framebuffer.html
--- a/dom/canvas/test/webgl-conf/checkout/conformance2/renderbuffers/invalidate-framebuffer.html
+++ b/dom/canvas/test/webgl-conf/checkout/conformance2/renderbuffers/invalidate-framebuffer.html
@@ -80,43 +80,43 @@ if (!gl) {
   invalidateIncompleteAttachment(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT);
   gl.renderbufferStorageMultisample(gl.RENDERBUFFER, samples[0], gl.DEPTH_COMPONENT16, canvas.width, canvas.height);
   gl.clear(gl.DEPTH_BUFFER_BIT);
   wtu.glErrorShouldBe(gl, gl.NO_ERROR,
       "should be no errors after attaching a renderbuffer to fbo.");
 
   // in real world case, after some drawing, we can invalidate the depth attachment of the bound fbo
   invalidation(gl.FRAMEBUFFER, gl.DEPTH_ATTACHMENT, gl.STENCIL_ATTACHMENT);
- 
-  // set up framebuffer to blit to and read back from 
+
+  // set up framebuffer to blit to and read back from
   var fb = gl.createFramebuffer();
   gl.bindFramebuffer(gl.FRAMEBUFFER, fb);
   var buffer = gl.createRenderbuffer();
   gl.bindRenderbuffer(gl.RENDERBUFFER, buffer);
   gl.renderbufferStorage(gl.RENDERBUFFER, gl.RGBA8, canvas.width, canvas.height);
   gl.framebufferRenderbuffer(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.RENDERBUFFER, buffer);
   gl.clear(gl.COLOR_BUFFER_BIT);
   wtu.glErrorShouldBe(gl, gl.NO_ERROR,
       "should be no errors after attaching a renderbuffer to fbo.");
 
   gl.bindFramebuffer(gl.READ_FRAMEBUFFER, fb_m);
   gl.bindFramebuffer(gl.DRAW_FRAMEBUFFER, fb);
   gl.blitFramebuffer(0, 0, canvas.width, canvas.height, 0, 0, canvas.width, canvas.height, gl.COLOR_BUFFER_BIT, gl.NEAREST);
   wtu.glErrorShouldBe(gl, gl.NO_ERROR,
       "should be no errors after bliting framebuffer.");
- 
+
   // invalidate the multi-sampled color attachment of the bound read framebuffer after blitFramebuffer.
   invalidation(gl.READ_FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.DEPTH_ATTACHMENT);
 
   var maxColorAttachments = gl.getParameter(gl.MAX_COLOR_ATTACHMENTS);
   gl.invalidateSubFramebuffer(gl.READ_FRAMEBUFFER, [gl.COLOR_ATTACHMENT0 + maxColorAttachments], 5, 5, 10, 10);
-  wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION,
+  wtu.glErrorShouldBe(gl, [gl.INVALID_OPERATION, gl.INVALID_ENUM],
       "calling invalidateSubFramebuffer to invalidate a COLOR_ATTACHMENT that exceeds MAX_COLOR_ATTACHMENT should generate INVALID_OPERATION.");
   gl.invalidateFramebuffer(gl.READ_FRAMEBUFFER, [gl.COLOR_ATTACHMENT0 + maxColorAttachments]);
-  wtu.glErrorShouldBe(gl, gl.INVALID_OPERATION,
+  wtu.glErrorShouldBe(gl, [gl.INVALID_OPERATION, gl.INVALID_ENUM],
       "calling invalidateFramebuffer to invalidate a COLOR_ATTACHMENT that exceeds MAX_COLOR_ATTACHMENT should generate INVALID_OPERATION.");
 
   // invalidate the default framebuffer
   gl.bindFramebuffer(gl.FRAMEBUFFER, null);
   invalidation(gl.FRAMEBUFFER, gl.DEPTH, gl.STENCIL);
 
   gl.deleteFramebuffer(fb_m);
   gl.deleteRenderbuffer(rb_m);