16 lines
388 B
Bash
Executable File
16 lines
388 B
Bash
Executable File
#!/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"
|