]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
PEP8: fix E211: whitespace before '('
authorJoe Guo <joeg@catalyst.net.nz>
Mon, 30 Jul 2018 06:17:15 +0000 (18:17 +1200)
committerDouglas Bagnall <dbagnall@samba.org>
Fri, 24 Aug 2018 05:49:27 +0000 (07:49 +0200)
Signed-off-by: Joe Guo <joeg@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
python/samba/gpclass.py
python/samba/subunit/__init__.py
source4/dsdb/tests/python/rodc_rwdc.py
source4/dsdb/tests/python/sort.py
source4/dsdb/tests/python/vlv.py

index 008599bd53fc92f5f42ecd5a2a8fa4d658df33a4..106bed26cdd46b2a52195f549369203fe9ca3ec3 100644 (file)
@@ -224,8 +224,7 @@ class gp_log:
                 for attr in attrs:
                     func = None
                     if attr.attrib['name'] in data_maps[ext.attrib['name']]:
-                        func = data_maps[ext.attrib['name']]\
-                               [attr.attrib['name']][-1]
+                        func = data_maps[ext.attrib['name']][attr.attrib['name']][-1]
                     else:
                         for dmap in data_maps[ext.attrib['name']].keys():
                             if data_maps[ext.attrib['name']][dmap][0] == \
index ae208430d169ce8cb5aa735cba6620b39fc8f1db..c6203c30afbb86cb2b7b65c632083d27abf194a4 100644 (file)
@@ -45,7 +45,7 @@ class RemotedTestCase(unittest.TestCase):
     actions.
     """
 
-    def __eq__ (self, other):
+    def __eq__(self, other):
         try:
             return self.__description == other.__description
         except AttributeError:
index 653e0404bf82fae066a84ba5adda2b2455386101..4b6c68486adf7eae5575d5a79039a1091d9b98bf 100644 (file)
@@ -84,7 +84,7 @@ def set_auto_replication(dc, allow):
         if p.returncode:
             if 'LDAP_REFERRAL' not in stderr:
                 raise RodcRwdcTestException()
-            print ("ignoring +%s REFERRAL error; assuming %s is RODC" %
+            print("ignoring +%s REFERRAL error; assuming %s is RODC" %
                    (opt, dc))
 
 
index d41bb953f1d4b79f9ea46150485dee7713886eb7..2939aca3666f026769a394140af8364771cb406e 100644 (file)
@@ -331,7 +331,7 @@ class BaseSortTests(samba.tests.TestCase):
                     # Let's remind ourselves.
                     if result_attr == "msTSExpireDate4":
                         print('-' * 72)
-                        print ("This test fails against Windows with the "
+                        print("This test fails against Windows with the "
                                "default number of elements (33).")
                         print("Try with --elements=27 (or similar).")
                         print('-' * 72)
index 44c1f6ef32ee1b0a968ddb28519316375d168f6d..6e6ed393e4144037da0169bffdf42e82348efc7e 100644 (file)
@@ -558,7 +558,7 @@ class VLVTests(samba.tests.TestCase):
                                 skipped += 1
 
                         if expected_results != results:
-                            print ("attr %s before %d after %d offset %d" %
+                            print("attr %s before %d after %d offset %d" %
                                    (attr, before, after, offset))
                         self.assertEquals(expected_results, results)
 
@@ -701,7 +701,7 @@ class VLVTests(samba.tests.TestCase):
                             except ldb.LdbError as e:
                                 if offset != 0:
                                     raise
-                                print ("offset %d denominator %d raised error "
+                                print("offset %d denominator %d raised error "
                                        "expected error %s\n"
                                        "(offset zero is illegal unless "
                                        "content count is zero)" %
@@ -740,7 +740,7 @@ class VLVTests(samba.tests.TestCase):
                                     cstr = str(c)
                                     if cstr.startswith('vlv_resp'):
                                         bits = cstr.rsplit(':')
-                                        print ("the answer is %s; we said %d" %
+                                        print("the answer is %s; we said %d" %
                                                (bits[2], real_offset))
                                         break
 
@@ -858,7 +858,7 @@ class VLVTests(samba.tests.TestCase):
                                                                      expression=expression,
                                                                      base=base,
                                                                      scope=ldb.SCOPE_ONELEVEL)
-            print ("searching for attr %s amongst %d deleted objects" %
+            print("searching for attr %s amongst %d deleted objects" %
                    (attr, len(expected_order)))
             sort_control = "server_sort:1:0:%s" % attr
             step = max(len(expected_order) // 10, 1)
@@ -1010,7 +1010,7 @@ class VLVTests(samba.tests.TestCase):
                             print(middle)
                             print(expected_order)
                             print()
-                            print ("\nattr %s offset %d before %d "
+                            print("\nattr %s offset %d before %d "
                                    "after %d gte %s" %
                                    (attr, offset, before, after, gte))
                         self.assertEquals(expected_results, results)