On Friday, September 26, 2014 07:02:49 PM Jan Vesely wrote: > Signed-off-by: Jan Vesely <jan.ves...@rutgers.edu> > --- > > Something like this? > > tests/cl.py | 13 ++++++------- > 1 file changed, 6 insertions(+), 7 deletions(-) > > diff --git a/tests/cl.py b/tests/cl.py > index f618f59..2d3c930 100644 > --- a/tests/cl.py > +++ b/tests/cl.py > @@ -7,6 +7,9 @@ __all__ = ['profile'] > import os > import os.path as path > > +import platform > +import glob > + > from framework.opencv import add_opencv_tests > > from framework.profile import TestProfile > @@ -16,13 +19,9 @@ from framework.exectest import PiglitTest > # Helper functions > > def add_plain_test(group, name, args): > - group[name] = PiglitTest(args) > - > -# TODO: Use concurrent tests for everything once kernels with render nodes > -# enabled by default (3.16 or newer) are more widely used. > -def add_concurrent_test(group, name, args): > - test = PiglitTest(args, run_concurrent=True) > - group[name] = test > + group[name] = PiglitTest(args, run_concurrent= > + platform.system().lower()[0:5] != 'linux' or > + glob.glob('/dev/dri/render*'))
Isn't that going to be re-evaluated every time you call add_concurrent_test? I would think evaluating that once as a module constant would be better. > > def add_plain_program_tester_test(group, name, path): > add_plain_test(group, name, ['cl-program-tester', path]) > -- > 1.9.3 >
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ Piglit mailing list Piglit@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/piglit