gl.NO_ERROR, "should be no more errors");
    gl.samplerParameterf(sampler, ext.DEPTH_STENCIL_TEXTURE_MODE_WEBGL, gl.DEPTH_COMPONENT);
    wtu.glErrorShouldBe(gl, gl.INVALID_ENUM, "parameter unknown for samplerParameterf");
    wtu.glErrorShouldBe(gl, gl.NO_ERROR, "should be no more errors");
}

function checkSampling() {
    const formats = [
        {name: "DEPTH_COMPONENT16", internalFormat: gl.DEPTH_COMPONENT16,
         format: gl.DEPTH_COMPONENT, type: gl.UNSIGNED_SHORT},
        {name: "DEPTH_COMPONE