chore: run anvil using compose #2
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker Test | |
on: | |
push: | |
branches-ignore: | |
- main | |
# pull_request: | |
# branches: | |
# - '*' | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Build Docker image | |
run: docker-compose -f compose.yaml up -d | |
- name: Wait for container to be healthy | |
run: docker-compose -f compose.yaml exec contracts sh -c 'while ! nc -z localhost 8545; do sleep 1; done' | |
- name: Run tests | |
run: yarn test | |
- name: Stop Docker container | |
run: docker-compose -f compose.yaml down |