Tests: run benchmarks in container via Docker

This commit is contained in:
Lovell Fuller
2022-09-01 14:58:39 +01:00
parent 0e3bd46ca3
commit 953a94885b
4 changed files with 44 additions and 22 deletions

13
test/bench/run-with-docker.sh Executable file
View File

@@ -0,0 +1,13 @@
#!/usr/bin/env bash
set -e
if ! type docker >/dev/null; then
echo "Please install docker"
exit 1
fi
BRANCH=$(git branch --show-current)
echo "Running sharp performance tests using $BRANCH branch"
docker build --build-arg "BRANCH=$BRANCH" -t sharp-test-bench .
docker run --rm -it sharp-test-bench