Skip to content

Commit

Permalink
🐛 isMock skal være true hvis FUNCTIONAL_TESTS er enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
tidnav committed Feb 28, 2024
1 parent 3c04bea commit 0af0097
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion utils/environments.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
const MOCK_ENVIRONMENTS = ['localhost'];

export const isMock = () => MOCK_ENVIRONMENTS.includes(process.env.RUNTIME_ENVIRONMENT ?? '');
export const isMock = () =>
MOCK_ENVIRONMENTS.includes(process.env.RUNTIME_ENVIRONMENT ?? '') || isFunctionalTest();

export const isFunctionalTest = () => process.env.FUNCTIONAL_TESTS === 'enabled';

Expand Down

0 comments on commit 0af0097

Please sign in to comment.