Skip to content

Commit e0c7bde

Browse files
committed
fix(e2e): serialize Kubernetes HA deployment tests
Signed-off-by: Drew Newberry <anewberry@nvidia.com>
1 parent 3e197a7 commit e0c7bde

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

‎architecture/build.md‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,9 @@ the managed Podman driver path, Kubernetes database scenarios, and Docker-hosted
112112
SDK and policy-advisor E2E checks. The managed Podman test gateway receives the
113113
same run-specific sandbox runtime image as the standalone driver so each round
114114
uses the image built from its source commit.
115+
The Kubernetes HA test binary runs one test at a time because its scenarios
116+
scale and roll the same gateway deployment, and separate Nextest processes do
117+
not share their in-process lock.
115118
Policy-advisor E2E checks build a dedicated Docker workload with curl and cargo
116119
at the paths their denial scenarios inspect.
117120
The Docker gateway wrapper exports its resolved sandbox image to the test

‎e2e/rust/e2e-kubernetes.sh‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,12 @@ test_filter=()
5858
if [ -n "${OPENSHELL_E2E_KUBE_TEST:-}" ]; then
5959
test_filter+=(--test "${OPENSHELL_E2E_KUBE_TEST}")
6060
fi
61+
test_threads=()
62+
if [ "${OPENSHELL_E2E_KUBE_TEST:-}" = "kubernetes_ha_rebalancing" ]; then
63+
# These tests scale and roll the same deployment. Nextest starts each test
64+
# in its own process, so their in-process mutex cannot serialize them.
65+
test_threads+=(--test-threads 1)
66+
fi
6167

6268
is_operator_workspace_mode() {
6369
[[ ",${E2E_FEATURES}," == *",e2e-kubernetes-workspace-operator,"* ]]
@@ -99,6 +105,7 @@ run_e2e() {
99105
--target-dir "${ROOT}/e2e/rust/target" \
100106
--manifest-path "${ROOT}/e2e/rust/Cargo.toml" \
101107
--features "${E2E_FEATURES}" \
108+
${test_threads[@]+"${test_threads[@]}"} \
102109
${test_filter[@]+"${test_filter[@]}"}
103110
}
104111

0 commit comments

Comments
 (0)