3 Commits
Author SHA1 Message Date
Ruslan KonviserandClaude Opus 5.5 5c8d4e1c8c chore(cspell): declare or reword the words #10324 added
The develop push of #10324 (9a6f8787) failed "Check Spelling and Typos
with cspell" (run 36399734369): 13 issues in 5 files. PRs into develop
run no cspell, so this surfaced only after the merge.

- "Nx's" (4x) and "callables": reworded in the comments.
- "internmap" (a d3 dependency, npm package name): added to .cspell.json.
- "avascript" / "msdt" in the safe-url spec: file-level cspell:ignore,
  as the repo does elsewhere; they are the tail of the entity-encoded
  "javascript:" payloads and the ms-msdt: scheme the tests feed in.

Comment, dictionary and directive changes only; no code or config
behaviour changes. Local cspell 6.31.3 on the five files: 0 issues
(the pre-fix safe-url spec, as a control: 6 issues).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-28 11:04:48 +02:00
Ruslan KonviserandClaude Opus 5.5 dc0897c29d test: address review findings on the unit-test harness
- docs-ui safe-url linearity tests: time each input size in batches of
  calls (doubled until a batch runs >= 50 ms, median of three) and take
  the growth ratio as measured, with no 1 ms floor that could understate
  growth for sub-millisecond samples (CodeRabbit). Keep a generous
  absolute ceiling (3 s per rejection of the smaller input, ~9x the
  slowest CI reading) so a uniformly slow validator cannot pass either.
- role-permission demo-mode suite: state its scope precisely. The reload
  only adds rows, so it never removes a deletion grant a tenant already
  holds; the seed and RolePermissionService keep demo tenants free of it,
  and PermissionGuard has no demo-mode rule (a product question, out of
  scope for this test-harness PR).
- Sonar: String.raw for the transformIgnorePatterns regex (pattern
  verified byte-identical), startsWith in jest.resolver.js, and no
  blanket eslint-disable in the new activepieces jest config (its
  template, integration-make-com, has none; eslint clean).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-28 09:26:56 +02:00
Ruslan KonviserandClaude Opus 5.5 91d91ffca3 test: make the unit-test run hermetic and fix the Angular jest harness
The Unit Tests workflow has never been green (24 of 97 projects red at
develop eac7136562, run 36319732347). Causes addressed here:

- Env leak: Nx loads the committed .env.local (DEMO=true,
  WORKER_QUEUE_ENABLED=false, NODE_ENV=development) into every task.
  The test step now sets NX_LOAD_DOT_ENV_FILES=false, and the two specs
  that depend on a mode pin it themselves (role-permission counts pin
  environment.demo=false and gain a demo-mode suite asserting 209 per
  role; the worker spec clears the queue env before the constants load).
  .env.local is unchanged.
- Angular harness: nohoist gives each workspace its own @angular copy,
  so setupZoneTestEnv() initialised a different TestBed from the one the
  spec used. A workspace resolver (jest.resolver.js, wrapping Nx's) makes
  every @angular/* import in a Jest project resolve to one copy. The
  Angular projects now inherit the preset's transformIgnorePatterns,
  which gains the .mjs exception plus @datorama, @ngneat and lodash-es.
- ui-config's environment.ts is generated and gitignored; the workflow
  runs `yarn config:dev` before the tests, as the Playwright workflow does.
- Misconfigured targets: gauzy (jest.config.js -> .ts, Angular transform,
  setupFile moved into the config), integration-sim-ui (.ts -> .cts),
  integration-activepieces (config file added), mcp-auth (ran
  `node build/main.js --test`; now the jest executor like apps/mcp).
- Real failures: the openai "silence" case used a body with no `text`,
  which the shared helper rejects by contract; the toolbar spec read the
  tabIndex property, which is 0 on any button; the docs-ui linearity
  tests asserted wall-clock bounds, now a 4x-input growth ratio.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-27 17:39:40 +02:00