patman: Rename check_patchwork_status()
This function actually shows the status and does some other things.
Rename it to better reflect its purpose.
Signed-off-by: Simon Glass <sjg@chromium.org>
diff --git a/tools/patman/control.py b/tools/patman/control.py
index c33ca82..06a9dfd 100644
--- a/tools/patman/control.py
+++ b/tools/patman/control.py
@@ -99,8 +99,8 @@
# Import this here to avoid failing on other commands if the dependencies
# are not present
from patman import status
- status.check_patchwork_status(series, found[0], branch, dest_branch, force,
- show_comments, url)
+ status.check_and_show_status(series, found[0], branch, dest_branch, force,
+ show_comments, url)
def do_patman(args):
diff --git a/tools/patman/func_test.py b/tools/patman/func_test.py
index 50fb537..31ba708 100644
--- a/tools/patman/func_test.py
+++ b/tools/patman/func_test.py
@@ -1045,8 +1045,8 @@
series = Series()
series.commits = [commit1, commit2]
terminal.set_print_test_mode()
- status.check_patchwork_status(series, '1234', None, None, False, False,
- None, self._fake_patchwork2)
+ status.check_and_show_status(series, '1234', None, None, False, False,
+ None, self._fake_patchwork2)
lines = iter(terminal.get_print_test_lines())
col = terminal.Color()
self.assertEqual(terminal.PrintLine(' 1 Subject 1', col.BLUE),
@@ -1159,9 +1159,9 @@
# <unittest.result.TestResult run=8 errors=0 failures=0>
terminal.set_print_test_mode()
- status.check_patchwork_status(series, '1234', branch, dest_branch,
- False, False, None, self._fake_patchwork3,
- repo)
+ status.check_and_show_status(series, '1234', branch, dest_branch,
+ False, False, None, self._fake_patchwork3,
+ repo)
lines = terminal.get_print_test_lines()
self.assertEqual(12, len(lines))
self.assertEqual(
@@ -1361,8 +1361,8 @@
series = Series()
series.commits = [commit1, commit2]
terminal.set_print_test_mode()
- status.check_patchwork_status(series, '1234', None, None, False, True,
- None, self._fake_patchwork2)
+ status.check_and_show_status(series, '1234', None, None, False, True,
+ None, self._fake_patchwork2)
lines = iter(terminal.get_print_test_lines())
col = terminal.Color()
self.assertEqual(terminal.PrintLine(' 1 Subject 1', col.BLUE),
diff --git a/tools/patman/status.py b/tools/patman/status.py
index 8edb4ce..57786e4 100644
--- a/tools/patman/status.py
+++ b/tools/patman/status.py
@@ -300,9 +300,9 @@
[parent.target])
return num_added
-def check_patchwork_status(series, series_id, branch, dest_branch, force,
- show_comments, url, rest_api=call_rest_api,
- test_repo=None):
+def check_and_show_status(series, series_id, branch, dest_branch, force,
+ show_comments, url, rest_api=call_rest_api,
+ test_repo=None):
"""Check the status of a series on Patchwork
This finds review tags and comments for a series in Patchwork, displaying