From 51e79566dddda88761be6576aaafb768670f1139 Mon Sep 17 00:00:00 2001 From: Ujjwal Sharma Date: Tue, 6 Mar 2018 10:55:46 +0530 Subject: [PATCH 1/8] test: rename test-regress-GH-1726 Rename the test appropriately alongside mentioning the subsystem Also, make a few basic changes to make sure the test conforms to the standard test structure Refs: https://github.com/nodejs/node/issues/19105 Refs: https://github.com/nodejs/node/blob/master/doc/guides/writing-tests.md#test-structure --- ...gress-GH-1726.js => test-regress-child_process-exit.js} | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) rename test/sequential/{test-regress-GH-1726.js => test-regress-child_process-exit.js} (98%) diff --git a/test/sequential/test-regress-GH-1726.js b/test/sequential/test-regress-child_process-exit.js similarity index 98% rename from test/sequential/test-regress-GH-1726.js rename to test/sequential/test-regress-child_process-exit.js index 1291dec261ccf6..303f015cf0aebd 100644 --- a/test/sequential/test-regress-GH-1726.js +++ b/test/sequential/test-regress-child_process-exit.js @@ -20,12 +20,13 @@ // USE OR OTHER DEALINGS IN THE SOFTWARE. 'use strict'; +require('../common'); + // Open a chain of five Node processes each a child of the next. The final -// process exits immediately. Each process in the chain is instructed to -// exit when its child exits. +// process exits immediately. Each process in the chain is instructed to exit +// when its child exits. // https://github.com/joyent/node/issues/1726 -require('../common'); const assert = require('assert'); const ch = require('child_process'); From 713a7d56c3b81c39f9919bf4f357ac0c68d229af Mon Sep 17 00:00:00 2001 From: Ujjwal Sharma Date: Tue, 6 Mar 2018 11:30:25 +0530 Subject: [PATCH 2/8] test: rename test-regress-GH-1697 Rename the test appropriately alongside mentioning the subsystem Also, make a few basic changes to make sure the test conforms to the standard test structure Refs: https://github.com/nodejs/node/issues/19105 Refs: https://github.com/nodejs/node/blob/master/doc/guides/writing-tests.md#test-structure --- ...-regress-GH-1697.js => test-regress-net-response_size.js} | 5 +++++ 1 file changed, 5 insertions(+) rename test/sequential/{test-regress-GH-1697.js => test-regress-net-response_size.js} (91%) diff --git a/test/sequential/test-regress-GH-1697.js b/test/sequential/test-regress-net-response_size.js similarity index 91% rename from test/sequential/test-regress-GH-1697.js rename to test/sequential/test-regress-net-response_size.js index 9d2555705ab023..e6be7fa7273362 100644 --- a/test/sequential/test-regress-GH-1697.js +++ b/test/sequential/test-regress-net-response_size.js @@ -21,6 +21,11 @@ 'use strict'; const common = require('../common'); + +// Make sure the net module's server doesn't throw an error when handling +// responses that are either too long or too small (especially on windows) +// https://github.com/nodejs/node-v0.x-archive/issues/1697 + const net = require('net'); const cp = require('child_process'); From e699b921a4fa2c9274da8cb504072f5eb461f9a5 Mon Sep 17 00:00:00 2001 From: Ujjwal Sharma Date: Tue, 6 Mar 2018 11:42:21 +0530 Subject: [PATCH 3/8] test: rename test-regress-GH-4015 Rename the test appropriately alongside mentioning the subsystem Also, make a few basic changes to make sure the test conforms to the standard test structure Refs: https://github.com/nodejs/node/issues/19105 Refs: https://github.com/nodejs/node/blob/master/doc/guides/writing-tests.md#test-structure --- ...st-regress-GH-4015.js => test-regress-fs-stat_sync.js} | 8 ++++++++ 1 file changed, 8 insertions(+) rename test/sequential/{test-regress-GH-4015.js => test-regress-fs-stat_sync.js} (80%) diff --git a/test/sequential/test-regress-GH-4015.js b/test/sequential/test-regress-fs-stat_sync.js similarity index 80% rename from test/sequential/test-regress-GH-4015.js rename to test/sequential/test-regress-fs-stat_sync.js index cac20c7948ae2f..c770b6b1560785 100644 --- a/test/sequential/test-regress-GH-4015.js +++ b/test/sequential/test-regress-fs-stat_sync.js @@ -22,6 +22,14 @@ 'use strict'; require('../common'); const { fixturesDir } = require('../common/fixtures'); + +// Check that the calls to Integer::New() and Date::New() succeed and bail out +// if they don't. +// V8 returns an empty handle on stack overflow. Trying to set the empty handle +// as a property on an object results in a NULL pointer dereference in release +// builds and an assert in debug builds. +// https://github.com/nodejs/node-v0.x-archive/issues/4015 + const assert = require('assert'); const { exec } = require('child_process'); From 7b91ada3a732283ce5d9052e7782181056e0da5c Mon Sep 17 00:00:00 2001 From: Ujjwal Sharma Date: Tue, 6 Mar 2018 11:57:06 +0530 Subject: [PATCH 4/8] test: rename test-regress-GH-4027 Rename the test appropriately alongside mentioning the subsystem Also, make a few basic changes to make sure the test conforms to the standard test structure Refs: https://github.com/nodejs/node/issues/19105 Refs: https://github.com/nodejs/node/blob/master/doc/guides/writing-tests.md#test-structure --- ...gress-GH-4027.js => test-regress-fs-watch_file.js} | 11 +++++++++++ 1 file changed, 11 insertions(+) rename test/sequential/{test-regress-GH-4027.js => test-regress-fs-watch_file.js} (81%) diff --git a/test/sequential/test-regress-GH-4027.js b/test/sequential/test-regress-fs-watch_file.js similarity index 81% rename from test/sequential/test-regress-GH-4027.js rename to test/sequential/test-regress-fs-watch_file.js index 8936537323581e..f5b9012acabe58 100644 --- a/test/sequential/test-regress-GH-4027.js +++ b/test/sequential/test-regress-fs-watch_file.js @@ -21,6 +21,17 @@ 'use strict'; const common = require('../common'); + +// Make sure the deletion event gets reported in the following scenario: +// 1. Watch a file. +// 2. The initial stat() goes okay. +// 3. Something deletes the watched file. +// 4. The second stat() fails with ENOENT. + +// The second stat() translates into the first 'change' event but a logic error +// stopped it from getting emitted. +// https://github.com/nodejs/node-v0.x-archive/issues/4027 + const assert = require('assert'); const path = require('path'); const fs = require('fs'); From 24016c4f142305c4cb37f01c0aca7644d16a5536 Mon Sep 17 00:00:00 2001 From: Ujjwal Sharma Date: Tue, 6 Mar 2018 19:07:56 +0530 Subject: [PATCH 5/8] test: rename tests to remove "regress" keyword Rename affected tests to remove the "regress" keyword as well as improve naming scheme. Refs: https://github.com/nodejs/node/issues/19105 --- ...t-regress-child_process-exit.js => test-child-process-exit.js} | 0 ...test-regress-fs-stat_sync.js => test-fs-stat-sync-overflow.js} | 0 ...-watch_file.js => test-fs-watch-file-enoent-after-deletion.js} | 0 ...est-regress-net-response_size.js => test-net-response-size.js} | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename test/sequential/{test-regress-child_process-exit.js => test-child-process-exit.js} (100%) rename test/sequential/{test-regress-fs-stat_sync.js => test-fs-stat-sync-overflow.js} (100%) rename test/sequential/{test-regress-fs-watch_file.js => test-fs-watch-file-enoent-after-deletion.js} (100%) rename test/sequential/{test-regress-net-response_size.js => test-net-response-size.js} (100%) diff --git a/test/sequential/test-regress-child_process-exit.js b/test/sequential/test-child-process-exit.js similarity index 100% rename from test/sequential/test-regress-child_process-exit.js rename to test/sequential/test-child-process-exit.js diff --git a/test/sequential/test-regress-fs-stat_sync.js b/test/sequential/test-fs-stat-sync-overflow.js similarity index 100% rename from test/sequential/test-regress-fs-stat_sync.js rename to test/sequential/test-fs-stat-sync-overflow.js diff --git a/test/sequential/test-regress-fs-watch_file.js b/test/sequential/test-fs-watch-file-enoent-after-deletion.js similarity index 100% rename from test/sequential/test-regress-fs-watch_file.js rename to test/sequential/test-fs-watch-file-enoent-after-deletion.js diff --git a/test/sequential/test-regress-net-response_size.js b/test/sequential/test-net-response-size.js similarity index 100% rename from test/sequential/test-regress-net-response_size.js rename to test/sequential/test-net-response-size.js From 5b96920800cd5e3841fd74444ac3a2771791b3fe Mon Sep 17 00:00:00 2001 From: Ujjwal Sharma Date: Tue, 6 Mar 2018 19:29:21 +0530 Subject: [PATCH 6/8] test: address nits and rename the corresponding fixture Refs: https://github.com/nodejs/node/issues/19105 --- .../{test-regress-GH-4015.js => test-fs-stat-sync-overflow.js} | 0 test/sequential/test-fs-stat-sync-overflow.js | 2 +- test/sequential/test-net-response-size.js | 2 +- 3 files changed, 2 insertions(+), 2 deletions(-) rename test/fixtures/{test-regress-GH-4015.js => test-fs-stat-sync-overflow.js} (100%) diff --git a/test/fixtures/test-regress-GH-4015.js b/test/fixtures/test-fs-stat-sync-overflow.js similarity index 100% rename from test/fixtures/test-regress-GH-4015.js rename to test/fixtures/test-fs-stat-sync-overflow.js diff --git a/test/sequential/test-fs-stat-sync-overflow.js b/test/sequential/test-fs-stat-sync-overflow.js index c770b6b1560785..9c9109989a19c3 100644 --- a/test/sequential/test-fs-stat-sync-overflow.js +++ b/test/sequential/test-fs-stat-sync-overflow.js @@ -34,7 +34,7 @@ const assert = require('assert'); const { exec } = require('child_process'); const cmd = - `"${process.execPath}" "${fixturesDir}/test-regress-GH-4015.js"`; + `"${process.execPath}" "${fixturesDir}/test-fs-stat-sync-overflow.js"`; exec(cmd, function(err, stdout, stderr) { assert(/RangeError: Maximum call stack size exceeded/.test(stderr)); diff --git a/test/sequential/test-net-response-size.js b/test/sequential/test-net-response-size.js index e6be7fa7273362..c5d7e9b600e05d 100644 --- a/test/sequential/test-net-response-size.js +++ b/test/sequential/test-net-response-size.js @@ -23,7 +23,7 @@ const common = require('../common'); // Make sure the net module's server doesn't throw an error when handling -// responses that are either too long or too small (especially on windows) +// responses that are either too long or too small (especially on Windows) // https://github.com/nodejs/node-v0.x-archive/issues/1697 const net = require('net'); From 8532aaa258935b9d47073daca2e39a6dcfe6ae8a Mon Sep 17 00:00:00 2001 From: Ujjwal Sharma Date: Tue, 6 Mar 2018 19:39:10 +0530 Subject: [PATCH 7/8] test: rename test-regress-GH-784.js Rename the test appropriately alongside mentioning the subsystem Also, make a few basic changes to make sure the test conforms to the standard test structure Refs: https://github.com/nodejs/node/issues/19105 Refs: https://github.com/nodejs/node/blob/master/doc/guides/writing-tests.md#test-structure --- ...est-regress-GH-784.js => test-http-econnrefused.js} | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) rename test/sequential/{test-regress-GH-784.js => test-http-econnrefused.js} (96%) diff --git a/test/sequential/test-regress-GH-784.js b/test/sequential/test-http-econnrefused.js similarity index 96% rename from test/sequential/test-regress-GH-784.js rename to test/sequential/test-http-econnrefused.js index 4b285020d45a35..ff4508963b9877 100644 --- a/test/sequential/test-regress-GH-784.js +++ b/test/sequential/test-http-econnrefused.js @@ -20,15 +20,15 @@ // USE OR OTHER DEALINGS IN THE SOFTWARE. 'use strict'; -// Regression test for GH-784 -// https://github.com/joyent/node/issues/784 -// +const common = require('../common'); + // The test works by making a total of 8 requests to the server. The first // two are made with the server off - they should come back as ECONNREFUSED. // The next two are made with server on - they should come back successful. // The next two are made with the server off - and so on. Without the fix -// we were experiencing parse errors and instead of ECONNREFUSED. -const common = require('../common'); +// we were experiencing parse errors instead of ECONNREFUSED. +// https://github.com/nodejs/node-v0.x-archive/issues/784 + const http = require('http'); const assert = require('assert'); From c3cc56b1ed469b254508b27eb357930c4437c333 Mon Sep 17 00:00:00 2001 From: Ujjwal Sharma Date: Tue, 6 Mar 2018 20:00:38 +0530 Subject: [PATCH 8/8] test: rename test-regress-GH-877.js Rename the test appropriately alongside mentioning the subsystem Also, make a few basic changes to make sure the test conforms to the standard test structure Refs: https://github.com/nodejs/node/issues/19105 Refs: https://github.com/nodejs/node/blob/master/doc/guides/writing-tests.md#test-structure --- .../{test-regress-GH-877.js => test-http-max-sockets.js} | 4 ++++ 1 file changed, 4 insertions(+) rename test/sequential/{test-regress-GH-877.js => test-http-max-sockets.js} (94%) diff --git a/test/sequential/test-regress-GH-877.js b/test/sequential/test-http-max-sockets.js similarity index 94% rename from test/sequential/test-regress-GH-877.js rename to test/sequential/test-http-max-sockets.js index c717c2dd74f444..24629448f7ac77 100644 --- a/test/sequential/test-regress-GH-877.js +++ b/test/sequential/test-http-max-sockets.js @@ -21,6 +21,10 @@ 'use strict'; const common = require('../common'); + +// Make sure http server doesn't wait for socket pool to establish connections +// https://github.com/nodejs/node-v0.x-archive/issues/877 + const http = require('http'); const assert = require('assert');