Skip to content

Commit 38a0c23

Browse files
committed
chore(federation-matrix): Review build configuration
1 parent cb7c338 commit 38a0c23

File tree

7 files changed

+13
-84
lines changed

7 files changed

+13
-84
lines changed

ee/packages/federation-matrix/babel.config.js

Lines changed: 0 additions & 3 deletions
This file was deleted.

ee/packages/federation-matrix/jest.config.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,7 @@ import type { Config } from 'jest';
33

44
export default {
55
preset: server.preset,
6-
transformIgnorePatterns: [
7-
'<rootDir>/node_modules/@babel',
8-
'<rootDir>/node_modules/@jest',
9-
'/node_modules/(?!marked|@testing-library/)',
10-
],
6+
transformIgnorePatterns: ['<rootDir>/node_modules/@babel', '<rootDir>/node_modules/@jest', '/node_modules/(?!marked|@testing-library/)'],
117
// Exclude integration/e2e tests from unit test runs
128
testPathIgnorePatterns: ['<rootDir>/tests/end-to-end/'],
139
} satisfies Config;

ee/packages/federation-matrix/package.json

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@
99
],
1010
"scripts": {
1111
"build": "rm -rf dist && tsc -p tsconfig.build.json",
12-
"dev": "tsc -p tsconfig.json --watch --preserveWatchOutput",
13-
"lint": "eslint src",
14-
"lint:fix": "eslint src --fix",
12+
"dev": "tsc -p tsconfig.build.json --watch --preserveWatchOutput",
13+
"lint": "eslint .",
14+
"lint:fix": "eslint --fix .",
1515
"test": "jest",
1616
"test:integration": "./tests/scripts/run-integration-tests.sh",
1717
"test:federation": "jest --config jest.config.federation.ts",
1818
"testunit": "jest",
19-
"typecheck": "tsc --noEmit --skipLibCheck"
19+
"typecheck": "tsc --noEmit"
2020
},
2121
"dependencies": {
2222
"@rocket.chat/core-services": "workspace:^",
@@ -38,16 +38,11 @@
3838
"tweetnacl": "^1.0.3"
3939
},
4040
"devDependencies": {
41-
"@babel/cli": "~7.28.3",
42-
"@babel/core": "~7.28.5",
43-
"@babel/preset-env": "~7.28.5",
44-
"@babel/preset-typescript": "~7.27.1",
4541
"@rocket.chat/ddp-client": "workspace:^",
4642
"@rocket.chat/eslint-config": "workspace:^",
4743
"@types/emojione": "^2.2.9",
4844
"@types/node": "~22.16.5",
4945
"@types/sanitize-html": "~2.16.0",
50-
"babel-jest": "~30.2.0",
5146
"eslint": "~8.45.0",
5247
"jest": "~30.2.0",
5348
"jest-qase-reporter": "^2.1.4",

ee/packages/federation-matrix/tests/end-to-end/room.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1605,7 +1605,7 @@ import { SynapseClient } from '../helper/synapse-client';
16051605
expect(pendingInvitation).not.toBeUndefined();
16061606

16071607
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
1608-
rid = pendingInvitation?.rid!;
1608+
rid = pendingInvitation!.rid!;
16091609

16101610
await acceptRoomInvite(rid, rc1AdminRequestConfig);
16111611
}, 15000);
@@ -1644,7 +1644,7 @@ import { SynapseClient } from '../helper/synapse-client';
16441644
expect(pendingInvitation).not.toBeUndefined();
16451645

16461646
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
1647-
rid = pendingInvitation?.rid!;
1647+
rid = pendingInvitation!.rid!;
16481648
}, 15000);
16491649

