bump solana crates to 2.1 (#109) #243
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
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
name: CI | |
jobs: | |
test: | |
name: Test Suite | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v4 | |
- name: Cache cargo | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cargo/registry | |
~/.cargo/bin | |
~/.cargo/git | |
target | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
- name: Install Solana CLI | |
run: | | |
sh -c "$(curl -sSfL https://release.solana.com/v1.18.8/install)" | |
echo "/home/runner/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH | |
- name: Install protobuf compiler # delete this once we get to solana 2.1 | |
run: sudo apt-get install protobuf-compiler | |
- name: Build test programs | |
run: cd crates/litesvm/test_programs && cargo build-sbf | |
- name: Run tests | |
run: cargo test | |
env: | |
RUST_BACKTRACE: 1 | |
- name: Run SPL tests | |
run: cargo test --features token-2022 | |
env: | |
RUST_BACKTRACE: 1 | |
lints: | |
name: Lints | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v4 | |
- name: Install protobuf compiler # delete this once we get to solana 2.1 | |
run: sudo apt-get install protobuf-compiler | |
- name: Cache cargo | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cargo/registry | |
~/.cargo/bin | |
~/.cargo/git | |
target | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
- name: Run cargo fmt | |
run: cargo fmt --all -- --check | |
- name: Run cargo clippy | |
run: cargo clippy --all-targets -- -D warnings |