Skip to content

Commit

Permalink
Merge pull request #17 from 0xPolygonHermez/edu/add_riscof_tests
Browse files Browse the repository at this point in the history
add Risc Oficial Tests Check gha
  • Loading branch information
fractasy authored Jul 25, 2024
2 parents 4e65a98 + 6157b86 commit c85ead6
Show file tree
Hide file tree
Showing 2 changed files with 58 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ runs:
uses: Dup4/actions-setup-gcc@v1
with:
version: latest
cc: false

- name: rust-cache
uses: actions/cache@v3
Expand Down
57 changes: 57 additions & 0 deletions .github/workflows/pr_emulator.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Risc Oficial Tests Check

on:
push:
branches: [develop]
paths:
- 'emulator/**'
- 'riscv/**'
pull_request:
branches:
- '**'
paths:
- 'emulator/**'
- 'riscv/**'

jobs:
docker-ziskof-check:
name: Docker Risc Oficial Tests Check
runs-on: self-hosted
env:
CARGO_NET_GIT_FETCH_WITH_CLI: "true"
steps:
- name: Checkout sources
uses: actions/checkout@v4

- uses: actions/checkout@v2
- name: Install nightly
uses: actions-rs/toolchain@v1
with:
toolchain: nightly-2024-07-21
override: true
components: rustfmt, clippy

- name: Run cargo check
uses: actions-rs/cargo@v1
with:
command: check

- name: Build project
uses: actions-rs/cargo@v1
with:
command: build
toolchain: nightly-2024-07-21
args: --release --all-features
env:
RUSTFLAGS: -Copt-level=3 -Cdebug-assertions -Coverflow-checks=y -Cdebuginfo=0 -C target-cpu=native
RUST_BACKTRACE: 1

- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Run Docker container
run: |
docker run --rm -v ./target/release/ziskemu:/program hermeznetwork/ziskof:latest

0 comments on commit c85ead6

Please sign in to comment.