ci(sonar): analyse the server tests in the server's own TypeScript program

The scan ran out of memory since the places work: the analyser keeps every
file it parsed until the end, finds only files named tsconfig.json, and
server/tsconfig.json leaves out tests/, so the server tests landed in a
catch-all program that parsed server/src and shared/src a second time,
about 9,400 files and some 2 GB. Naming the tsconfigs, with the server's
tsconfig.tests.json in place of tsconfig.json, keeps them in the program
that already parsed those files. No file leaves the analysis.
This commit is contained in:
Maurice
2026-11-30 14:04:47 +01:00
parent dc645b1205
commit dbf808362d
+15
View File
@@ -99,6 +99,21 @@ sonar.cpd.exclusions=shared/src/i18n/**,server/src/db/kysely/**,shared/src/book/
# The hosted runner has 16 GB.
sonar.javascript.node.maxspace=8192
# The analyser builds one TypeScript program per tsconfig and keeps every file
# it parsed until the end of the scan. On its own it only finds files named
# tsconfig.json, and server/tsconfig.json leaves out tests/, so the server tests
# landed in a catch-all program with options merged from every package, which
# parsed all of server/src and shared/src a second time (about 9,400 files).
# tsconfig.tests.json is the server's own program over src and tests, so the
# tests share the files the server program already parsed. The order is the
# one the lookup used (alphabetical), so every other file stays in the program
# that analysed it before; the eslint-rules fixture project claimed no file.
sonar.typescript.tsconfigPaths=\
client/tsconfig.json,\
plugin-sdk/tsconfig.json,\
server/tsconfig.tests.json,\
shared/tsconfig.json
# Only categorical, path-wide suppressions live here — cases where the rule can
# never meaningfully apply to anything in the path. Instance-specific findings