From de4d301881e7fd084f1f0b359ec6f9b2bf8bd4c5 Mon Sep 17 00:00:00 2001 From: Ethan Nicholas Date: Thu, 19 Jan 2017 16:58:02 -0500 Subject: Replaced all calls to fragmentPosition() with sk_FragCoord BUG=skia: Change-Id: I179576e148ea6caf6e1c40f0a216421898bcb35d Reviewed-on: https://skia-review.googlesource.com/5941 Commit-Queue: Ethan Nicholas Reviewed-by: Brian Salomon --- tests/SkSLErrorTest.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'tests/SkSLErrorTest.cpp') diff --git a/tests/SkSLErrorTest.cpp b/tests/SkSLErrorTest.cpp index a33e6f16e6..c28dbbb7f3 100644 --- a/tests/SkSLErrorTest.cpp +++ b/tests/SkSLErrorTest.cpp @@ -418,4 +418,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 -- cgit v1.2.3