Skip to contentSkip to conversation

Fix s6-portable-utils runtime tests

PATCH New J. Neuschäfer via buildroot 1 participant 3 messages Jul 26, 2024

lore
Share & tools
lore
#0 lore raw

cover Fix s6-portable-utils runtime tests

---
J. Neuschäfer (2):
support/testing: Fix s6-portable-utils test support/testing: Test eltest (part of execline)

 support/testing/tests/package/test_execline.py          | 5 +++++
 support/testing/tests/package/test_s6_portable_utils.py | 2 +-
 2 files changed, 6 insertions(+), 1 deletion(-)

---
base-commit: 541eb8bf7db553708ff2286995ce94b38fc8d537
change-id: 20240726-s6-tests-69bebc8f8d3a

Best regards,
--
J. Neuschäfer <[email protected]>

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot

#1 lore raw

PATCH 1/2 support/testing: Fix s6-portable-utils test

s6-test was removed in s6-portable-utils 2.3.0.0, and replaced with eltest (from execline). This change broke the existing runtime tests with commit 42fad03182 ("packages: bump skalibs-related packages").

Instead of s6-test simply use the shell built-in "test", which provides sufficient functionality.

---
 support/testing/tests/package/test_s6_portable_utils.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
support/testing/tests/package/test_s6_portable_utils.py +1 -1
index 372e3ba812..d4df70cd51 100644
@@ -28,5 +28,5 @@ class TestS6PortableUtils(infra.basetest.BRTest):
 
         _, exit_code = self.emulator.run("s6-mkfifo testpipe")
         self.assertEqual(exit_code, 0)
-        _, exit_code = self.emulator.run("s6-test -p testpipe")
+        _, exit_code = self.emulator.run("test -p testpipe")
         self.assertEqual(exit_code, 0)

--
2.43.0

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot

#2 lore raw

PATCH 2/2 support/testing: Test eltest (part of execline)

In reply to J. Neuschäfer via buildroot

The previous commit removes s6-test from the runtime tests. This commit adds the same test for eltest, which replaced s6-test.

---
 support/testing/tests/package/test_execline.py | 5 +++++
 1 file changed, 5 insertions(+)
support/testing/tests/package/test_execline.py +5 -0
index a7ea36c1a2..15ff92d762 100644
@@ -21,3 +21,8 @@ class TestExecline(infra.basetest.BRTest):
         output, exit_code = self.emulator.run("execlineb -c 'echo hello world'")
         self.assertEqual(exit_code, 0)
         self.assertEqual(output[0].strip(), "hello world")
+
+        _, exit_code = self.emulator.run("mkfifo testpipe")
+        self.assertEqual(exit_code, 0)
+        _, exit_code = self.emulator.run("execlineb -c 'eltest -p testpipe'")
+        self.assertEqual(exit_code, 0)

--
2.43.0

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot