Skip to content

Refactor TestGetBountyIndexById To Use A Real Postgres DB For The Test #1267

Refactor TestGetBountyIndexById To Use A Real Postgres DB For The Test

Refactor TestGetBountyIndexById To Use A Real Postgres DB For The Test #1267

Workflow file for this run

name: Tests
on:
pull_request:
branches:
- "*"
jobs:
test-go:
name: Go
runs-on:
- ubuntu-latest
steps:
- name: Enable docker.host.internal for Ubuntu
run: |
pwd && sudo bash -c 'echo "172.17.0.1 host.docker.internal" >> /etc/hosts'
- uses: actions/checkout@v2
- name: Starting DB
run: docker compose -f ./docker/testdb-docker-compose.yml -p test_db up -d
- name: Install cover
run: go get golang.org/x/tools/cmd/cover
- name: Tests
run: RELAY_AUTH_KEY=TEST go test ./... -race -v -coverprofile=coverage.out && ./cover-check.sh coverage.out 8.4
- name: Droping with docker compose
run: docker compose -f ./docker/testdb-docker-compose.yml -p test_db down