File tree Expand file tree Collapse file tree 3 files changed +5
-7
lines changed
Expand file tree Collapse file tree 3 files changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -35,4 +35,4 @@ export type { BaseEnv } from './schemas/env.schema.js';
3535export { $MongoEnv } from './schemas/mongo-env.schema.js' ;
3636export type { RequestUser } from './user-config.js' ;
3737export type { BaseEnvSchema } from './utils/env.utils.js' ;
38- export { getInstanceId } from './utils/env.utils.js' ;
38+ export { INSTANCE_ID } from './utils/env.utils.js' ;
Original file line number Diff line number Diff line change 11import { describe , expect , it } from 'vitest' ;
22
3- import { getInstanceId } from '../env.utils.js' ;
3+ import { INSTANCE_ID } from '../env.utils.js' ;
44
55describe ( 'getInstanceId' , ( ) => {
6- it ( 'should return a UUID in tests' , ( ) => {
7- expect ( getInstanceId ( ) ) . toBeTypeOf ( 'string' ) ;
6+ it ( 'should be a UUID in tests' , ( ) => {
7+ expect ( INSTANCE_ID ) . toBeTypeOf ( 'string' ) ;
88 } ) ;
99} ) ;
Original file line number Diff line number Diff line change @@ -5,9 +5,7 @@ import type { BaseEnv } from '../schemas/env.schema.js';
55
66export type BaseEnvSchema = z . ZodType < BaseEnv > ;
77
8- export function getInstanceId ( ) : string {
9- return process . env . LIBNEST_INSTANCE_ID ! ;
10- }
8+ export const INSTANCE_ID = process . env . LIBNEST_INSTANCE_ID ! ;
119
1210export function parseEnv < TSchema extends BaseEnvSchema = BaseEnvSchema > ( schema : TSchema ) : z . output < TSchema > {
1311 // this is required so that these can be statically replaced in the bundle
You can’t perform that action at this time.
0 commit comments