diff --git a/src/datasmith/harbor_adapter/template/tests/setup.sh b/src/datasmith/harbor_adapter/template/tests/setup.sh index 9c3eb2c4..4f1f81c5 100644 --- a/src/datasmith/harbor_adapter/template/tests/setup.sh +++ b/src/datasmith/harbor_adapter/template/tests/setup.sh @@ -83,6 +83,11 @@ command -v snapshot-tool >/dev/null 2>&1 \ || micromamba run -n "$ENV_NAME" bash -c 'command -v snapshot-tool >/dev/null 2>&1' \ || { echo "[$(ts)] [setup] FATAL: snapshot-tool missing in '$ENV_NAME' — the correctness gate would be inert; rebuild the task image." >&2; exit 1; } +SETUP_PHASE="asv_machine" +# `asv run` without --machine looks up the hostname in ~/.asv-machine.json and stops if it is missing; results go to dockertest. +python -c 'import socket; from asv.machine import Machine, MachineCollection; MachineCollection.save(socket.gethostname(), {**Machine.get_defaults(), "machine": "dockertest"})' \ + || echo "[$(ts)] [setup] WARN: asv machine registration failed; agents must pass --machine." >&2 + SETUP_PHASE="extra_setup_commands" {{ extra_setup_commands }}