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 ff2b65c commit 0c8a549Copy full SHA for 0c8a549
packages/jest-util/src/createProcessObject.ts
@@ -111,18 +111,12 @@ export default function (): NodeJS.Process {
111
112
newProcess.env = createProcessEnv();
113
newProcess.send = () => {};
114
-
115
- const domainPropertyDescriptor = Object.getOwnPropertyDescriptor(
116
- newProcess,
117
- 'domain',
118
- );
119
- if (domainPropertyDescriptor && !domainPropertyDescriptor.enumerable) {
120
- Object.defineProperty(newProcess, 'domain', {
121
- get() {
122
- return process.domain;
123
- },
124
- });
125
- }
+
+ Object.defineProperty(newProcess, 'domain', {
+ get() {
+ return process.domain;
+ },
+ });
126
127
return newProcess;
128
}
0 commit comments