Skip to content

ci: Cleaner Verilator install (#79) #191

ci: Cleaner Verilator install (#79)

ci: Cleaner Verilator install (#79) #191

Workflow file for this run

name: CI
on:
pull_request:
push:
branches:
- main
env:
CARGO_TERM_COLOR: always
CARGO_INCREMENTAL: 1 # since we cache
COLOG: 1
jobs:
test_verilog:
strategy:
matrix:
os: [ubuntu-latest, macos-15]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: Swatinem/rust-cache@v2
- name: Install Verilator
run: |
if [[ "$(uname)" == 'Darwin' ]]; then
brew install verilator
else
sudo apt-get install -y verilator
fi
- name: Manual test
run: |
cd examples/verilog-project
cargo run --package example-verilog-project --bin tutorial
cargo run --package example-verilog-project --bin tutorial # rerun
cargo test --package example-verilog-project --test dynamic_model_tutorial -- --exact main
cargo test --package example-verilog-project --test dpi_tutorial -- --exact main
cargo test --package example-verilog-project --test visibility_works -- --exact main
- name: Cargo test
run: cargo test --package example-verilog-project
test_spade:
strategy:
matrix:
os: [ubuntu-latest, macos-15]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Rust Caching
uses: Swatinem/rust-cache@v2
- name: Install Verilator
run: |
if [[ "$(uname)" == 'Darwin' ]]; then
brew install verilator
else
sudo apt-get install -y verilator
fi
- name: Install swim
run: cargo install --locked --git https://gitlab.com/spade-lang/swim --rev 639c5d88db76ef3454af4feef842c37985ca1943
- name: Test
run: cargo test --package example-spade-project