#!/usr/bin/env bash set -euo pipefail ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" TEST_IMAGE="${TEST_IMAGE:-localhost/wiki-print:test}" if ! podman info >/dev/null 2>&1; then echo "Podman is not ready. Starting the Podman machine…" podman machine start fi cd "$ROOT_DIR" podman build --target test --tag "$TEST_IMAGE" . podman run --rm "$TEST_IMAGE"