File tree Expand file tree Collapse file tree 2 files changed +6
-7
lines changed Expand file tree Collapse file tree 2 files changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -60,11 +60,10 @@ class Test extends Request {
60
60
serverAddress ( app , path ) {
61
61
const addr = app . address ( ) ;
62
62
63
- if ( ! addr ) {
64
- this . _server = app . listen ( 0 ) ;
65
- } else {
66
- this . _server = app ;
67
- }
63
+ if ( ! addr ) this . _server = app . listen ( 0 ) ;
64
+ // } else {
65
+ // this._server = app;
66
+ // }
68
67
const port = app . address ( ) . port ;
69
68
const protocol = app instanceof Server ? 'https' : 'http' ;
70
69
return protocol + '://127.0.0.1:' + port + path ;
Original file line number Diff line number Diff line change @@ -1444,8 +1444,8 @@ describeHttp2('http2', function() {
1444
1444
. end ( function ( err , res ) {
1445
1445
res . status . should . equal ( 200 ) ;
1446
1446
res . text . should . equal ( 'hey' ) ;
1447
- // Let supertest handle server closing
1448
- done ( ) ;
1447
+ // lose the external server explicitly
1448
+ server . close ( done ) ;
1449
1449
} ) ;
1450
1450
} ) ;
1451
1451
} ) ;
You can’t perform that action at this time.
0 commit comments