Fix/claimable LM Rewards #9
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: Lb Clmm SDK | |
on: | |
pull_request: | |
branches: | |
- main | |
env: | |
SOLANA_CLI_VERSION: 1.16.1 | |
NODE_VERSION: 18.14.2 | |
ANCHOR_CLI_VERSION: 0.28.0 | |
jobs: | |
sdk_changed_files: | |
runs-on: ubuntu-latest | |
outputs: | |
sdk: ${{steps.changed-files-specific.outputs.any_changed}} | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Get specific changed files | |
id: changed-files-specific | |
uses: tj-actions/[email protected] | |
with: | |
files: | | |
ts-client | |
sdk_test: | |
runs-on: ubuntu-latest | |
needs: sdk_changed_files | |
if: needs.sdk_changed_files.outputs.sdk == 'true' | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: ./.github/actions/setup-solana | |
- uses: ./.github/actions/setup-dep | |
- uses: ./.github/actions/setup-anchor | |
# Install rust + toolchain | |
- uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
components: clippy | |
# Cache node_modules | |
- uses: actions/cache@v2 | |
id: cache-node-modules | |
with: | |
path: ./ts-client/node_modules | |
key: ${{ runner.os }}-${{ hashFiles('./package-lock.json') }} | |
- run: anchor build -- --features localnet | |
shell: bash | |
- run: anchor localnet -- --features localnet & sleep 2 | |
shell: bash | |
- run: cd ts-client && npm install && npm run test | |
shell: bash |