runtime: Bump Oasis SDK to 0.9.0 and prepare 0.8.0-testnet #933
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: contracts-test | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
contracts-test: | |
runs-on: ubuntu-latest | |
services: | |
sapphire-localnet-ci: | |
image: ghcr.io/oasisprotocol/sapphire-localnet:latest | |
ports: | |
- 8545:8545 | |
- 8546:8546 | |
env: | |
OASIS_DEPOSIT: /oasis-deposit -test-mnemonic -n 5 | |
options: >- | |
--rm | |
--health-cmd="/oasis-node debug control wait-ready -a unix:/serverdir/node/net-runner/network/client-0/internal.sock" | |
--health-start-period=90s | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install jq | |
run: sudo apt install -y jq | |
- name: Wait for gateway | |
run: bash .github/wait-until-ready.sh | |
- name: Python client tests | |
working-directory: clients/py | |
run: | | |
python3 -mpip install --user -r requirements.txt | |
python3 -munittest discover | |
- name: Install Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 18 | |
- uses: pnpm/action-setup@v4 | |
name: Install pnpm | |
id: pnpm-install | |
with: | |
version: 8 | |
run_install: false | |
- name: Get pnpm store directory | |
id: pnpm-cache | |
run: | | |
echo "pnpm_cache_dir=$(pnpm store path)" >> $GITHUB_OUTPUT | |
- uses: actions/cache@v4 | |
name: Setup pnpm cache | |
with: | |
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} | |
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | |
restore-keys: | | |
${{ runner.os }}-pnpm-store- | |
- name: Install Foundry | |
uses: foundry-rs/foundry-toolchain@v1 | |
- name: Install forge doc deps | |
run: cargo install mdbook-pagetoc | |
- name: Install dependencies | |
run: pnpm install | |
- name: Build JS client | |
working-directory: clients/js | |
run: pnpm build | |
- name: Build hardhat integration | |
working-directory: integrations/hardhat | |
run: pnpm build | |
- name: Test contracts with Hardhat | |
working-directory: contracts | |
run: pnpm hardhat test --network sapphire-localnet-ci | |
- name: Build docs | |
working-directory: contracts | |
run: pnpm doc | |
- name: hardhat test examples/hardhat | |
working-directory: examples/hardhat | |
run: pnpm hardhat run --network sapphire-localnet scripts/run-vigil.ts | |
env: | |
PRIVATE_KEY: '0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80' | |
- name: hardhat test examples/onchain-signer | |
working-directory: examples/onchain-signer | |
run: pnpm run test --network sapphire-localnet | |
- name: ethersv5-ts-esm | |
working-directory: examples/ethersv5-ts-esm | |
run: pnpm run test | |
- name: ethersv6-ts-esm | |
working-directory: examples/ethersv6-ts-esm | |
run: pnpm run test |