chore: add script for running tests in Docker container

This commit is contained in:
2026-03-31 21:58:49 -07:00
parent 5b91cf1426
commit 9c884ee020
+15
View File
@@ -0,0 +1,15 @@
#!/bin/bash
# Run tests in a Node.js container (for consistent environment)
set -e
echo "Running tests in node:20-alpine container..."
echo "This avoids Node.js setup time and ensures consistent environment."
echo ""
# Run unit tests in container
docker run --rm \
-v "$(pwd):/app" \
-w /app \
node:20-alpine \
sh -c "apk add --no-cache bash git && npm ci && npm run test:run"