aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorSimon Glass2022-02-11 13:23:19 -0700
committerTom Rini2022-03-02 10:28:12 -0500
commitac05335d854179d4fb2cd018469b01682cba3a30 (patch)
treee89733d1a60d428601f5725b8afb58087f9b2487 /tools
parent32cc6ae273128510cffc536fc72f260181ef1744 (diff)
buildman: Correct pylint errors
Fix pylint errors that can be fixed and mask those that seem to be incorrect. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'tools')
-rw-r--r--tools/buildman/builder.py2
-rw-r--r--tools/buildman/cfgutil.py6
-rw-r--r--tools/buildman/func_test.py6
-rw-r--r--tools/buildman/kconfiglib.py1
-rwxr-xr-xtools/buildman/main.py4
5 files changed, 7 insertions, 12 deletions
diff --git a/tools/buildman/builder.py b/tools/buildman/builder.py
index 754642d4a68..ecbfa3e361e 100644
--- a/tools/buildman/builder.py
+++ b/tools/buildman/builder.py
@@ -1763,7 +1763,7 @@ class Builder:
if self.num_threads:
self.queue.put(job)
else:
- results = self._single_builder.RunJob(job)
+ self._single_builder.RunJob(job)
if self.num_threads:
term = threading.Thread(target=self.queue.join)
diff --git a/tools/buildman/cfgutil.py b/tools/buildman/cfgutil.py
index 4eba50868f5..ab74a8ef062 100644
--- a/tools/buildman/cfgutil.py
+++ b/tools/buildman/cfgutil.py
@@ -123,10 +123,10 @@ def adjust_cfg_file(fname, adjust_cfg):
C=val to set the value of C (val must have quotes if C is
a string Kconfig)
"""
- lines = tools.ReadFile(fname, binary=False).splitlines()
+ lines = tools.read_file(fname, binary=False).splitlines()
out_lines = adjust_cfg_lines(lines, adjust_cfg)
out = '\n'.join(out_lines) + '\n'
- tools.WriteFile(fname, out, binary=False)
+ tools.write_file(fname, out, binary=False)
def convert_list_to_dict(adjust_cfg_list):
"""Convert a list of config changes into the dict used by adjust_cfg_file()
@@ -219,7 +219,7 @@ def check_cfg_file(fname, adjust_cfg):
Returns:
str: None if OK, else an error string listing the problems
"""
- lines = tools.ReadFile(fname, binary=False).splitlines()
+ lines = tools.read_file(fname, binary=False).splitlines()
bad_cfgs = check_cfg_lines(lines, adjust_cfg)
if bad_cfgs:
out = [f'{cfg:20} {line}' for cfg, line in bad_cfgs]
diff --git a/tools/buildman/func_test.py b/tools/buildman/func_test.py
index 6fcceb0ea56..fbf6706644b 100644
--- a/tools/buildman/func_test.py
+++ b/tools/buildman/func_test.py
@@ -524,12 +524,6 @@ class TestFunctional(unittest.TestCase):
# Each commit has a config and make
self.assertEqual(self._make_calls, len(boards) * self._commits * 2)
- def testForceReconfigure(self):
- """The -f flag should force a rebuild"""
- self._RunControl('-b', TEST_BRANCH, '-C', '-o', self._output_dir)
- # Each commit has a config and make
- self.assertEqual(self._make_calls, len(boards) * self._commits * 2)
-
def testMrproper(self):
"""The -f flag should force a rebuild"""
self._RunControl('-b', TEST_BRANCH, '-m', '-o', self._output_dir)
diff --git a/tools/buildman/kconfiglib.py b/tools/buildman/kconfiglib.py
index c67895ced6b..b9f37567559 100644
--- a/tools/buildman/kconfiglib.py
+++ b/tools/buildman/kconfiglib.py
@@ -556,6 +556,7 @@ from os.path import dirname, exists, expandvars, islink, join, realpath
VERSION = (14, 1, 0)
+# pylint: disable=E1101
# File layout:
#
diff --git a/tools/buildman/main.py b/tools/buildman/main.py
index 01271061e6c..3b6af240802 100755
--- a/tools/buildman/main.py
+++ b/tools/buildman/main.py
@@ -30,8 +30,8 @@ from patman import terminal
from patman import test_util
def RunTests(skip_net_tests, verboose, args):
- import func_test
- import test
+ from buildman import func_test
+ from buildman import test
import doctest
result = unittest.TestResult()