tests: migrate pending-recognition seam to the pruning contract
This commit is contained in:
1 parent
02a787683c
commit
bd96906aee
1 file changed
+9
-3
@@ -198,12 +198,18 @@ REMOTE_DEPLOY="$REPO_ROOT/scripts/deploy-remote.sh"
|
|||||||
}
|
}
|
||||||
|
|
||||||
@test "remote runner recognizes a pending service at the same revision" {
|
@test "remote runner recognizes a pending service at the same revision" {
|
||||||
|
# Contract superseded 2026-09-17: recognition used to mean "retry and
|
||||||
|
# hard-fail at the dispatcher" (exit 2), which let a retired service's
|
||||||
|
# stale pending entry (frank-default-sightsound) block every deploy
|
||||||
|
# before the e2e gate. Recognition now means: name the entry, prune it
|
||||||
|
# to the trash, and keep the run going.
|
||||||
local state_dir="$(mktemp -d)"
|
local state_dir="$(mktemp -d)"
|
||||||
printf 'revision=%s\nstatus=pending\n' "$(git rev-parse HEAD)" > "$state_dir/unknown-service"
|
printf 'revision=%s\nstatus=pending\n' "$(git rev-parse HEAD)" > "$state_dir/unknown-service"
|
||||||
run env DEPLOY_STATE_DIR="$state_dir" REMOTE_DIR="$REPO_ROOT" \
|
run env DEPLOY_STATE_DIR="$state_dir" REMOTE_DIR="$REPO_ROOT" HOME="$(mktemp -d)" \
|
||||||
bash "$REMOTE_DEPLOY" dankclaw "$(git rev-parse HEAD)" --pending
|
bash "$REMOTE_DEPLOY" dankclaw "$(git rev-parse HEAD)" --pending
|
||||||
[ "$status" -eq 2 ]
|
[ "$status" -eq 0 ]
|
||||||
[[ "$output" == *"unknown-service"* || "$output" == *"not deployed"* ]]
|
[[ "$output" == *"unknown-service"* ]]
|
||||||
|
[ ! -e "$state_dir/unknown-service" ]
|
||||||
}
|
}
|
||||||
|
|
||||||
@test "top-level deployer delegates to the service-scoped remote runner" {
|
@test "top-level deployer delegates to the service-scoped remote runner" {
|
||||||
|
|||||||
Reference in new issue
Block a user