summaryrefslogtreecommitdiff
path: root/framework
diff options
context:
space:
mode:
authorNeha Bhende <bhenden@vmware.com>2017-02-06 09:08:27 -0700
committerBrian Paul <brianp@vmware.com>2017-02-06 09:09:18 -0700
commit724ba4c2fbc9603dbe4fec96ae199a1b8f5fb248 (patch)
treec406411e85e1a86f6ad7c58f3eee76e5f38f3b06 /framework
parentca58eec0b965655c7eba592a634cbf4aadfbc675 (diff)
framework/test/glsl_parser_test.py: fix python script to run glslparsertest on Windows
glslparsertest was not running on windows because python script is looking for glslparsertest. On windows, piglit creates glslparsertest.exe. With this fix, all glslparsertest will run on Windows. Reviewed-by: Charmaine Lee <charmainel@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'framework')
-rw-r--r--framework/test/glsl_parser_test.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/framework/test/glsl_parser_test.py b/framework/test/glsl_parser_test.py
index 22eb6ce4c..6a06bc3ef 100644
--- a/framework/test/glsl_parser_test.py
+++ b/framework/test/glsl_parser_test.py
@@ -25,6 +25,7 @@ from __future__ import (
absolute_import, division, print_function, unicode_literals
)
import os
+import sys
import re
import io
import six
@@ -40,8 +41,12 @@ __all__ = [
]
# In different configurations piglit may have one or both of these.
-_HAS_GL_BIN = os.path.exists(os.path.join(TEST_BIN_DIR, 'glslparsertest'))
-_HAS_GLES_BIN = os.path.exists(os.path.join(TEST_BIN_DIR, 'glslparsertest_gles2'))
+if sys.platform == 'win32':
+ _HAS_GL_BIN = os.path.exists(os.path.join(TEST_BIN_DIR, 'glslparsertest.exe'))
+ _HAS_GLES_BIN = os.path.exists(os.path.join(TEST_BIN_DIR, 'glslparsertest_gles2.exe'))
+else:
+ _HAS_GL_BIN = os.path.exists(os.path.join(TEST_BIN_DIR, 'glslparsertest'))
+ _HAS_GLES_BIN = os.path.exists(os.path.join(TEST_BIN_DIR, 'glslparsertest_gles2'))
# This forces testing with compatibility extensions, even when GLES support is
# built