We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad158c5 commit 674c20eCopy full SHA for 674c20e
packages/utils/src/getTestIds.ts
@@ -27,7 +27,7 @@ export function getTestIdsBrowser(): TestIdShape {
27
export default function getTestIds(): TestIdShape {
28
// For some reason, even though process.env contains the value of `test` for NODE_ENV, accessing it directly returns
29
// 'development'. Using `get()` does, in fact, return test so sticking with it
30
- if (get(process, 'env.NODE_ENV') !== 'test') {
+ if (typeof process !== 'undefined' && get(process, 'env.NODE_ENV') !== 'test') {
31
return getTestIdsBrowser();
32
}
33
0 commit comments