mirror of
https://github.com/dadosfera/maestro.git
synced 2026-11-16 08:49:08 +00:00
feat(auth): GET /auth/module-identity — identity + module gate
Adds the route (cookie auth via verifyAccessToken, module gate seqid 31, X-Auth-* headers, admin via seqid set). Adds a jest setupFiles hook giving a dummy DUC_URL for module-load-time env reads, which also unblocks the pre-existing authentication.guard.spec. Co-Authored-By: WOZCODE <contact@withwoz.com>
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
/**
|
||||
* Jest setupFiles hook: provide dummy values for env vars that modules read
|
||||
* at *import time* (module-load side effects), so unit specs that transitively
|
||||
* import those modules don't crash before a single test runs.
|
||||
*
|
||||
* These are never exercised by unit tests — the services that use them are
|
||||
* stubbed via DI — but the values must exist because the reads happen at
|
||||
* module evaluation, before any mock is installed.
|
||||
*
|
||||
* DUC_URL: read at load time in src/modules/duc/client.config.ts, reached via
|
||||
* the AuthClientService import chain.
|
||||
*/
|
||||
process.env.DUC_URL = process.env.DUC_URL || 'duc:localhost:0';
|
||||
Reference in New Issue
Block a user