Skip to content

Commit

Permalink
Updated CI
Browse files Browse the repository at this point in the history
  • Loading branch information
KyrylR committed Dec 13, 2024
1 parent 50930db commit c910b94
Show file tree
Hide file tree
Showing 14 changed files with 53 additions and 1,553 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,7 @@ jobs:
uses: ./.github/actions/setup

- name: Run tests
run: npm run test
run: |
npm run prepare-circuits
./scripts/replace-circuits-files.sh
npm run test
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ artifacts
coverage.json
coverage

!zkit/artifacts

# Typechain generated files
generated-types

Expand Down
39 changes: 39 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
"compile": "npx hardhat compile --force",
"coverage": "npx hardhat coverage --solcoverjs ./.solcover.ts",
"clean": "npx hardhat clean",
"prepare-circuits": "npx hardhat zkit make",
"test": "npx hardhat test",
"prepare-circuits": "npx hardhat zkit make && ./scripts/replace-circuits-files.sh",
"test": "npm run prepare-circuits && npx hardhat test",
"test-all": "npx hardhat migrate && npm run test",
"private-network": "npx hardhat node",
"private-network-fork": "npx hardhat node --fork https://mainnet.infura.io/v3/$(grep INFURA_KEY .env | cut -d '\"' -f2)",
Expand Down Expand Up @@ -77,6 +77,7 @@
"circomlibjs": "^0.1.7",
"dotenv": "16.4.5",
"ethers": "^6.11.1",
"fs-extra": "^11.2.0",
"hardhat": "2.20.1",
"hardhat-contract-sizer": "^2.10.0",
"hardhat-gas-reporter": "^2.0.2",
Expand Down
7 changes: 7 additions & 0 deletions scripts/replace-circuits-files.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/usr/bin/env bash

cp -f assets/registerIdentityLight256.dev/registerIdentityLight256_js/generate_witness.js zkit/artifacts/circuits/RegisterIdentityLight256.circom/RegisterIdentityLight256_js/generate_witness.js
cp -f assets/registerIdentityLight256.dev/registerIdentityLight256_js/RegisterIdentityLight256.wasm zkit/artifacts/circuits/RegisterIdentityLight256.circom/RegisterIdentityLight256_js
cp -f assets/registerIdentityLight256.dev/registerIdentityLight256_js/witness_calculator.js zkit/artifacts/circuits/RegisterIdentityLight256.circom/RegisterIdentityLight256_js
cp -f assets/registerIdentityLight256.dev/RegisterIdentityLight256.groth16.vkey.json zkit/artifacts/circuits/RegisterIdentityLight256.circom
cp -f assets/registerIdentityLight256.dev/RegisterIdentityLight256.groth16.zkey zkit/artifacts/circuits/RegisterIdentityLight256.circom
2 changes: 0 additions & 2 deletions test/registration/RegistrationSimple.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import * as fs from "fs-extra";

import { zkit, ethers } from "hardhat";
import { HDNodeWallet } from "ethers";

Expand Down

This file was deleted.

Binary file not shown.
Binary file not shown.
Loading

0 comments on commit c910b94

Please sign in to comment.