 tex2d, 0);

  testTexOrSubImage("texImage2D", fn2D);
  testTexOrSubImage("texSubImage2D", fnSub2D);

  ////

  var tex3d = gl.createTexture();
  gl.bindTexture(gl.TEXTURE_3D, tex3d);
  gl.texImage3D(gl.TEXTURE_3D, 0, gl.RGBA, 1, 1, 1, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);

  gl.bindFramebuffer(gl.FRAMEBUFFER, fb);
  gl.framebufferTextureLayer(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, tex3d, 0, 0);

  testTexOrSubImage("texImage3D", fn3D);
  testTexOrSubImage("texSubImage3D", fnSub3D);
} while (false);


do {
  