Bump solana-validator from 1.7.0 to 1.18.23 in /program #187
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: CI | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
env: | |
CARGO_TERM_COLOR: always | |
SOLANA_VERSION: "1.6.12" | |
RUST_TOOLCHAIN: stable | |
defaults: | |
run: | |
working-directory: ./program | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Rust nightly | |
uses: actions-rs/toolchain@v1 | |
with: | |
override: true | |
profile: minimal | |
toolchain: ${{ env.RUST_TOOLCHAIN }} | |
components: rustfmt, clippy | |
- name: Cache dependencies | |
uses: Swatinem/rust-cache@v1 | |
- name: Run fmt | |
run: cargo fmt -- --check | |
- name: Run clippy | |
run: cargo clippy -- --deny=warnings | |
unit-tests: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Linux dependencies | |
run: sudo apt-get install -y pkg-config build-essential libudev-dev | |
- name: Install Rust nightly | |
uses: actions-rs/toolchain@v1 | |
with: | |
override: true | |
profile: minimal | |
toolchain: ${{ env.RUST_TOOLCHAIN }} | |
- name: Cache dependencies | |
uses: Swatinem/rust-cache@v1 | |
- name: Run unit tests | |
run: cargo test --lib | |
integration-tests: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Cache dependencies | |
uses: Swatinem/rust-cache@v1 | |
- name: Install Linux dependencies | |
run: sudo apt-get install -y pkg-config build-essential libudev-dev | |
# Install Solana | |
- name: Cache Solana binaries | |
uses: actions/cache@v2 | |
with: | |
path: ~/.cache/solana | |
key: ${{ runner.os }}-${{ env.SOLANA_VERSION }} | |
- name: Install Solana | |
run: | | |
sh -c "$(curl -sSfL https://release.solana.com/v${{ env.SOLANA_VERSION }}/install)" | |
echo "$HOME/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH | |
export PATH="/home/runner/.local/share/solana/install/active_release/bin:$PATH" | |
solana --version | |
echo "Generating keypair..." | |
solana-keygen new -o "$HOME/.config/solana/id.json" --no-passphrase --silent | |
# Run tests | |
- name: Build program | |
run: cargo build-bpf | |
- name: Run tests | |
run: cargo test-bpf |