[PATCH 10/20] patman: Use variables for series ID and title
Simon Glass
sjg at chromium.org
Thu May 8 09:28:34 CEST 2025
Rather than hard-coding these values in the sample patches, use
variables so that we can refer to these in tests.
Signed-off-by: Simon Glass <sjg at chromium.org>
---
tools/patman/func_test.py | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/tools/patman/func_test.py b/tools/patman/func_test.py
index 5ddefc3a9b1..9c7d5d8c381 100644
--- a/tools/patman/func_test.py
+++ b/tools/patman/func_test.py
@@ -59,6 +59,10 @@ class TestFunctional(unittest.TestCase):
verbosity = False
preserve_outdirs = False
+ # Fake patchwork info for testing
+ SERIES_ID_SECOND_V1 = 456
+ TITLE_SECOND = 'Series for my board'
+
@classmethod
def setup_test_args(cls, preserve_indir=False, preserve_outdirs=False,
toolpath=None, verbosity=None, no_capture=False):
@@ -508,16 +512,17 @@ a very nice colour.
Purple and purple
Even more purple
Could not be any more purple''')
- self.make_commit_with_file('serial: Add a serial driver', '''
+ self.make_commit_with_file('serial: Add a serial driver', f'''
Here is the serial driver
for my chip.
Cover-letter:
-Series for my board
+{self.TITLE_SECOND}
This series implements support
for my glorious board.
END
-Series-links: 183237
+Series-to: u-boot
+Series-links: {self.SERIES_ID_SECOND_V1}
''', 'serial.c', '''The code for the
serial driver is here''')
self.make_commit_with_file('bootm: Make it boot', '''
--
2.43.0
More information about the U-Boot
mailing list