@@ -3,7 +3,6 @@ require('../spec_helper')
3
3
const os = require ( 'os' )
4
4
const tty = require ( 'tty' )
5
5
const snapshot = require ( '../support/snapshot' )
6
- const mockedEnv = require ( 'mocked-env' )
7
6
const supportsColor = require ( 'supports-color' )
8
7
const proxyquire = require ( 'proxyquire' )
9
8
const hasha = require ( 'hasha' )
@@ -12,9 +11,6 @@ const la = require('lazy-ass')
12
11
const util = require ( `${ lib } /util` )
13
12
const logger = require ( `${ lib } /logger` )
14
13
15
- // https://github.com/cypress-io/cypress/issues/5431
16
- const expectedNodeOptions = `--max-http-header-size=${ 1024 * 1024 } `
17
-
18
14
describe ( 'util' , ( ) => {
19
15
beforeEach ( ( ) => {
20
16
sinon . stub ( process , 'exit' )
@@ -217,7 +213,6 @@ describe('util', () => {
217
213
FORCE_COLOR : '1' ,
218
214
DEBUG_COLORS : '1' ,
219
215
MOCHA_COLORS : '1' ,
220
- NODE_OPTIONS : expectedNodeOptions ,
221
216
} )
222
217
223
218
util . supportsColor . returns ( false )
@@ -229,46 +224,7 @@ describe('util', () => {
229
224
FORCE_STDERR_TTY : '0' ,
230
225
FORCE_COLOR : '0' ,
231
226
DEBUG_COLORS : '0' ,
232
- NODE_OPTIONS : expectedNodeOptions ,
233
- } )
234
- } )
235
- } )
236
-
237
- context ( '.getNodeOptions' , ( ) => {
238
- let restoreEnv
239
-
240
- afterEach ( ( ) => {
241
- if ( restoreEnv ) {
242
- restoreEnv ( )
243
- restoreEnv = null
244
- }
245
- } )
246
-
247
- it ( 'adds required NODE_OPTIONS' , ( ) => {
248
- restoreEnv = mockedEnv ( {
249
- NODE_OPTIONS : undefined ,
250
227
} )
251
-
252
- expect ( util . getNodeOptions ( { } ) ) . to . deep . eq ( {
253
- NODE_OPTIONS : expectedNodeOptions ,
254
- } )
255
- } )
256
-
257
- it ( 'includes existing NODE_OPTIONS' , ( ) => {
258
- restoreEnv = mockedEnv ( {
259
- NODE_OPTIONS : '--foo --bar' ,
260
- } )
261
-
262
- expect ( util . getNodeOptions ( { } ) ) . to . deep . eq ( {
263
- NODE_OPTIONS : `${ expectedNodeOptions } --foo --bar` ,
264
- ORIGINAL_NODE_OPTIONS : '--foo --bar' ,
265
- } )
266
- } )
267
-
268
- it ( 'does not return if dev is set and version < 12' , ( ) => {
269
- expect ( util . getNodeOptions ( {
270
- dev : true ,
271
- } , 11 ) ) . to . be . undefined
272
228
} )
273
229
} )
274
230
0 commit comments