21 lines
486 B
Bash
Executable File
21 lines
486 B
Bash
Executable File
#!/usr/bin/env nix-shell
|
|
#!nix-shell -i bash
|
|
#!nix-shell -p python3 python3Packages.click python3Packages.ruff python3Packages.black python3Packages.mypy python3Packages.pytest
|
|
set -euo pipefail
|
|
|
|
here="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
cd "$here"
|
|
|
|
ruff check .
|
|
black --check .
|
|
mypy src
|
|
|
|
start=$(date +%s)
|
|
pytest
|
|
elapsed=$(( $(date +%s) - start ))
|
|
echo "Test suite duration: ${elapsed}s"
|
|
if [ $elapsed -gt 60 ]; then
|
|
echo "Test suite exceeded 60s budget." >&2
|
|
exit 1
|
|
fi
|