Skip to content

Commit c762455

Browse files
authored
refactor(core): Set up @n8n/integration-test-utils package (#15098)
1 parent 2bb1903 commit c762455

File tree

10 files changed

+77
-0
lines changed

10 files changed

+77
-0
lines changed

codecov.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ component_management:
4040
- packages/@n8n/decorators/**
4141
- packages/@n8n/constants/**
4242
- packages/@n8n/backend-common/**
43+
- packages/@n8n/integration-test-utils/**
4344
- packages/@n8n/db/**
4445
- packages/@n8n/di/**
4546
- packages/@n8n/imap/**
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
const sharedOptions = require('@n8n/eslint-config/shared');
2+
3+
/** @type {import('@types/eslint').ESLint.ConfigData} */
4+
module.exports = {
5+
extends: ['@n8n/eslint-config/base'],
6+
...sharedOptions(__dirname),
7+
};
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
{
2+
"name": "@n8n/integration-test-utils",
3+
"version": "0.1.0",
4+
"scripts": {
5+
"clean": "rimraf dist .turbo",
6+
"dev": "pnpm watch",
7+
"typecheck": "tsc --noEmit",
8+
"build": "tsc -p tsconfig.build.json",
9+
"format": "biome format --write .",
10+
"format:check": "biome ci .",
11+
"lint": "eslint .",
12+
"lintfix": "eslint . --fix",
13+
"watch": "tsc -p tsconfig.build.json --watch",
14+
"test": "jest",
15+
"test:dev": "jest --watch"
16+
},
17+
"main": "dist/index.js",
18+
"module": "src/index.ts",
19+
"types": "dist/index.d.ts",
20+
"files": [
21+
"dist/**/*"
22+
],
23+
"dependencies": {
24+
"reflect-metadata": "catalog:"
25+
},
26+
"devDependencies": {
27+
"@n8n/typescript-config": "workspace:*"
28+
}
29+
}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export {};
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.json"],
3+
"compilerOptions": {
4+
"composite": true,
5+
"rootDir": "src",
6+
"outDir": "dist",
7+
"tsBuildInfoFile": "dist/build.tsbuildinfo"
8+
},
9+
"include": ["src/**/*.ts"],
10+
"exclude": ["src/**/__tests__/**"]
11+
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"extends": "@n8n/typescript-config/tsconfig.common.json",
3+
"compilerOptions": {
4+
"rootDir": ".",
5+
"types": ["node", "jest"],
6+
"baseUrl": "src",
7+
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
8+
"experimentalDecorators": true,
9+
"emitDecoratorMetadata": true
10+
},
11+
"include": ["src/**/*.ts"]
12+
}

packages/cli/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,7 @@
9595
"@n8n/config": "workspace:*",
9696
"@n8n/constants": "workspace:^",
9797
"@n8n/backend-common": "workspace:^",
98+
"@n8n/integration-test-utils": "workspace:^",
9899
"@n8n/db": "workspace:^",
99100
"@n8n/decorators": "workspace:*",
100101
"@n8n/di": "workspace:*",

packages/cli/tsconfig.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
{ "path": "../@n8n/decorators/tsconfig.build.json" },
3131
{ "path": "../@n8n/db/tsconfig.build.json" },
3232
{ "path": "../@n8n/backend-common/tsconfig.build.json" },
33+
{ "path": "../@n8n/integration-test-utils/tsconfig.build.json" },
3334
{ "path": "../@n8n/di/tsconfig.build.json" },
3435
{ "path": "../@n8n/nodes-langchain/tsconfig.build.json" },
3536
{ "path": "../@n8n/permissions/tsconfig.build.json" }

pnpm-lock.yaml

Lines changed: 13 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

turbo.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
"@n8n/decorators#lint",
3232
"@n8n/constants#lint",
3333
"@n8n/backend-common#lint",
34+
"@n8n/integration-test-utils#lint",
3435
"@n8n/db#lint",
3536
"@n8n/di#lint",
3637
"@n8n/client-oauth2#lint",

0 commit comments

Comments
 (0)