diff mbox series

[yocto-autobuilder-helper,1/3] scripts/test_utils: test master nightly build case

Message ID 20230323092057.17918-2-alexis.lothore@bootlin.com
State New
Headers show
Series fix regression reporting for nightly build | expand

Commit Message

Alexis Lothoré March 23, 2023, 9:20 a.m. UTC
From: Alexis Lothoré <alexis.lothore@bootlin.com>

Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com>
---
 scripts/test_utils.py | 10 ++++++++++
 1 file changed, 10 insertions(+)
diff mbox series

Patch

diff --git a/scripts/test_utils.py b/scripts/test_utils.py
index ab91e3b..d02e9b2 100755
--- a/scripts/test_utils.py
+++ b/scripts/test_utils.py
@@ -99,6 +99,16 @@  class TestGetComparisonBranch(unittest.TestCase):
         self.assertEqual(
             comparebranch, None,  msg="Arbitrary repo/branch should not return any specific comparebranch")
 
+    def test_master_nightly(self):
+        repo = "ssh://git@push.yoctoproject.org/poky"
+        branch = "master"
+        basebranch, comparebranch = utils.getcomparisonbranch(
+            self.TEST_CONFIG, repo, branch)
+        self.assertEqual(
+            basebranch, "master", msg="Master branch should be returned")
+        self.assertEqual(
+            comparebranch, None,  msg="No specific comparebranch should be returned")
+
 
 if __name__ == '__main__':
     unittest.main()