Skip to content

Commit 75808ff

Browse files
authored
chore: test agains Fleets and add optional tests (#1432)
* test Prod and Test fleets in CI * compute predefined nodes once * remove async * add optional test step * fix command
1 parent af5d613 commit 75808ff

File tree

7 files changed

+137
-111
lines changed

7 files changed

+137
-111
lines changed

.github/workflows/ci.yml

+17
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,23 @@ jobs:
8585
name: nwaku-logs
8686
path: packages/tests/log/
8787

88+
node_optional:
89+
runs-on: ubuntu-latest
90+
env:
91+
WAKUNODE_IMAGE: "statusteam/nim-waku:v0.18.0"
92+
steps:
93+
- uses: actions/checkout@v3
94+
95+
- uses: actions/setup-node@v3
96+
with:
97+
node-version: ${{ env.NODE_JS }}
98+
99+
- uses: ./.github/actions/npm
100+
- run: npm run build:esm
101+
- run: npm run test:optional --workspace=@waku/tests
102+
env:
103+
DEBUG: ""
104+
88105
node_with_go_waku_master:
89106
runs-on: ubuntu-latest
90107
env:

package-lock.json

+60-60
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/tests/.mocharc.json

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
{
22
"extension": ["ts"],
3-
"spec": "tests/*.spec.ts",
43
"require": ["ts-node/register", "isomorphic-fetch"],
54
"loader": "ts-node/esm",
65
"node-option": [

packages/tests/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@
4141
"check:lint": "eslint src tests",
4242
"check:spelling": "cspell \"{README.md,{tests,src}/**/*.ts}\"",
4343
"check:tsc": "tsc -p tsconfig.dev.json",
44-
"test": "run-s test:*",
45-
"test:node": "node ./src/run-tests.js",
44+
"test": "node ./src/run-tests.js \"tests/**/!(*.optional).spec.ts\"",
45+
"test:optional": "node ./src/run-tests.js \"tests/**/@(*.optional).spec.ts\"",
4646
"reset-hard": "git clean -dfx -e .idea && git reset --hard && npm i && npm run build"
4747
},
4848
"engines": {

packages/tests/src/run-tests.js

+1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ async function main() {
2525
"ts-node/register",
2626
"--project",
2727
"./tsconfig.dev.json",
28+
...process.argv.slice(2),
2829
],
2930
{
3031
stdio: "inherit",

0 commit comments

Comments
 (0)