TECH-292 - Add consent message #528
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 Build and Test (Local setup) | |
on: [push, pull_request] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
include: | |
- os: ubuntu-latest | |
file_suffix: "-linux" | |
steps: | |
- name: Check out repository code | |
uses: actions/checkout@v4 | |
- name: Set up environment | |
run: | | |
echo "Setting up on ${{ matrix.os }}" | |
mv ic-test-machine-binaries/ic-test-state-machine${{ matrix.file_suffix }} ic-test-state-machine | |
- name: Install dfx | |
uses: dfinity/setup-dfx@main | |
- name: Confirm successful installation | |
run: dfx --version | |
- name: Install Rust target | |
run: rustup target add wasm32-unknown-unknown | |
- name: Rust Cache | |
uses: Swatinem/rust-cache@v2.7.3 | |
- name: Install dependencies | |
run: | | |
npm install | |
cargo install ic-wasm | |
- name: Run the deploy script to deploy all the canisters to local environment | |
run: | | |
cargo build --target wasm32-unknown-unknown --release | |
- name: List contents of the directory | |
run: | | |
ls -R target/wasm32-unknown-unknown/release | |
- name: Update Cargo.toml | |
run: | | |
chmod +x ./scripts/build-ubuntu.sh | |
./scripts/build-ubuntu.sh | |
- name: Run tests | |
run: | | |
chmod +x ic-test-state-machine | |
cargo test -- --nocapture |