Merge pull request #109 from oasisprotocol/csillag/mobile-dashboard #446
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: Build and test | |
on: | |
push: | |
branches: [master] | |
pull_request: | |
branches: [master] | |
jobs: | |
build-test: | |
services: | |
sapphire-localnet-ci: | |
image: ghcr.io/oasisprotocol/sapphire-localnet:latest | |
ports: | |
- 8545:8545 | |
options: >- | |
--rm | |
--health-cmd="test -f /CONTAINER_READY" | |
--health-start-period=90s | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 18 | |
- uses: pnpm/action-setup@v4 | |
name: Install pnpm | |
with: | |
version: 9 | |
run_install: false | |
- name: Install | |
run: pnpm install --frozen-lockfile | |
- name: Build backend | |
working-directory: hardhat | |
run: pnpm build | |
- name: Build TypeChain contracts | |
working-directory: contracts | |
run: pnpm build | |
- name: Test backend | |
working-directory: hardhat | |
run: pnpm hardhat --network sapphire-localnet test | |
- name: Build frontend | |
working-directory: frontend | |
run: pnpm build |