EnvModel: Returns many feature options
Overview
These tests validate nestjs-mod EnvModel: environment variable reading, required field validation, and DI value propagation into services.
What We Do And Verify
-
We verify how
envTransformandEnvModel/EnvModelPropertydecorators extract and validate env values. -
We confirm expected behavior for missing or invalid required env fields.
-
We lock the DI access contract for env values in services.
-
We lock the API boundary contract (status, payload, and response shape) to protect externally observable behavior.
-
We explicitly validate the error contract: not only failure itself, but also error shape/content expected by module consumers.
-
We confirm correct lifecycle behavior in test environment: initialization, dependency readiness, and graceful shutdown of app/modules.