From e7043ea3abec0cb2673c52cc45e3358f801fb874 Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Mon, 26 Jan 2026 02:10:31 +0100 Subject: [PATCH 1/8] .zuul: Drop one "o" and rename the project as "Toolbx" This is meant to make the project more searchable on the Internet. More and more people have been pointing out that "toolbox" is terribly difficult to search for, and it's impossible to find any decent Internet real estate by that name. https://github.com/containers/toolbox/issues/1399 https://github.com/containers/toolbox/pull/1740 (backported from commit c3403dae8cb0544ecaa94abdcd5eb3c896851b90) --- .zuul.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.zuul.yaml b/.zuul.yaml index a88e8c5d3..ff2b1f00b 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -17,7 +17,7 @@ --- - job: name: unit-test - description: Run Toolbox's unit tests declared in Meson + description: Run Toolbx's unit tests declared in Meson timeout: 1800 nodeset: nodes: @@ -28,7 +28,7 @@ - job: name: unit-test-migration-path-for-coreos-toolbox - description: Run Toolbox's unit tests declared in Meson when built with -Dmigration_path_for_coreos_toolbox + description: Run Toolbx's unit tests declared in Meson when built with -Dmigration_path_for_coreos_toolbox timeout: 600 nodeset: nodes: @@ -39,7 +39,7 @@ - job: name: unit-test-restricted - description: Run Toolbox's unit tests declared in Meson in a restricted build environment + description: Run Toolbx's unit tests declared in Meson in a restricted build environment timeout: 1800 nodeset: nodes: @@ -50,7 +50,7 @@ - job: name: system-test-fedora-rawhide - description: Run Toolbox's system tests in Fedora Rawhide + description: Run Toolbx's system tests in Fedora Rawhide timeout: 4800 nodeset: nodes: From ec3553bbb0c4f19c4299bb9068217f6bb70db4be Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Mon, 11 Mar 2024 16:23:16 +0100 Subject: [PATCH 2/8] .zuul: Enable testing on Fedora 40 https://github.com/containers/toolbox/pull/1468 https://github.com/containers/toolbox/pull/1740 (cherry picked from commit 9ea89670c6508479be2f9eaa9f71de3812a97b56) --- .zuul.yaml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.zuul.yaml b/.zuul.yaml index ff2b1f00b..b3415f764 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -59,6 +59,17 @@ pre-run: playbooks/setup-env.yaml run: playbooks/system-test.yaml +- job: + name: system-test-fedora-40 + description: Run Toolbx's system tests in Fedora 40 + timeout: 3600 + nodeset: + nodes: + - name: fedora-40 + label: cloud-fedora-40 + pre-run: playbooks/setup-env.yaml + run: playbooks/system-test.yaml + - job: name: system-test-fedora-39 description: Run Toolbx's system tests in Fedora 39 @@ -85,6 +96,7 @@ periodic: jobs: - system-test-fedora-rawhide + - system-test-fedora-40 - system-test-fedora-39 - system-test-fedora-38 check: @@ -93,6 +105,7 @@ - unit-test-migration-path-for-coreos-toolbox - unit-test-restricted - system-test-fedora-rawhide + - system-test-fedora-40 - system-test-fedora-39 - system-test-fedora-38 gate: @@ -101,5 +114,6 @@ - unit-test-migration-path-for-coreos-toolbox - unit-test-restricted - system-test-fedora-rawhide + - system-test-fedora-40 - system-test-fedora-39 - system-test-fedora-38 From a72f1da59046db5d290b7d10db5c4346d4dd6ddf Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Tue, 13 Feb 2024 21:56:06 +0100 Subject: [PATCH 3/8] test/system: Unbreak Podman's downstream Fedora CI The paths to bats-assert and bats-support are broken, if bats(1) is invoked from any other location than the parent directory of the 'tests' directory. eg., Podman's downstream Fedora CI invokes the tests as: $ cd /path/to/toolbox/test/system $ bats . ... and it led to [1]: 1..306 # test suite: Set up # Missing dependencies # Forgot to run 'git submodule init' and 'git submodule update' ? # test suite: Tear down not ok 1 setup_suite # (from function `setup_suite' in test file ./setup_suite.bash, line 33) # `return 1' failed # bats warning: Executed 1 instead of expected 306 tests Fallout from 2c0960660330dc6be6861502988695f9812c475a [1] https://bugzilla.redhat.com/show_bug.cgi?id=2263968 https://github.com/containers/toolbox/pull/1448 https://github.com/containers/toolbox/pull/1740 (cherry picked from commit 6838e9347199e875f9869acd2afa64688161ca11) --- test/system/setup_suite.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/system/setup_suite.bash b/test/system/setup_suite.bash index e4edf232b..01985b7f9 100644 --- a/test/system/setup_suite.bash +++ b/test/system/setup_suite.bash @@ -17,7 +17,7 @@ missing_dependencies=false -if [ -f test/system/libs/bats-assert/load.bash ] && [ -f test/system/libs/bats-support/load.bash ]; then +if [ -f "$BATS_TEST_DIRNAME/libs/bats-assert/load.bash" ] && [ -f "$BATS_TEST_DIRNAME/libs/bats-support/load.bash" ]; then load 'libs/helpers' else missing_dependencies=true From c0fb8f317eae85ffb6dfbe7609931ff4cefc12c2 Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Fri, 23 Feb 2024 10:38:16 +0100 Subject: [PATCH 4/8] test/system: Unbreak Podman's downstream Fedora CI (part 2) The working directory from which bats(1) is invoked might not be part of the Toolbx container. eg., Podman's downstream Fedora CI invokes the tests as: $ cd /path/to/toolbox/test/system $ bats . ... and it led to [1]: not ok 110 run: Smoke test with true(1) # (from function `assert_output' in file ./libs/bats-assert/src/assert.bash, line 255, # in test file ./104-run.bats, line 38) # `assert_output ""' failed # # -- output differs -- # expected (0 lines): # # actual (3 lines): # Error: crun: chdir to `/usr/share/toolbox/test/system`: No such file or directory: OCI runtime attempted to invoke a command that was not found # Error: directory /usr/share/toolbox/test/system not found in container fedora-toolbox-41 # Using /home/testuser instead. # -- # [1] https://bugzilla.redhat.com/show_bug.cgi?id=2263968 https://github.com/containers/toolbox/pull/1457 https://github.com/containers/toolbox/pull/1740 (cherry picked from commit 9d3ae61ed8c5194916e46c425aaa9ce7874fe386) --- test/system/104-run.bats | 2 ++ test/system/201-ipc.bats | 2 ++ test/system/203-network.bats | 2 ++ test/system/206-user.bats | 2 ++ test/system/210-ulimit.bats | 2 ++ test/system/211-dbus.bats | 2 ++ test/system/220-environment-variables.bats | 2 ++ 7 files changed, 14 insertions(+) diff --git a/test/system/104-run.bats b/test/system/104-run.bats index b2f3942a3..2c5b2b616 100644 --- a/test/system/104-run.bats +++ b/test/system/104-run.bats @@ -23,9 +23,11 @@ setup() { bats_require_minimum_version 1.7.0 _setup_environment cleanup_containers + pushd "$HOME" || return 1 } teardown() { + popd || return 1 cleanup_containers } diff --git a/test/system/201-ipc.bats b/test/system/201-ipc.bats index 15c791dec..09200b41d 100644 --- a/test/system/201-ipc.bats +++ b/test/system/201-ipc.bats @@ -23,9 +23,11 @@ setup() { bats_require_minimum_version 1.7.0 _setup_environment cleanup_containers + pushd "$HOME" || return 1 } teardown() { + popd || return 1 cleanup_containers } diff --git a/test/system/203-network.bats b/test/system/203-network.bats index db1ba561f..012374e33 100644 --- a/test/system/203-network.bats +++ b/test/system/203-network.bats @@ -35,9 +35,11 @@ setup() { bats_require_minimum_version 1.7.0 _setup_environment cleanup_containers + pushd "$HOME" || return 1 } teardown() { + popd || return 1 cleanup_containers } diff --git a/test/system/206-user.bats b/test/system/206-user.bats index c295d8a61..9920d8fee 100644 --- a/test/system/206-user.bats +++ b/test/system/206-user.bats @@ -23,9 +23,11 @@ setup() { bats_require_minimum_version 1.7.0 _setup_environment cleanup_containers + pushd "$HOME" || return 1 } teardown() { + popd || return 1 cleanup_containers } diff --git a/test/system/210-ulimit.bats b/test/system/210-ulimit.bats index ea0c46685..ea08feea1 100644 --- a/test/system/210-ulimit.bats +++ b/test/system/210-ulimit.bats @@ -23,9 +23,11 @@ setup() { bats_require_minimum_version 1.7.0 _setup_environment cleanup_containers + pushd "$HOME" || return 1 } teardown() { + popd || return 1 cleanup_containers } diff --git a/test/system/211-dbus.bats b/test/system/211-dbus.bats index 295bb71b2..61c543a56 100644 --- a/test/system/211-dbus.bats +++ b/test/system/211-dbus.bats @@ -23,9 +23,11 @@ setup() { bats_require_minimum_version 1.7.0 _setup_environment cleanup_containers + pushd "$HOME" || return 1 } teardown() { + popd || return 1 cleanup_containers } diff --git a/test/system/220-environment-variables.bats b/test/system/220-environment-variables.bats index 0e1356654..eb2f39809 100644 --- a/test/system/220-environment-variables.bats +++ b/test/system/220-environment-variables.bats @@ -23,9 +23,11 @@ setup() { bats_require_minimum_version 1.7.0 _setup_environment cleanup_containers + pushd "$HOME" || return 1 } teardown() { + popd || return 1 cleanup_containers } From 4e544024abdc6c9e3bb9d8f127b752ac218637d8 Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Thu, 15 Aug 2024 00:06:18 +0200 Subject: [PATCH 5/8] .zuul: Drop testing on Fedora 38 Fedora 38 reached End of Life on 21st May 2024: https://docs.fedoraproject.org/en-US/releases/eol/ https://github.com/containers/toolbox/pull/1527 https://github.com/containers/toolbox/pull/1741 (cherry picked from commit b684b190d1d931434d0d7d63c841973101dfb928) --- .zuul.yaml | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/.zuul.yaml b/.zuul.yaml index b3415f764..107ef2d47 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -81,24 +81,12 @@ pre-run: playbooks/setup-env.yaml run: playbooks/system-test.yaml -- job: - name: system-test-fedora-38 - description: Run Toolbx's system tests in Fedora 38 - timeout: 3600 - nodeset: - nodes: - - name: fedora-38 - label: cloud-fedora-38 - pre-run: playbooks/setup-env.yaml - run: playbooks/system-test.yaml - - project: periodic: jobs: - system-test-fedora-rawhide - system-test-fedora-40 - system-test-fedora-39 - - system-test-fedora-38 check: jobs: - unit-test @@ -107,7 +95,6 @@ - system-test-fedora-rawhide - system-test-fedora-40 - system-test-fedora-39 - - system-test-fedora-38 gate: jobs: - unit-test @@ -116,4 +103,3 @@ - system-test-fedora-rawhide - system-test-fedora-40 - system-test-fedora-39 - - system-test-fedora-38 From 23b4a3473c691893eb9cf9f32e264ac680caee02 Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Wed, 14 Aug 2024 21:04:02 +0200 Subject: [PATCH 6/8] test/system: Consolidate teardown() to remove both containers & images It's far more consistent and understandable if all tests start with a clean state without any containers or images present. Otherwise, the subtle side-effects of having some image left behind from a previous test can lead to surprises, and there's no need to spend time wondering whether some tests should only clean up the containers or both containers and images. This additional work of cleaning up the images for all tests makes it necessary to increase the timeout for all Fedora nodes to prevent the CI from timing out. https://github.com/containers/toolbox/pull/1526 https://github.com/containers/toolbox/pull/1741 (backported from commits 67d40024ce98451dffc738294a136b579ff295ad and 55c0e6378657757c305334adaead804c487817b6) --- .zuul.yaml | 6 +++--- test/system/101-create.bats | 4 ++-- test/system/103-container.bats | 4 ++-- test/system/104-run.bats | 4 ++-- test/system/105-enter.bats | 4 ++-- test/system/106-rm.bats | 4 ++-- test/system/201-ipc.bats | 4 ++-- test/system/203-network.bats | 4 ++-- test/system/206-user.bats | 4 ++-- test/system/210-ulimit.bats | 4 ++-- test/system/211-dbus.bats | 4 ++-- test/system/220-environment-variables.bats | 4 ++-- test/system/libs/helpers.bash | 5 ----- 13 files changed, 25 insertions(+), 30 deletions(-) diff --git a/.zuul.yaml b/.zuul.yaml index 107ef2d47..77378b303 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -51,7 +51,7 @@ - job: name: system-test-fedora-rawhide description: Run Toolbx's system tests in Fedora Rawhide - timeout: 4800 + timeout: 7800 nodeset: nodes: - name: fedora-rawhide @@ -62,7 +62,7 @@ - job: name: system-test-fedora-40 description: Run Toolbx's system tests in Fedora 40 - timeout: 3600 + timeout: 6600 nodeset: nodes: - name: fedora-40 @@ -73,7 +73,7 @@ - job: name: system-test-fedora-39 description: Run Toolbx's system tests in Fedora 39 - timeout: 3600 + timeout: 6600 nodeset: nodes: - name: fedora-39 diff --git a/test/system/101-create.bats b/test/system/101-create.bats index f0b58f69d..02791673e 100644 --- a/test/system/101-create.bats +++ b/test/system/101-create.bats @@ -21,11 +21,11 @@ load 'libs/helpers' setup() { _setup_environment - cleanup_containers + cleanup_all } teardown() { - cleanup_containers + cleanup_all } @test "create: Smoke test" { diff --git a/test/system/103-container.bats b/test/system/103-container.bats index b339315ea..13c1e0f22 100644 --- a/test/system/103-container.bats +++ b/test/system/103-container.bats @@ -21,11 +21,11 @@ load 'libs/helpers' setup() { _setup_environment - cleanup_containers + cleanup_all } teardown() { - cleanup_containers + cleanup_all } diff --git a/test/system/104-run.bats b/test/system/104-run.bats index 2c5b2b616..6f6a51351 100644 --- a/test/system/104-run.bats +++ b/test/system/104-run.bats @@ -22,13 +22,13 @@ load 'libs/helpers' setup() { bats_require_minimum_version 1.7.0 _setup_environment - cleanup_containers + cleanup_all pushd "$HOME" || return 1 } teardown() { popd || return 1 - cleanup_containers + cleanup_all } @test "run: Smoke test with true(1)" { diff --git a/test/system/105-enter.bats b/test/system/105-enter.bats index c05556049..ef1ac76de 100644 --- a/test/system/105-enter.bats +++ b/test/system/105-enter.bats @@ -21,11 +21,11 @@ load 'libs/helpers' setup() { _setup_environment - cleanup_containers + cleanup_all } teardown() { - cleanup_containers + cleanup_all } @test "enter: Try to enter the default container with no containers created" { diff --git a/test/system/106-rm.bats b/test/system/106-rm.bats index 9b5d3082d..0f0a76033 100644 --- a/test/system/106-rm.bats +++ b/test/system/106-rm.bats @@ -21,11 +21,11 @@ load 'libs/helpers' setup() { _setup_environment - cleanup_containers + cleanup_all } teardown() { - cleanup_containers + cleanup_all } diff --git a/test/system/201-ipc.bats b/test/system/201-ipc.bats index 09200b41d..20fdb32af 100644 --- a/test/system/201-ipc.bats +++ b/test/system/201-ipc.bats @@ -22,13 +22,13 @@ load 'libs/helpers' setup() { bats_require_minimum_version 1.7.0 _setup_environment - cleanup_containers + cleanup_all pushd "$HOME" || return 1 } teardown() { popd || return 1 - cleanup_containers + cleanup_all } @test "ipc: No namespace" { diff --git a/test/system/203-network.bats b/test/system/203-network.bats index 012374e33..4d88dc4e6 100644 --- a/test/system/203-network.bats +++ b/test/system/203-network.bats @@ -34,13 +34,13 @@ readonly RESOLVER_SH='resolvectl --legend false --no-pager --type "$0" query "$1 setup() { bats_require_minimum_version 1.7.0 _setup_environment - cleanup_containers + cleanup_all pushd "$HOME" || return 1 } teardown() { popd || return 1 - cleanup_containers + cleanup_all } @test "network: No namespace" { diff --git a/test/system/206-user.bats b/test/system/206-user.bats index 9920d8fee..b51434ac2 100644 --- a/test/system/206-user.bats +++ b/test/system/206-user.bats @@ -22,13 +22,13 @@ load 'libs/helpers' setup() { bats_require_minimum_version 1.7.0 _setup_environment - cleanup_containers + cleanup_all pushd "$HOME" || return 1 } teardown() { popd || return 1 - cleanup_containers + cleanup_all } @test "user: Separate namespace" { diff --git a/test/system/210-ulimit.bats b/test/system/210-ulimit.bats index ea08feea1..ce601da7c 100644 --- a/test/system/210-ulimit.bats +++ b/test/system/210-ulimit.bats @@ -22,13 +22,13 @@ load 'libs/helpers' setup() { bats_require_minimum_version 1.7.0 _setup_environment - cleanup_containers + cleanup_all pushd "$HOME" || return 1 } teardown() { popd || return 1 - cleanup_containers + cleanup_all } @test "ulimit: real-time non-blocking time (hard)" { diff --git a/test/system/211-dbus.bats b/test/system/211-dbus.bats index 61c543a56..ca34101ac 100644 --- a/test/system/211-dbus.bats +++ b/test/system/211-dbus.bats @@ -22,13 +22,13 @@ load 'libs/helpers' setup() { bats_require_minimum_version 1.7.0 _setup_environment - cleanup_containers + cleanup_all pushd "$HOME" || return 1 } teardown() { popd || return 1 - cleanup_containers + cleanup_all } @test "dbus: session bus inside the default container" { diff --git a/test/system/220-environment-variables.bats b/test/system/220-environment-variables.bats index eb2f39809..bc818b29c 100644 --- a/test/system/220-environment-variables.bats +++ b/test/system/220-environment-variables.bats @@ -22,13 +22,13 @@ load 'libs/helpers' setup() { bats_require_minimum_version 1.7.0 _setup_environment - cleanup_containers + cleanup_all pushd "$HOME" || return 1 } teardown() { popd || return 1 - cleanup_containers + cleanup_all } @test "environment variables: HISTFILESIZE inside the default container" { diff --git a/test/system/libs/helpers.bash b/test/system/libs/helpers.bash index 248ba4df7..fb724c617 100644 --- a/test/system/libs/helpers.bash +++ b/test/system/libs/helpers.bash @@ -37,11 +37,6 @@ function cleanup_all() { } -function cleanup_containers() { - "$PODMAN" rm --all --force >/dev/null -} - - function _setup_environment() { _setup_containers_storage check_xdg_runtime_dir From 316a3b18097b6fb784242b9172e1d8ce10521b0f Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Wed, 18 Sep 2024 22:34:45 +0200 Subject: [PATCH 7/8] .zuul: Try to prevent the CI from timing out on Fedora 39 and 40 Currently, the CI has been frequently timing out on stable Fedora nodes. So, increase the timeout from 1 hour 50 minutes to 2 hours to avoid that. For what it's worth, the timeout for Fedora Rawhide nodes is 2 hours 10 minutes and it seems enough. https://github.com/containers/toolbox/pull/1546 https://github.com/containers/toolbox/pull/1741 (backported from commit f2dc3b8f63c00f7698d91183600435509c945baa) --- .zuul.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.zuul.yaml b/.zuul.yaml index 77378b303..88c9b59bf 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -62,7 +62,7 @@ - job: name: system-test-fedora-40 description: Run Toolbx's system tests in Fedora 40 - timeout: 6600 + timeout: 7200 nodeset: nodes: - name: fedora-40 @@ -73,7 +73,7 @@ - job: name: system-test-fedora-39 description: Run Toolbx's system tests in Fedora 39 - timeout: 6600 + timeout: 7200 nodeset: nodes: - name: fedora-39 From c09ef38fa1e43c668439120486726488d43d3c68 Mon Sep 17 00:00:00 2001 From: Debarshi Ray Date: Wed, 25 Sep 2024 18:25:56 +0200 Subject: [PATCH 8/8] .zuul: Try to prevent the CI from timing out on Fedora This keeps the timeout for the Fedora nodes synchronized with the main branch. https://github.com/containers/toolbox/pull/1548 https://github.com/containers/toolbox/pull/1741 (backported from commit 83f28c52e47c2d44acbc5c8454ea23ba70ecdb6f) --- .zuul.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.zuul.yaml b/.zuul.yaml index 88c9b59bf..319d1dd75 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -51,7 +51,7 @@ - job: name: system-test-fedora-rawhide description: Run Toolbx's system tests in Fedora Rawhide - timeout: 7800 + timeout: 10800 nodeset: nodes: - name: fedora-rawhide @@ -62,7 +62,7 @@ - job: name: system-test-fedora-40 description: Run Toolbx's system tests in Fedora 40 - timeout: 7200 + timeout: 9000 nodeset: nodes: - name: fedora-40 @@ -73,7 +73,7 @@ - job: name: system-test-fedora-39 description: Run Toolbx's system tests in Fedora 39 - timeout: 7200 + timeout: 9000 nodeset: nodes: - name: fedora-39