aboutsummaryrefslogtreecommitdiffstats
path: root/tests/msw/instances/index.ts
diff options
context:
space:
mode:
Diffstat (limited to 'tests/msw/instances/index.ts')
-rw-r--r--tests/msw/instances/index.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/msw/instances/index.ts b/tests/msw/instances/index.ts
index 82218c3..2e2dfeb 100644
--- a/tests/msw/instances/index.ts
+++ b/tests/msw/instances/index.ts
@@ -1,7 +1,8 @@
import { graphql } from 'msw';
import { GITHUB_API } from '../../../src/utils/constants';
-const wordpressGraphQLUrl = process.env.NEXT_PUBLIC_STAGING_GRAPHQL_API;
+const { env } = { ...process, ...window.process };
+const wordpressGraphQLUrl = env.NEXT_PUBLIC_STAGING_GRAPHQL_API;
if (!wordpressGraphQLUrl)
throw new Error('You forgot to define an URL for the WordPress GraphQL API');