Skip to content

Commit 8deb845

Browse files
authored
Run integration tests sequentially when generating READMEs (#4157)
* Run integration tests sequentially when generating READMEs * changeset
1 parent 8d4db8a commit 8deb845

File tree

3 files changed

+43
-8
lines changed

3 files changed

+43
-8
lines changed

.changeset/heavy-chairs-dance.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@chainlink/enzyme-adapter': patch
3+
'@chainlink/ea-scripts': patch
4+
---
5+
6+
Fix README generation

packages/scripts/src/generate-readme/generator.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ export class ReadmeGenerator {
407407
if (this.verbose)
408408
console.log(`${this.adapterPath}: Running integration tests to get updated I/O examples`)
409409

410-
const testOutput = exec(`yarn test ${this.integrationTestPath}`, {
410+
const testOutput = exec(`yarn test --runInBand ${this.integrationTestPath}`, {
411411
fatal: true,
412412
silent: true,
413413
env: { ...process.env, ...testEnvOverrides },

packages/sources/enzyme/README.md

Lines changed: 36 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,36 @@ Endpoint to call the `calcGav` function on the contract.
4444

4545
### Example
4646

47-
There are no examples for this endpoint.
47+
Request:
48+
49+
```json
50+
{
51+
"id": "1",
52+
"data": {
53+
"calculatorContract": "0x0b2cBB1974f17700531439E3e4AfF5e5D2AADD4A",
54+
"vaultProxy": "0x44902e5a88371224d9ac172e391C64257B701Ade",
55+
"endpoint": "calcGav"
56+
},
57+
"debug": {
58+
"cacheKey": "yUw9SO6VrH2QFaTp1fXS40T8Kzg="
59+
}
60+
}
61+
```
62+
63+
Response:
64+
65+
```json
66+
{
67+
"jobRunID": "1",
68+
"data": {
69+
"gav": "19995161270996618818245984471",
70+
"result": "19995161270996618818245984471"
71+
},
72+
"result": "19995161270996618818245984471",
73+
"statusCode": 200,
74+
"providerStatusCode": 200
75+
}
76+
```
4877

4978
---
5079

@@ -135,10 +164,10 @@ Response:
135164
{
136165
"jobRunID": "1",
137166
"data": {
138-
"gav": "19995161270996618818245984471",
139-
"result": "19995161270996618818245984471"
167+
"netValue": "10000000000000000000",
168+
"result": "10000000000000000000"
140169
},
141-
"result": "19995161270996618818245984471",
170+
"result": "10000000000000000000",
142171
"statusCode": 200,
143172
"providerStatusCode": 200
144173
}
@@ -185,10 +214,10 @@ Response:
185214
{
186215
"jobRunID": "1",
187216
"data": {
188-
"netValue": "10000000000000000000",
189-
"result": "10000000000000000000"
217+
"netShareValue": "1000000000000000000",
218+
"result": "1000000000000000000"
190219
},
191-
"result": "10000000000000000000",
220+
"result": "1000000000000000000",
192221
"statusCode": 200,
193222
"providerStatusCode": 200
194223
}

0 commit comments

Comments
 (0)