Skip to content

Add fields in programJSon #90

Add fields in programJSon

Add fields in programJSon #90

Workflow file for this run

name: rust
on:
merge_group:
push:
branches: [ main ]
pull_request:
branches: [ '*' ]
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: ubuntu-20.04
steps:
- name: Install Rust 1.66.1
uses: actions-rs/toolchain@v1
with:
toolchain: 1.66.1
override: true
components: rustfmt, clippy
- name: Python3 Build
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Install Nextest
uses: taiki-e/install-action@nextest
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov
- name: Install wasm-bindgen-cli
uses: jetli/wasm-pack-action@v0.4.0
with:
version: "v0.10.3"
- name: Set up cargo cache
uses: Swatinem/rust-cache@v2
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install test dependencies
run: pip install -r requirements.txt
- name: Format
run: cargo fmt --all -- --check
- name: Build
run: make build
- name: Populate cache
uses: actions/cache@v3
id: cache-cairo-programs
with:
path: |
cairo_programs/*.json
cairo_programs/*.memory
cairo_programs/*.trace
!cairo_programs/*.rs.*
cairo_programs/*/*.json
cairo_programs/*/*.memory
cairo_programs/*/*.trace
!cairo_programs/*/*.rs.*
key: cairo-cache-${{ hashFiles( 'cairo_programs/*.cairo', 'cairo_programs/*/*.cairo' ) }}
restore-keys: cairo-cache-
- name: Restore timestamps
uses: chetan/git-restore-mtime-action@v1
- name: Install dependencies
run: pip install -r requirements.txt
- name: Run tests
run: make -j test
- name: Run tests no_std
run: make -j test-no_std
- name: Run wasm tests
run: make -j test-wasm
- name: Compare trace and memory
run: make -j compare_trace_memory
- name: Compare trace and memory with proof mode
run: make -j compare_trace_memory_proof
- name: Run clippy
run: make clippy
- name: Coverage
run: make coverage
- name: Upload coverage to codecov.io
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: lcov.info
fail_ci_if_error: true
# NB: the following step is needed so caching doesn't cause misleading coverage in later runs
- name: Clean coverage artifacts
run: make coverage-clean