-
Notifications
You must be signed in to change notification settings - Fork 1
47 lines (38 loc) · 1.04 KB
/
CI.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: Nexus Test Cases
on:
pull_request:
types: [opened,edited]
branches: [develop,main]
jobs:
Test-Contracts:
runs-on: ubuntu-latest
environment: Testing
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 20
- name: Install dependencies
run: |
npm ci
- name: Setup Environment
run: |
npx hardhat compile
- name: Run Test
run: |
npx hardhat test test/registration.ts
- name: Copy ABI
run: |
mkdir -p contract_abi
cp artifacts/contracts/Nexus.sol/Nexus.json abis/Nexus.json
cp artifacts/contracts/NexusBridge.sol/NexusBridge.json abis/NexusBridge.json
- name: Commit
uses: EndBug/add-and-commit@v9
with:
default_author: RohitAudit
message: 'CI: Generated ABIs'
add: 'contract_abi/*'