[Piglit] [Patch v2 06/13] Rename all tests files from .tests to .py
Dylan Baker
baker.dylan.c at gmail.com
Wed Jan 8 16:25:04 PST 2014
This patch renames the .tests files to .py files; which is required for
the python interpreter to allow importing them.
---
CMakeLists.txt | 2 +-
README | 25 +++++++++++--------------
tests/{all.tests => all.py} | 0
tests/{all_cl.tests => all_cl.py} | 0
tests/{es3conform.tests => es3conform.py} | 0
tests/{gpu.tests => gpu.py} | 2 +-
tests/{igt.tests => igt.py} | 0
tests/{oglconform.tests => oglconfirm.py} | 0
tests/{quick.tests => quick.py} | 2 +-
tests/{r300.tests => r300.py} | 0
tests/{r500.tests => r500.py} | 0
tests/{sanity.tests => sanity.py} | 0
12 files changed, 14 insertions(+), 17 deletions(-)
rename tests/{all.tests => all.py} (100%)
rename tests/{all_cl.tests => all_cl.py} (100%)
rename tests/{es3conform.tests => es3conform.py} (100%)
rename tests/{gpu.tests => gpu.py} (91%)
rename tests/{igt.tests => igt.py} (100%)
rename tests/{oglconform.tests => oglconfirm.py} (100%)
rename tests/{quick.tests => quick.py} (89%)
rename tests/{r300.tests => r300.py} (100%)
rename tests/{r500.tests => r500.py} (100%)
rename tests/{sanity.tests => sanity.py} (100%)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6092f99..4595de6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -388,7 +388,7 @@ install (
install (
DIRECTORY tests
DESTINATION .
- FILES_MATCHING REGEX ".*\\.(tests|program_test|shader_test|frag|vert|geom|ktx|cl|txt)$"
+ FILES_MATCHING REGEX ".*\\.(py|program_test|shader_test|frag|vert|geom|ktx|cl|txt)$"
REGEX "CMakeFiles|CMakeLists" EXCLUDE
)
diff --git a/README b/README
index bd4591e..13f1202 100644
--- a/README
+++ b/README
@@ -176,13 +176,10 @@ Use
$ ./piglit-run.py
-to learn more about the command's syntax. Have a look into the tests/
+To learn more about the command's syntax. Have a look into the tests/
directory to see what test profiles are available:
- $ cd tests
- $ ls *.tests
- ...
- $ cd ..
+ $ ls tests/*.py
See also section 4.
@@ -227,25 +224,25 @@ The summary shows the 'status' of a test:
Test sets are specified as Python scripts in the tests directory.
The following test sets are currently available:
-sanity.tests
+sanity.py
This suite contains minimal sanity tests. These tests must
pass, otherwise the other tests will not generate reliable results.
-all.tests
- This suite contains all tests.
+all.py
+ This suite contains all OpenGL tests.
-all_cl.tests
+all_cl.py
This suite contains all OpenCL tests.
-quick.tests
+quick.py
Run all tests, but cut down significantly on their runtime
(and thus on the number of problems they can find).
In particular, this runs Glean with the --quick option, which
reduces the number of visuals and state combinations tested.
-radeon.tests
-r300.tests
-r500.tests
+radeon.py
+r300.py
+r500.py
These test suites are adaptations of all.tests, with some tweaks
to account for hardware limitations in Radeon chips.
@@ -260,7 +257,7 @@ Therefore, tests can be implemented in an arbitrary standalone language.
I recommend C, C++ and Python, as these are the languages that are already
used in Piglit.
-All new tests must be added to the all.tests profile. The test profiles
+All new tests must be added to the all.py profile. The test profiles
are simply Python scripts. There are currently two supported test types:
PlainExecTest
diff --git a/tests/all.tests b/tests/all.py
similarity index 100%
rename from tests/all.tests
rename to tests/all.py
diff --git a/tests/all_cl.tests b/tests/all_cl.py
similarity index 100%
rename from tests/all_cl.tests
rename to tests/all_cl.py
diff --git a/tests/es3conform.tests b/tests/es3conform.py
similarity index 100%
rename from tests/es3conform.tests
rename to tests/es3conform.py
diff --git a/tests/gpu.tests b/tests/gpu.py
similarity index 91%
rename from tests/gpu.tests
rename to tests/gpu.py
index 7ed4418..99e1614 100644
--- a/tests/gpu.tests
+++ b/tests/gpu.py
@@ -18,7 +18,7 @@ def add_glsl_parser_test(group, filepath, test_name):
framework.glsl_parser_test.add_glsl_parser_test = add_glsl_parser_test
-execfile(os.path.dirname(__file__) + '/quick.tests')
+execfile(os.path.dirname(__file__) + '/quick.py')
# Drop ARB_vertex_program/ARB_fragment_program compiler tests.
del profile.tests['asmparsertest']
diff --git a/tests/igt.tests b/tests/igt.py
similarity index 100%
rename from tests/igt.tests
rename to tests/igt.py
diff --git a/tests/oglconform.tests b/tests/oglconfirm.py
similarity index 100%
rename from tests/oglconform.tests
rename to tests/oglconfirm.py
diff --git a/tests/quick.tests b/tests/quick.py
similarity index 89%
rename from tests/quick.tests
rename to tests/quick.py
index fca5559..0f8c7f3 100644
--- a/tests/quick.tests
+++ b/tests/quick.py
@@ -9,7 +9,7 @@ __all__ = ['profile']
GleanTest.globalParams += [ "--quick" ]
-execfile(os.path.dirname(__file__) + '/all.tests')
+execfile(os.path.dirname(__file__) + '/all.py')
# These take too long
del profile.tests['shaders']['glsl-fs-inline-explosion']
diff --git a/tests/r300.tests b/tests/r300.py
similarity index 100%
rename from tests/r300.tests
rename to tests/r300.py
diff --git a/tests/r500.tests b/tests/r500.py
similarity index 100%
rename from tests/r500.tests
rename to tests/r500.py
diff --git a/tests/sanity.tests b/tests/sanity.py
similarity index 100%
rename from tests/sanity.tests
rename to tests/sanity.py
--
1.8.5.2
More information about the Piglit
mailing list