evm: updates wormhole-solidity-sdk to latest main
commit
#37
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: Run tests | |
on: | |
workflow_dispatch: | |
pull_request: | |
push: | |
branches: | |
- main | |
permissions: | |
contents: read | |
packages: read | |
jobs: | |
pre-commit: | |
name: Run Solana SDK tests | |
runs-on: ubuntu-latest | |
env: | |
NODE_OPTIONS: "--max-old-space-size=2500" | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: "20.17.0" | |
registry-url: "https://npm.pkg.github.com" | |
cache: "yarn" | |
cache-dependency-path: | | |
./yarn.lock | |
- name: Checkout relayer-infra-contracts | |
uses: actions/checkout@v3 | |
with: | |
repository: xlabs/relayer-infra-contracts | |
path: lib/relayer-infra-contracts | |
ssh-key: '${{ secrets.RELAYER_INFRA_CONTRACTS }}' | |
# Taken from https://github.com/metaDAOproject/setup-anchor/blob/main/action.yml#L25-L40 | |
- name: Cache Solana CLI tools | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cache/solana/ | |
~/.local/share/solana/ | |
key: solana-cli-${{ runner.os }}-build-1.28.23 | |
- name: Install Solana CLI tools | |
run: sh -c "$(curl -sSfL https://release.anza.xyz/v1.18.23/install)" | |
shell: bash | |
- name: Update PATH | |
run: echo "$HOME/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH | |
shell: bash | |
- name: Install Anchor | |
run: npm i -g @coral-xyz/[email protected] | |
shell: bash | |
- name: Create keypair | |
run: solana-keygen new --no-bip39-passphrase | |
shell: bash | |
- name: Setup private package access | |
run: | | |
yarn config set npmScopes.xlabs.npmAlwaysAuth true | |
yarn config set npmScopes.xlabs.npmAuthToken ${{ secrets.GITHUB_TOKEN }} | |
- name: Install dependencies | |
run: yarn install --immutable --immutable-cache | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build Solana programs | |
run: anchor build | |
working-directory: ./solana | |
shell: bash | |
- name: Run Solana SDK tests | |
run: | | |
yarn ./sdk/common build:ts && yarn ./sdk/solana build:ts && yarn ./solana build:ts | |
anchor run setup-test | |
anchor test | |
shell: bash |