#!/bin/bash
set -euo pipefail

SELF="$(/usr/bin/readlink -f -- "${BASH_SOURCE[0]}")"
BIN_DIR="$(cd -- "${SELF%/*}" && pwd -P)"
DEPLOY_ROOT="$(cd "$BIN_DIR/../../../.." && pwd -P)"
FIXTURE="$DEPLOY_ROOT/modules/harness/wrappers/model-test-fixture.sh"

[[ -x "$FIXTURE" ]] || {
  printf '{"ok":false,"detail":"landed model fixture missing or not executable: %s"}\n' "$FIXTURE" >&2
  exit 3
}
exec /bin/bash "$FIXTURE" "$@"
