-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
61 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
name: Verify Proofs (Reusable) | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
artifact-name: | ||
type: string | ||
description: 'Name of the artifact to extract' | ||
required: true | ||
test-names: | ||
type: string | ||
description: 'Names of the tests to run (one per line)' | ||
required: true | ||
evm-placeholder-verification-ref: | ||
type: string | ||
description: "Reference to evm-placeholder-verification repository to checkout at" | ||
required: true | ||
refs: | ||
type: string | ||
description: "Lines with repo names and refs (e.g. `org/repo: ref`)" | ||
required: false | ||
|
||
jobs: | ||
run-tests: | ||
runs-on: [ ubuntu-22.04 ] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
repository: 'NilFoundation/evm-placeholder-verification' | ||
ref: ${{ inputs.evm-placeholder-verification-ref }} | ||
|
||
- name: Checkout modules to specified refs | ||
if: inputs.refs != '' | ||
uses: NilFoundation/ci-cd/actions/[email protected] | ||
with: | ||
paths: ${{ github.workspace }}/** | ||
refs: ${{ inputs.refs }} | ||
|
||
- name: Setup Node.js environment | ||
uses: actions/[email protected] | ||
|
||
- name: Install node dependencies | ||
run: | | ||
npm install | ||
- name: Download artifact | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: ${{ inputs.artifact-name }} | ||
path: ./contracts/zkllvm | ||
|
||
- name: Hardhat deploy | ||
run: | | ||
npx hardhat deploy | ||
- name: Verification of zkllvm proofs | ||
run: | | ||
echo "${{ inputs.test-names }}" | awk '{$1=$1};1' | sed '/^$/d' | while read test_name | ||
do | ||
npx hardhat verify-circuit-proof --test "$test_name" | ||
done |