16501650
it('should allow RC user to reject the invite and remove the subscription', async () => {
@@ -1678,7 +1678,7 @@ import { SynapseClient } from '../helper/synapse-client';
16781678
expect(pendingInvitation).not.toBeUndefined();
16791679

16801680
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
1681-
rid = pendingInvitation?.rid!;
1681+
rid = pendingInvitation!.rid!;
16821682

16831683
// hs1 revokes the invitation by kicking the invited user
16841684
await hs1AdminApp.matrixClient.kick(matrixRoomId, federationConfig.rc1.adminMatrixUserId, 'Invitation revoked');
Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
11
{
22
"extends": "./tsconfig.json",
33
"compilerOptions": {
4-
"noEmit": false,
5-
"skipLibCheck": true,
4+
"outDir": "./dist",
65
"isolatedModules": true,
7-
"allowJs": false,
8-
"checkJs": false,
9-
"esModuleInterop": true
6+
"declaration": true,
107
},
118
"include": [
129
"src/**/*.ts"
@@ -18,4 +15,4 @@
1815
"**/*.test.ts",
1916
"../../../../**/*",
2017
]
21-
}
18+
}
Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
11
{
22
"extends": "@rocket.chat/tsconfig/server.json",
33
"compilerOptions": {
4+
"rootDir": "./src",
45
"strictPropertyInitialization": false,
5-
"skipLibCheck": true,
66
"experimentalDecorators": true,
7-
"declaration": true,
8-
"rootDir": "./src",
9-
"outDir": "./dist"
107
},
118
"files": ["./src/index.ts"]
129
}

yarn.lock

Lines changed: 1 addition & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -587,33 +587,6 @@ __metadata:
587587
languageName: node
588588
linkType: hard
589589

590-
"@babel/cli@npm:~7.28.3":
591-
version: 7.28.3
592-
resolution: "@babel/cli@npm:7.28.3"
593-
dependencies:
594-
"@jridgewell/trace-mapping": "npm:^0.3.28"
595-
"@nicolo-ribaudo/chokidar-2": "npm:2.1.8-no-fsevents.3"
596-
chokidar: "npm:^3.6.0"
597-
commander: "npm:^6.2.0"
598-
convert-source-map: "npm:^2.0.0"
599-
fs-readdir-recursive: "npm:^1.1.0"
600-
glob: "npm:^7.2.0"
601-
make-dir: "npm:^2.1.0"
602-
slash: "npm:^2.0.0"
603-
peerDependencies:
604-
"@babel/core": ^7.0.0-0
605-
dependenciesMeta:
606-
"@nicolo-ribaudo/chokidar-2":
607-
optional: true
608-
chokidar:
609-
optional: true
610-
bin:
611-
babel: ./bin/babel.js
612-
babel-external-helpers: ./bin/babel-external-helpers.js
613-
checksum: 10/abde275866845bf0c86c090e23373e747da12e49776a879d7e5b4e55528e8a8ccc341b2e3f908d5bb3632b19c663000dca1ac5495d8805f5ce63e037b64e2b85
614-
languageName: node
615-
linkType: hard
616-
617590
"@babel/code-frame@npm:^7.0.0, @babel/code-frame@npm:^7.10.4, @babel/code-frame@npm:^7.12.13, @babel/code-frame@npm:^7.16.7, @babel/code-frame@npm:^7.25.7, @babel/code-frame@npm:^7.25.9, @babel/code-frame@npm:^7.27.1":
618591
version: 7.27.1
619592
resolution: "@babel/code-frame@npm:7.27.1"
@@ -5104,13 +5077,6 @@ __metadata:
51045077
languageName: node
51055078
linkType: hard
51065079

5107-
"@nicolo-ribaudo/chokidar-2@npm:2.1.8-no-fsevents.3":
5108-
version: 2.1.8-no-fsevents.3
5109-
resolution: "@nicolo-ribaudo/chokidar-2@npm:2.1.8-no-fsevents.3"
5110-
checksum: 10/c6e83af3b5051a3f6562649ff8fe37de9934a4cc02138678ed1badbd13ed3334f7ae5f63f2bbc3432210f6b245f082ac97e9b2afe0c13730c9838b295658c185
5111-
languageName: node
5112-
linkType: hard
5113-
51145080
"@nicolo-ribaudo/eslint-scope-5-internals@npm:5.1.1-v1":
51155081
version: 5.1.1-v1
51165082
resolution: "@nicolo-ribaudo/eslint-scope-5-internals@npm:5.1.1-v1"
@@ -8486,10 +8452,6 @@ __metadata:
84868452
version: 0.0.0-use.local
84878453
resolution: "@rocket.chat/federation-matrix@workspace:ee/packages/federation-matrix"
84888454
dependencies:
8489-
"@babel/cli": "npm:~7.28.3"
8490-
"@babel/core": "npm:~7.28.5"
8491-
"@babel/preset-env": "npm:~7.28.5"
8492-
"@babel/preset-typescript": "npm:~7.27.1"
84938455
"@rocket.chat/core-services": "workspace:^"
84948456
"@rocket.chat/core-typings": "workspace:^"
84958457
"@rocket.chat/ddp-client": "workspace:^"
@@ -8504,7 +8466,6 @@ __metadata:
85048466
"@types/emojione": "npm:^2.2.9"
85058467
"@types/node": "npm:~22.16.5"
85068468
"@types/sanitize-html": "npm:~2.16.0"
8507-
babel-jest: "npm:~30.2.0"
85088469
emojione: "npm:^4.5.0"
85098470
eslint: "npm:~8.45.0"
85108471
jest: "npm:~30.2.0"
@@ -18181,7 +18142,7 @@ __metadata:
1818118142
languageName: node
1818218143
linkType: hard
1818318144

18184-
"commander@npm:^6.1.0, commander@npm:^6.2.0":
18145+
"commander@npm:^6.1.0":
1818518146
version: 6.2.1
1818618147
resolution: "commander@npm:6.2.1"
1818718148
checksum: 10/25b88c2efd0380c84f7844b39cf18510da7bfc5013692d68cdc65f764a1c34e6c8a36ea6d72b6620e3710a930cf8fab2695bdec2bf7107a0f4fa30a3ef3b7d0e
@@ -22407,13 +22368,6 @@ __metadata:
2240722368
languageName: node
2240822369
linkType: hard
2240922370

22410-
"fs-readdir-recursive@npm:^1.1.0":
22411-
version: 1.1.0
22412-
resolution: "fs-readdir-recursive@npm:1.1.0"
22413-
checksum: 10/d5e3fd8456b8e5d57a43f169a9eaf65c70fa82c4a22f1d4361cdba4ea5e61c60c5c2b4ac481ea137a4d43b2b99b3ea2fae95ac2730255c4206d61af645866c3a
22414-
languageName: node
22415-
linkType: hard
22416-
2241722371
"fs.realpath@npm:^1.0.0":
2241822372
version: 1.0.0
2241922373
resolution: "fs.realpath@npm:1.0.0"
@@ -33641,13 +33595,6 @@ __metadata:
3364133595
languageName: node
3364233596
linkType: hard
3364333597

33644-
"slash@npm:^2.0.0":
33645-
version: 2.0.0
33646-
resolution: "slash@npm:2.0.0"
33647-
checksum: 10/512d4350735375bd11647233cb0e2f93beca6f53441015eea241fe784d8068281c3987fbaa93e7ef1c38df68d9c60013045c92837423c69115297d6169aa85e6
33648-
languageName: node
33649-
linkType: hard
33650-
3365133598
"slash@npm:^3.0.0":
3365233599
version: 3.0.0
3365333600
resolution: "slash@npm:3.0.0"

0 commit comments

Comments
 (0)