* [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup
@ 2022-11-01 18:13 Thomas Petazzoni via buildroot
2022-11-01 18:13 ` [Buildroot] [PATCH 2/3] support/testing/tests/package/test_python_crossbar: use ext2 instead of cpio Thomas Petazzoni via buildroot
` (3 more replies)
0 siblings, 4 replies; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2022-11-01 18:13 UTC (permalink / raw)
To: buildroot; +Cc: Lionel Flandrin, Thomas Petazzoni
It seems like on Gitlab CI, the runners are quite slow, and the Flask
server does not startup in the 15 seconds we give it. So increase this
to 30 seconds before trying to contact the Flask server.
Hopefully fixes:
https://gitlab.com/buildroot.org/buildroot/-/jobs/3249828594
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
support/testing/tests/package/test_python_flask.py | 2 +-
support/testing/tests/package/test_python_flask_expects_json.py | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/support/testing/tests/package/test_python_flask.py b/support/testing/tests/package/test_python_flask.py
index ef5d96bae9..9d8587e918 100644
--- a/support/testing/tests/package/test_python_flask.py
+++ b/support/testing/tests/package/test_python_flask.py
@@ -21,7 +21,7 @@ class TestPythonPy3Flask(TestPythonPackageBase):
_, exit_code = self.emulator.run(cmd, timeout=self.timeout)
# Give enough time for the flask server to start up
- time.sleep(15)
+ time.sleep(30)
cmd = "wget -q -O - http://127.0.0.1:5000/"
output, exit_code = self.emulator.run(cmd, timeout=self.timeout)
diff --git a/support/testing/tests/package/test_python_flask_expects_json.py b/support/testing/tests/package/test_python_flask_expects_json.py
index 5576cba2b4..91b8bf21b7 100644
--- a/support/testing/tests/package/test_python_flask_expects_json.py
+++ b/support/testing/tests/package/test_python_flask_expects_json.py
@@ -31,7 +31,7 @@ class TestPythonPy3FlaskExpectsJson(TestPythonPackageBase):
_, exit_code = self.emulator.run(cmd, timeout=self.timeout)
# Give enough time for the flask server to start up
- time.sleep(15)
+ time.sleep(30)
self.try_json("""{"email": "test", "name": "test"}""", 200)
self.try_json("""{"email": "test", "name": 2}""", 400)
--
2.37.3
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 6+ messages in thread* [Buildroot] [PATCH 2/3] support/testing/tests/package/test_python_crossbar: use ext2 instead of cpio
2022-11-01 18:13 [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup Thomas Petazzoni via buildroot
@ 2022-11-01 18:13 ` Thomas Petazzoni via buildroot
2022-11-14 10:22 ` Peter Korsgaard
2022-11-01 18:13 ` [Buildroot] [PATCH 3/3] support/testing/tests/package/test_gdb.py: drop version-specific tests Thomas Petazzoni via buildroot
` (2 subsequent siblings)
3 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2022-11-01 18:13 UTC (permalink / raw)
To: buildroot; +Cc: Thomas Petazzoni
The CPIO filesystem generated by the test_python_crossbar test is too
large, and doesn't fit as an initramfs in the 256MB of RAM available
in the versatilepb machine. This causes a "Initramfs unpacking failed:
write error" when booting, and many files being missing from the root
filesystem, ultimately causing the test to fail.
It would make sense to switch all test cases to use ext2 + a
hard-drive, but for now, let's fix the few test cases that are causing
problems.
Fixes:
https://gitlab.com/buildroot.org/buildroot/-/jobs/3249828587
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
.../testing/tests/package/test_python_crossbar.py | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/support/testing/tests/package/test_python_crossbar.py b/support/testing/tests/package/test_python_crossbar.py
index 83649aeec2..178b16be82 100644
--- a/support/testing/tests/package/test_python_crossbar.py
+++ b/support/testing/tests/package/test_python_crossbar.py
@@ -1,4 +1,5 @@
from tests.package.test_python import TestPythonPackageBase
+import os
class TestPythonPy3Crossbar(TestPythonPackageBase):
@@ -13,8 +14,16 @@ class TestPythonPy3Crossbar(TestPythonPackageBase):
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_ARMV5_EABI_GLIBC_STABLE=y
BR2_PACKAGE_PYTHON3=y
BR2_PACKAGE_PYTHON_CROSSBAR=y
- BR2_TARGET_ROOTFS_CPIO=y
- # BR2_TARGET_ROOTFS_TAR is not set
+ BR2_TARGET_ROOTFS_EXT2=y
+ BR2_TARGET_ROOTFS_EXT2_SIZE="120M"
"""
sample_scripts = ["tests/package/sample_python_crossbar.py"]
timeout = 60
+
+ def login(self):
+ ext2_file = os.path.join(self.builddir, "images", "rootfs.ext2")
+ self.emulator.boot(arch="armv5",
+ kernel="builtin",
+ options=["-drive", "file=%s,if=scsi,format=raw" % ext2_file],
+ kernel_cmdline=["rootwait", "root=/dev/sda"])
+ self.emulator.login()
--
2.37.3
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 6+ messages in thread* [Buildroot] [PATCH 3/3] support/testing/tests/package/test_gdb.py: drop version-specific tests
2022-11-01 18:13 [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup Thomas Petazzoni via buildroot
2022-11-01 18:13 ` [Buildroot] [PATCH 2/3] support/testing/tests/package/test_python_crossbar: use ext2 instead of cpio Thomas Petazzoni via buildroot
@ 2022-11-01 18:13 ` Thomas Petazzoni via buildroot
2022-11-03 22:08 ` [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup Thomas Petazzoni via buildroot
2022-11-14 10:22 ` Peter Korsgaard
3 siblings, 0 replies; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2022-11-01 18:13 UTC (permalink / raw)
To: buildroot; +Cc: Thomas Petazzoni
Back when support/testing/tests/package/test_gdb was introduced, there
was a significant difference in how gdb < 10 and gdb >= 10 were
handled in gdb.mk, which explained why we were testing both gdb 9.x
and gdb 11.x.
However, support for gdb 9.x has now been dropped, and we only support
gdb >= 10.x, so testing gdb 9.x and 11.x separately no longer make
much sense. In addition:
- other GDB tests in the same file already test the default version,
which is now 11.x, meaning we in fact have duplicated tests between
the ones testing the default version and the ones testing 11.x
specifically
- GDB 9.x has been removed, which means all the tests testing GDB 9.x
are failing, with a Config.in.legacy build error.
Fixes:
https://gitlab.com/buildroot.org/buildroot/-/jobs/3249828456 (TestGdbHostOnly9x)
https://gitlab.com/buildroot.org/buildroot/-/jobs/3249828454 (TestGdbHostGdbserver9x)
https://gitlab.com/buildroot.org/buildroot/-/jobs/3249828451 (TestGdbHostGdbTarget9x)
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
support/testing/tests/package/test_gdb.py | 108 ----------------------
1 file changed, 108 deletions(-)
diff --git a/support/testing/tests/package/test_gdb.py b/support/testing/tests/package/test_gdb.py
index a7b0870644..4712162349 100644
--- a/support/testing/tests/package/test_gdb.py
+++ b/support/testing/tests/package/test_gdb.py
@@ -91,114 +91,6 @@ class TestGdbFullTarget(BaseGdb):
self.verify_gdb()
-class TestGdbHostOnly9x(BaseGdb):
- config = \
- infra.basetest.MINIMAL_CONFIG + \
- """
- BR2_arm=y
- BR2_TOOLCHAIN_EXTERNAL=y
- BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
- BR2_PACKAGE_HOST_GDB=y
- BR2_GDB_VERSION_9_2=y
- """
-
- def test_run(self):
- self.verify_host_gdb()
-
-
-class TestGdbHostGdbserver9x(BaseGdb):
- config = \
- """
- BR2_arm=y
- BR2_TOOLCHAIN_EXTERNAL=y
- BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
- BR2_PACKAGE_HOST_GDB=y
- BR2_GDB_VERSION_9_2=y
- BR2_PACKAGE_GDB=y
- BR2_TARGET_ROOTFS_CPIO=y
- # BR2_TARGET_ROOTFS_TAR is not set
- """
-
- def test_run(self):
- self.verify_host_gdb()
- self.boot()
- self.verify_gdbserver()
-
-
-class TestGdbHostGdbTarget9x(BaseGdb):
- config = \
- """
- BR2_arm=y
- BR2_TOOLCHAIN_EXTERNAL=y
- BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
- BR2_PACKAGE_HOST_GDB=y
- BR2_GDB_VERSION_9_2=y
- BR2_PACKAGE_GDB=y
- BR2_PACKAGE_GDB_DEBUGGER=y
- BR2_TARGET_ROOTFS_CPIO=y
- # BR2_TARGET_ROOTFS_TAR is not set
- """
-
- def test_run(self):
- self.verify_host_gdb()
- self.boot()
- self.verify_gdb()
-
-
-class TestGdbHostOnly11x(BaseGdb):
- config = \
- infra.basetest.MINIMAL_CONFIG + \
- """
- BR2_arm=y
- BR2_TOOLCHAIN_EXTERNAL=y
- BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
- BR2_PACKAGE_HOST_GDB=y
- BR2_GDB_VERSION_11=y
- """
-
- def test_run(self):
- self.verify_host_gdb()
-
-
-class TestGdbHostGdbserver11x(BaseGdb):
- config = \
- """
- BR2_arm=y
- BR2_TOOLCHAIN_EXTERNAL=y
- BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
- BR2_PACKAGE_HOST_GDB=y
- BR2_GDB_VERSION_11=y
- BR2_PACKAGE_GDB=y
- BR2_TARGET_ROOTFS_CPIO=y
- # BR2_TARGET_ROOTFS_TAR is not set
- """
-
- def test_run(self):
- self.verify_host_gdb()
- self.boot()
- self.verify_gdbserver()
-
-
-class TestGdbHostGdbTarget11x(BaseGdb):
- config = \
- """
- BR2_arm=y
- BR2_TOOLCHAIN_EXTERNAL=y
- BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
- BR2_PACKAGE_HOST_GDB=y
- BR2_GDB_VERSION_11=y
- BR2_PACKAGE_GDB=y
- BR2_PACKAGE_GDB_DEBUGGER=y
- BR2_TARGET_ROOTFS_CPIO=y
- # BR2_TARGET_ROOTFS_TAR is not set
- """
-
- def test_run(self):
- self.verify_host_gdb()
- self.boot()
- self.verify_gdb()
-
-
class TestGdbArc(BaseGdb):
config = \
"""
--
2.37.3
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 6+ messages in thread* Re: [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup
2022-11-01 18:13 [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup Thomas Petazzoni via buildroot
2022-11-01 18:13 ` [Buildroot] [PATCH 2/3] support/testing/tests/package/test_python_crossbar: use ext2 instead of cpio Thomas Petazzoni via buildroot
2022-11-01 18:13 ` [Buildroot] [PATCH 3/3] support/testing/tests/package/test_gdb.py: drop version-specific tests Thomas Petazzoni via buildroot
@ 2022-11-03 22:08 ` Thomas Petazzoni via buildroot
2022-11-14 10:22 ` Peter Korsgaard
3 siblings, 0 replies; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2022-11-03 22:08 UTC (permalink / raw)
To: Thomas Petazzoni via buildroot; +Cc: Lionel Flandrin, Thomas Petazzoni
On Tue, 1 Nov 2022 19:13:17 +0100
Thomas Petazzoni via buildroot <buildroot@buildroot.org> wrote:
> It seems like on Gitlab CI, the runners are quite slow, and the Flask
> server does not startup in the 15 seconds we give it. So increase this
> to 30 seconds before trying to contact the Flask server.
>
> Hopefully fixes:
>
> https://gitlab.com/buildroot.org/buildroot/-/jobs/3249828594
>
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> ---
> support/testing/tests/package/test_python_flask.py | 2 +-
> support/testing/tests/package/test_python_flask_expects_json.py | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
Series applied to master.
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup
2022-11-01 18:13 [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup Thomas Petazzoni via buildroot
` (2 preceding siblings ...)
2022-11-03 22:08 ` [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup Thomas Petazzoni via buildroot
@ 2022-11-14 10:22 ` Peter Korsgaard
3 siblings, 0 replies; 6+ messages in thread
From: Peter Korsgaard @ 2022-11-14 10:22 UTC (permalink / raw)
To: Thomas Petazzoni via buildroot; +Cc: Lionel Flandrin, Thomas Petazzoni
>>>>> "Thomas" == Thomas Petazzoni via buildroot <buildroot@buildroot.org> writes:
> It seems like on Gitlab CI, the runners are quite slow, and the Flask
> server does not startup in the 15 seconds we give it. So increase this
> to 30 seconds before trying to contact the Flask server.
> Hopefully fixes:
> https://gitlab.com/buildroot.org/buildroot/-/jobs/3249828594
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Committed to 2022.08.x and 2022.02.x, thanks.
--
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2022-11-14 10:23 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-01 18:13 [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup Thomas Petazzoni via buildroot
2022-11-01 18:13 ` [Buildroot] [PATCH 2/3] support/testing/tests/package/test_python_crossbar: use ext2 instead of cpio Thomas Petazzoni via buildroot
2022-11-14 10:22 ` Peter Korsgaard
2022-11-01 18:13 ` [Buildroot] [PATCH 3/3] support/testing/tests/package/test_gdb.py: drop version-specific tests Thomas Petazzoni via buildroot
2022-11-03 22:08 ` [Buildroot] [PATCH 1/3] support/testing/tests/package/test_python_flask*: increase time after server startup Thomas Petazzoni via buildroot
2022-11-14 10:22 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox