[Piglit] [PATCH 5/9] tests/oglconform.py: override command.getter
baker.dylan.c at gmail.com
baker.dylan.c at gmail.com
Wed Oct 21 11:06:30 PDT 2015
From: Dylan Baker <baker.dylan.c at gmail.com>
This moves some constant arguments out of the permanently stored values
in each test instance into a getter, which reduces the number of
duplicate elements that need to be stored per instance. This reduces
memory usage a little.
Signed-off-by: Dylan Baker <dylanx.c.baker at intel.com>
---
tests/oglconform.py | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/tests/oglconform.py b/tests/oglconform.py
index a20dfb3..1772fa2 100644
--- a/tests/oglconform.py
+++ b/tests/oglconform.py
@@ -46,13 +46,18 @@ class OGLCTest(Test):
will obtain a list of tests from oglconform and add them all.
"""
+ _BIN = bin_oglconform
skip_re = re.compile(r'Total Not run: 1|no test in schedule is '
r'compat|GLSL [13].[345]0 is not supported|wont be '
r'scheduled due to lack of compatible fbconfig')
def __init__(self, category, subtest):
- super(OGLCTest, self).__init__([bin_oglconform, '-minFmt', '-v', '4',
- '-test', category, subtest])
+ super(OGLCTest, self).__init__([category, subtest])
+
+ @Test.command.getter
+ def command(self):
+ return [self._BIN, '-minFmt', '-v', '4', '-test'] + \
+ super(OGLCTest, self).command
def interpret_result(self):
if self.skip_re.search(self.result.out) is not None:
--
2.6.1
More information about the Piglit
mailing list