2 Copyright (c) 2019 The Khronos Group Inc.
3 Use of this source code is governed by an MIT-style license that can be
4 found in the LICENSE.txt file.
10 <meta charset=
"utf-8">
11 <title>WebGL Program Conformance Tests
</title>
12 <link rel=
"stylesheet" href=
"../../resources/js-test-style.css"/>
13 <script src=
"../../js/js-test-pre.js"></script>
14 <script src=
"../../js/webgl-test-utils.js"></script>
17 <div id=
"description"></div>
18 <div id=
"console"></div>
19 <canvas id=
"canvas" width=
"2" height=
"2"> </canvas>
20 <script id=
"vertexShader" language=
"x-shader/x-vertex">
23 gl_Position = vec4(
0.0,
0.0,
0.0,
1.0);
26 <script id=
"fragmentShader" language=
"x-shader/x-fragment">
27 precision mediump float;
30 gl_FragColor = vec4(
1.0,
0.0,
0.0,
1.0);
35 description('getProgramInfoLog should not return \\0');
39 var wtu
= WebGLTestUtils
;
40 var gl
= wtu
.create3DContext("canvas");
42 testFailed("context does not exist");
44 testPassed("context exists");
49 var program
= wtu
.loadProgramFromScript(gl
, 'vertexShader', 'fragmentShader');
50 var infolog
= gl
.getProgramInfoLog(program
);
51 if (infolog
=== '\0') {
52 testFailed("getProgramInfoLog should not return '\\0'");
54 testPassed("getProgramInfoLog didn't return '\\0'");
57 var successfullyParsed
= true;
59 <script src=
"../../js/js-test-post.js"></script>