summaryrefslogtreecommitdiff
path: root/android/scripts/piglit-gles-2.0.sh
diff options
context:
space:
mode:
authorYongqin Liu <yongqin.liu@linaro.org>2014-11-07 22:44:12 +0800
committerMilosz Wasilewski <milosz.wasilewski@linaro.org>2014-11-14 14:50:01 +0000
commit31a299d80c147ef2cebeb2dd9eab420bfa196277 (patch)
tree7a070e180ff3ba6450eea956b5a9a11638b25d86 /android/scripts/piglit-gles-2.0.sh
parent74ff4a60e70dd187d8cb3a1efe29d981297860f2 (diff)
android piglit test: update test definitions for piglit test
update the test definition files for piglit test, also rename the files' name with piglit as prefix Change-Id: I44c6b6168d6fd164d20deb8fa8dd3b077adfbd64 Signed-off-by: Yongqin Liu <yongqin.liu@linaro.org>
Diffstat (limited to 'android/scripts/piglit-gles-2.0.sh')
-rwxr-xr-xandroid/scripts/piglit-gles-2.0.sh48
1 files changed, 48 insertions, 0 deletions
diff --git a/android/scripts/piglit-gles-2.0.sh b/android/scripts/piglit-gles-2.0.sh
new file mode 100755
index 0000000..fadf58c
--- /dev/null
+++ b/android/scripts/piglit-gles-2.0.sh
@@ -0,0 +1,48 @@
+#!/system/bin/sh
+#
+# piglit gles2.0 test.
+#
+# Copyright (C) 2014, Linaro Limited.
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License
+# as published by the Free Software Foundation; either version 2
+# of the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
+# USA.
+#
+# owner: yongqin.liu@linaro.org
+#
+###############################################################################
+
+export PIGLIT_PLATFORM=android
+
+PSTRING='PIGLIT: {"result": "pass"'
+SSTRING='PIGLIT: {"result": "skip"'
+FSTRING='PIGLIT: {"result": "fail"'
+
+gles2_bin_dir="/system/xbin/piglit/piglit-spec-gles2"
+
+function normal_test(){
+ cmd="${gles2_bin_dir}/$1"
+ test_name="${1}"
+ RESULT=$(${cmd} -auto)
+ case $RESULT in
+ *"$PSTRING"*) echo "${test_name}: pass";;
+ *"$SSTRING"*) echo "${test_name}: skip";;
+ *"$FSTRING"*) echo "${test_name}: fail";;
+ *) echo "${test_name}: fail";;
+ esac
+}
+
+normal_test "glsl-fs-pointcoord_gles2"
+normal_test "minmax_gles2"
+normal_test "multiple-shader-objects_gles2"