2022-05-23 14:13:09 +00:00
#!/bin/bash
set -e
2022-05-06 11:21:11 +00:00
# Clear up existing docker images and volume.
docker-compose down --remove-orphans --volumes
2022-05-23 14:13:09 +00:00
# Spin up TimescaleDB
docker-compose -f docker-compose.yml up -d migrations ipld-eth-db
sleep 45
2022-05-06 11:21:11 +00:00
2022-05-23 14:13:09 +00:00
# Run unit tests
go clean -testcache
2022-05-06 11:21:11 +00:00
PGPASSWORD = password DATABASE_USER = vdbm DATABASE_PORT = 8077 DATABASE_PASSWORD = password DATABASE_HOSTNAME = 127.0.0.1 DATABASE_NAME = vulcanize_testing make test
2022-05-23 14:13:09 +00:00
# Clean up
2022-05-06 11:21:11 +00:00
docker-compose down --remove-orphans --volumes