Skip to content

Commit ea4c86d

Browse files
committed
fix: reorder unit test execution in CI workflow and update README for build instructions
1 parent 9b7d648 commit ea4c86d

File tree

3 files changed

+12
-7
lines changed

3 files changed

+12
-7
lines changed

.github/workflows/main.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ jobs:
1616
uses: actions/checkout@v4
1717
- name: Init
1818
run: npm ci
19-
- name: Run unit tests
20-
run: npm run test
2119
- name: Test build
2220
run: npm run build
21+
- name: Run unit tests
22+
run: npm run test
2323
# See Jenkinsfile-itest for "Run integration tests" step

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,12 @@ generate code
3636
npm run codegen
3737
```
3838

39+
build the project and generate the necessary files:
40+
41+
```sh
42+
npm run build
43+
```
44+
3945
deploy the subgraph on local node
4046

4147
```sh

package.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,14 @@
77
"scripts": {
88
"prepare": "husky",
99
"generate:typechain": "typechain --target ethers-v6 --out-dir generated/typechain './node_modules/@iexec/poco/build/contracts/*.json' --ts-nocheck",
10-
"codegen": "graph codegen",
11-
"test": "npm run codegen && graph test",
12-
"coverage": "npm run codegen && graph test -- -c",
13-
"build": "rm -rf generated && rm -rf build && npm run codegen && graph build --network ${NETWORK_NAME:-bellecour}",
10+
"build": "rm -rf generated && rm -rf build && npm run generate:typechain && graph codegen && graph build --network ${NETWORK_NAME:-bellecour}",
11+
"test": "graph test",
12+
"coverage": "graph test -- -c",
1413
"create": "graph create ${NETWORK_NAME:-bellecour}/poco --node ${GRAPHNODE_URL:-http://localhost:8020}",
1514
"deploy": "graph deploy ${NETWORK_NAME:-bellecour}/poco --node ${GRAPHNODE_URL:-http://localhost:8020} --ipfs ${IPFS_URL:-http://localhost:5001} --version-label ${VERSION_LABEL:-bellecour/poco-v5}",
1615
"all": "npm run build && npm run create && npm run deploy",
1716
"stop-test-stack": "cd test-stack && docker compose down --remove-orphans --volumes",
18-
"start-test-stack": "npm run generate:typechain & npm run stop-test-stack && cd test-stack && export NETWORK_NAME=${NETWORK_NAME:-bellecour} && node prepare-test-env.js && docker compose build && docker compose up -d",
17+
"start-test-stack": "npm run stop-test-stack && cd test-stack && export NETWORK_NAME=${NETWORK_NAME:-bellecour} && node prepare-test-env.js && docker compose build && docker compose up -d",
1918
"itest": "NETWORK_NAME=${NETWORK_NAME:-bellecour} mocha"
2019
},
2120
"lint-staged": {

0 commit comments

Comments
 (0)