summaryrefslogtreecommitdiff
path: root/test/parallel/test-cluster-rr-ref.js
AgeCommit message (Collapse)Author
2017-04-18test: remove common.PORT from multiple testsTarun Batra
PR-URL: https://github.com/nodejs/node/pull/12451 Ref: https://github.com/nodejs/node/issues/12376 Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2017-02-06test: add common.mustNotCall()cjihrig
This commit adds a mustNotCall() helper for testing. This provides an alternative to using common.fail() as a callback, or creating a callback function for the sole purpose of calling common.fail(). PR-URL: https://github.com/nodejs/node/pull/11152 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
2015-12-30test: remove unused assert module importsRich Trott
Many test modules load assert but do not use it. This change removes those instances. It also removes a handful of other unused variables when they were nearby. PR-URL: https://github.com/nodejs/node/pull/4438 Reviewed-By: Michaƫl Zasso <mic.besace@gmail.com> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2015-10-24test: wrap assert.fail when passed to callbackMyles Borins
Currently there are many instances where assert.fail is directly passed to a callback for error handling. Unfortunately this will swallow the error as it is the third argument of assert.fail that sets the message not the first. This commit adds a new function to test/common.js that simply wraps assert.fail and calls it with the provided message. Tip of the hat to @trott for pointing me in the direction of this. PR-URL: https://github.com/nodejs/node/pull/3453 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
2015-07-30cluster: add handle ref/unref stubs in rr modeBen Noordhuis
Add ref() and unref() stub methods to the faux handle in round-robin mode. Fixes the following TypeError when calling `server.unref()` in the worker: net.js:1521 this._handle.unref(); ^ TypeError: this._handle.unref is not a function at Server.unref (net.js:1521:18) No actual reference counting is implemented. It would effectively be a no-op because the control channel would still keep the worker alive. Fixes: https://github.com/nodejs/node/issues/73 PR-URL: https://github.com/nodejs/io.js/pull/2274 Reviewed-By: Evan Lucas <evanlucas@me.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>