clients/js: Add typedoc deployment #195
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: | |
hardhat-test: | |
runs-on: ubuntu-latest | |
services: | |
sapphire-dev-ci: | |
image: ghcr.io/oasisprotocol/sapphire-dev: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: attempt to connect to sapphire-dev-ci | |
run: curl -kv http://sapphire-dev-ci:8545/ || true | |
- name: attempt to connect to sapphire-dev-ci via localhost | |
run: curl -kv http://127.0.0.1:8545/ || true | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
- uses: pnpm/[email protected] | |
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@v3 | |
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 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: hardhat test contracts | |
working-directory: contracts | |
run: pnpm hardhat test --network sapphire-dev-ci | |
- name: hardhat test examples/truffle | |
working-directory: examples/truffle | |
run: pnpm run test --network sapphire_localnet | |
env: | |
PRIVATE_KEY: '0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80' | |
- name: hardhat test examples/onchain-signer | |
working-directory: examples/onchain-signer | |
run: pnpm run test --network sapphire-localnet |