aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/SkSLErrorTest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/SkSLErrorTest.cpp')
-rw-r--r--tests/SkSLErrorTest.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/SkSLErrorTest.cpp b/tests/SkSLErrorTest.cpp
index 9c34ab41fb..301281c28e 100644
--- a/tests/SkSLErrorTest.cpp
+++ b/tests/SkSLErrorTest.cpp
@@ -421,4 +421,13 @@ DEF_TEST(SkSLDivByZero, r) {
"error: 1: division by zero\n1 error\n");
}
+DEF_TEST(SkSLUnsupportedGLSLIdentifiers, r) {
+ test_failure(r,
+ "void main() { float x = gl_FragCoord.x; };",
+ "error: 1: unknown identifier 'gl_FragCoord'\n1 error\n");
+ test_failure(r,
+ "void main() { float r = gl_FragColor.r; };",
+ "error: 1: unknown identifier 'gl_FragColor'\n1 error\n");
+}
+
#endif