[Piglit] [RESEND RFC 13/25] gen_tcs_input_tests.py: fix whitespace errors

baker.dylan.c at gmail.com baker.dylan.c at gmail.com
Wed Oct 21 10:20:22 PDT 2015


From: Dylan Baker <baker.dylan.c at gmail.com>

Signed-off-by: Dylan Baker <dylanx.c.baker at intel.com>
---
 generated_tests/gen_tcs_input_tests.py | 24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

diff --git a/generated_tests/gen_tcs_input_tests.py b/generated_tests/gen_tcs_input_tests.py
index c705844..5d2b4a5 100644
--- a/generated_tests/gen_tcs_input_tests.py
+++ b/generated_tests/gen_tcs_input_tests.py
@@ -102,13 +102,13 @@ class Test(object):
             for i in xrange(12):
                 for j in xrange(self.var_array):
                     uniforms += 'uniform {0} reference[{1}].v[{2}] {3}\n'.format(
-                            self.var_type, i, j, data[i*j])
+                        self.var_type, i, j, data[i*j])
         else:
             for i in xrange(12):
                 uniforms += 'uniform {0} reference[{1}].v {2}\n'.format(
-                        self.var_type,
-                        i,
-                        data[i])
+                    self.var_type,
+                    i,
+                    data[i])
 
         #strip last newline
         return uniforms[:-1]
@@ -144,13 +144,13 @@ class Test(object):
             n = 12
 
         if self.var_type.startswith('i'):
-            rand = lambda : random.randint(-0x80000000, 0x7fffffff)
+            rand = lambda: random.randint(-0x80000000, 0x7fffffff)
         elif self.var_type.startswith('u'):
-            rand = lambda : random.randint(0, 0xffffffff)
+            rand = lambda: random.randint(0, 0xffffffff)
         else:
-            rand = lambda : ((-1 + 2 * random.randint(0, 1)) *
-                             random.randint(0, 2**23-1) *
-                             2.0**(random.randint(-126, 127)))
+            rand = lambda: ((-1 + 2 * random.randint(0, 1)) *
+                            random.randint(0, 2**23-1) *
+                            2.0**(random.randint(-126, 127)))
 
         c = self.components()
 
@@ -272,8 +272,7 @@ relative probe rgb (0.25, 0.75) (0.0, 1.0, 0.0)
 relative probe rgb (0.75, 0.75) (0.0, 1.0, 0.0)
 """
 
-        test = test.format(self = self,
-            generator_command = " ".join(sys.argv))
+        test = test.format(self=self, generator_command=" ".join(sys.argv))
 
         filename = self.filename()
         dirname = os.path.dirname(filename)
@@ -284,7 +283,7 @@ relative probe rgb (0.75, 0.75) (0.0, 1.0, 0.0)
 
 
 def all_tests():
-    for type_name in ['float', 'vec2',  'vec3',  'vec4',
+    for type_name in ['float', 'vec2', 'vec3', 'vec4',
                       'mat2', 'mat3', 'mat4',
                       'mat2x3', 'mat2x4', 'mat3x2',
                       'mat3x4', 'mat4x2', 'mat4x3',
@@ -295,6 +294,7 @@ def all_tests():
     for var in ['gl_Position', 'gl_PointSize', 'gl_ClipDistance']:
         yield Test(type_name=None, array=None, name=var)
 
+
 def main():
     for test in all_tests():
         test.generate()
-- 
2.6.1



More information about the Piglit mailing list