Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 21 additions & 1 deletion .github/workflows/pull-request-develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,30 @@ jobs:
- name: "Check formatting"
run: npx prettier ./packages --check

# type-checks all test folders (fast fail on compile errors)
test-check:
runs-on: ubuntu-latest
needs: install
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 22.9.0
cache: npm

- name: "Install dependencies"
run: npm ci --workspaces --include-workspace-root

- name: "Build"
run: npm run build

- name: "Type-check tests"
run: npm run test:check

# tests all packages
test:
runs-on: ubuntu-latest
needs: install
needs: test-check
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
Expand Down
1 change: 1 addition & 0 deletions nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
"prisma:generate",
"lint",
"test",
"test:check",
"integration"
]
}
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"lint:staged": "eslint",
"format": "prettier --check \"packages/*/src/**/*.ts\" \"packages/*/test/**/*.ts\" \"packages/*/*.{cjs,json}\"",
"format:write": "prettier --write \"packages/*/src/**/*.ts\" \"packages/*/test/**/*.ts\" \"packages/*/*.{cjs,json}\"",
"test:check": "npx lerna run test:check",
"test": "npx lerna run test -- --passWithNoTests",
"test:ci": "npx lerna run test --concurrency=1 -- --passWithNoTests --forceExit",
"test:integration": "npx lerna run test:integration --concurrency=1 -- --passWithNoTests --forceExit",
Expand Down
1 change: 1 addition & 0 deletions packages/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"lint": "eslint ./src ./test",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json",
"test:watch": "npm run test:file -- ./test/** --watch"
},
"main": "dist/index.js",
Expand Down
1 change: 1 addition & 0 deletions packages/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"lint": "eslint ./src ./test",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json",
"test:watch": "npm run test:file -- ./test/** --watch"
},
"main": "dist/index.js",
Expand Down
1 change: 1 addition & 0 deletions packages/deployment/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:watch": "npm run test:file -- ./test/** --watch",
"test:check": "tsc --noEmit -p test/tsconfig.json && tsc --noEmit -p test-integration/tsconfig.json",
"test:integration": "npm run test:file -- ./test-integration/** --runInBand"
},
"main": "dist/index.js",
Expand Down
1 change: 1 addition & 0 deletions packages/indexer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"lint": "eslint ./src ./test",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./src/** ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json",
"test:watch": "npm run test:file -- ./src/** ./test/** --watch",
"prisma:generate": "prisma generate --schema=./prisma/schema.prisma",
"prisma:migrate": "prisma migrate dev --schema=./prisma/schema.prisma"
Expand Down
1 change: 1 addition & 0 deletions packages/library/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"lint": "eslint ./src ./test",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json",
"test:watch": "npm run test:file -- ./test/** --watch"
},
"main": "dist/index.js",
Expand Down
1 change: 1 addition & 0 deletions packages/module/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"lint": "eslint ./src ./test",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json",
"test:watch": "npm run test:file -- ./test/** --watch"
},
"main": "dist/index.js",
Expand Down
1 change: 1 addition & 0 deletions packages/persistance/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"lint": "eslint ./src ./test ./test-integration",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json && tsc --noEmit -p test-integration/tsconfig.json",
"test:integration": "npm run test:file -- ./test-integration/** --runInBand",
"test:watch": "npm run test:file -- ./test/** --watch"
},
Expand Down
1 change: 1 addition & 0 deletions packages/processor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"prisma:generate": "prisma generate --schema=./test/prisma/schema.prisma",
"test": "npm run test:file -- ./src/** ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json",
"test:watch": "npm run test:file -- ./src/** ./test/** --watch"
},
"publishConfig": {
Expand Down
1 change: 1 addition & 0 deletions packages/protocol/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"lint": "eslint ./src ./test",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json",
"test:watch": "npm run test:file -- ./test/** --watch"
},
"main": "dist/index.js",
Expand Down
28 changes: 0 additions & 28 deletions packages/protocol/test/compiling/types.ts

This file was deleted.

4 changes: 2 additions & 2 deletions packages/protocol/test/modularity/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ import { TypedClass } from "@proto-kit/common";
import { GetContracts } from "../../src/settlement/modularity/types";
import {
BridgeContractType,
MandatorySettlementModulesRecord,
BridgingSettlementModulesRecord,
SettlementContractType,
} from "../../src";
/* eslint-disable @typescript-eslint/no-unused-vars */

// Goal of this "test" is that it compiles. By compiling this file checks that
// certain types are inferred correctly

type Inferred = GetContracts<MandatorySettlementModulesRecord>;
type Inferred = GetContracts<BridgingSettlementModulesRecord>;

// Get inferred Bridge Type
type Bridge = Inferred["BridgeContract"];
Expand Down
1 change: 1 addition & 0 deletions packages/sdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"lint": "eslint ./src ./test",
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:check": "tsc --noEmit -p test/tsconfig.json",
"test:watch": "npm run test:file -- ./test/** --watch"
},
"main": "dist/index.js",
Expand Down
1 change: 1 addition & 0 deletions packages/sequencer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"test:file": "node --experimental-vm-modules --experimental-wasm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:watch": "npm run test:file -- ./test/** --watch",
"test:check": "tsc --noEmit -p test/tsconfig.json && tsc --noEmit -p test-integration/tsconfig.json && tsc --noEmit -p test-proven/tsconfig.json",
"test:integration": "npm run test:file -- ./test-integration/** --runInBand",
"start": "npm run build && node --experimental-vm-modules --experimental-wasm-modules --es-module-specifier-resolution=node ./dist/src/entry.js"
},
Expand Down
1 change: 1 addition & 0 deletions packages/stack/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"test:file": "node --experimental-vm-modules ../../node_modules/jest/bin/jest.js",
"test": "npm run test:file -- ./test/**",
"test:watch": "npm run test:file -- ./test/** --watch",
"test:check": "tsc --noEmit -p test/tsconfig.json && tsc --noEmit -p test-integration/tsconfig.json",
"test:integration": "npm run test:file -- ./test-integration/** --runInBand",
"graphql": "npm run build && node --experimental-vm-modules --experimental-wasm-modules --es-module-specifier-resolution=node ./dist/scripts/graphql/run-graphql.js",
"start": "node --experimental-vm-modules --es-module-specifier-resolution=node ./dist/start.js"
Expand Down
Loading