summaryrefslogtreecommitdiff
path: root/test/gc
AgeCommit message (Collapse)Author
2017-10-15n-api: use module name macroMichael Dawson
Update tests to use module name macro PR-URL: https://github.com/nodejs/node/pull/16185 Reviewed-By: Gabriel Schulhof <gabriel.schulhof@intel.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
2017-07-21lib,src: fix consistent spacing inside bracesSebastiaan Deckers
PR-URL: https://github.com/nodejs/node/pull/14162 Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Timothy Gu <timothygu99@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2017-05-05test: reduce string concatenationsVse Mozhet Byt
PR-URL: https://github.com/nodejs/node/pull/12735 Refs: https://github.com/nodejs/node/pull/12455 Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
2017-02-11test: remove nan + weakBen Noordhuis
Since the previous commit obsoleted them, remove them. PR-URL: https://github.com/nodejs/node/pull/11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2017-02-11test: remove dependency on node-weakBen Noordhuis
Replace node-weak with a small hand-rolled add-on. We can now drop node-weak and nan, reducing the size of the source tree by about 750 kB and the size of the tarball by about 150-300 kB. PR-URL: https://github.com/nodejs/node/pull/11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2017-02-11test: don't call process.exit() in gc testsBen Noordhuis
Rewrite the tests in test/gc so that they no longer call process.exit(). Instead they exit gracefully now. PR-URL: https://github.com/nodejs/node/pull/11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
2017-01-22test: don't connect to :: (use localhost instead)Gibson Fahnestock
If a test does http.listen(0) or net.listen(0), http.listen(0).address().address returns '::'. Some machines will resolve this to localhost, but not all. Every machine should have localhost defined in /etc/hosts (or equivalent), so it should always resolve. Fixes: https://github.com/nodejs/node/issues/7291 PR-URL: https://github.com/nodejs/node/pull/10854 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michal Zasso <targos@protonmail.com>
2017-01-11test: use eslint to fix var->const/letGibson Fahnestock
Manually fix issues that eslint --fix couldn't do automatically. PR-URL: https://github.com/nodejs/node/pull/10685 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Roman Reiss <me@silverwind.io>
2017-01-02test: use const for all require() callscjihrig
PR-URL: https://github.com/nodejs/node/pull/10550 Reviewed-By: Rich Trott <rtrott@gmail.com>
2017-01-02test: increase usage of assert.ifError()cjihrig
PR-URL: https://github.com/nodejs/node/pull/10543 Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2016-10-05test: remove blank lines at end of filesRich Trott
In preparation for a lint rule that disallows empty lines at the end of a file, remove such lines from a number of test files. Refs: https://github.com/nodejs/node/issues/8918 PR-URL: https://github.com/nodejs/node/pull/8920 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ilkka Myller <ilkka.myller@nodefield.com> Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Roman Reiss <me@silverwind.io> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2016-09-20tools: add eslint rule prefer-assert-methodsDany Shaanan
PR-URL: https://github.com/nodejs/node/pull/8622 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Yorkie Liu <yorkiefixer@gmail.com> Reviewed-By: Jackson Tian <shvyo1987@gmail.com> Reviewed-By: Johan Bergström <bugs@bergstroem.nu> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Teddy Katz <teddy.katz@gmail.com>
2016-07-21test: make import common as the first lineSakthipriyan Vairamani
The `test/common` module has the capability to identify if any variable is leaked to the global scope and fail the test. So that has to be imported at the beginning. PR-URL: https://github.com/nodejs/node/pull/7786 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
2016-07-14test: cleanup IIFE testscjihrig
A number of test files use IIFEs to separate distinct tests from each other in the same file. The project has been moving toward using block scopes and let/const in favor of IIFEs. This commit moves IIFE tests to block scopes. Some additional cleanup such as use of strictEqual() and common.mustCall() is also included. PR-URL: https://github.com/nodejs/node/pull/7694 Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
2016-05-31test: update weak module for gc testsRich Trott
Previous version of weak used for gc tests emitted a warning on OS X. Updating to current version eliminates warning. PR-URL: https://github.com/nodejs/node/pull/7014 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com>
2016-05-31test: remove `common.PORT` from gc testsRich Trott
Allow the operating system to provide an arbitrary available port rather than using `common.PORT`, as `common.PORT` makes it likely that a test will fail with `EADDRINUSE` as a side effect of an earlier test. PR-URL: https://github.com/nodejs/node/pull/7013 Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2016-05-11benchmark,test,lib: remove extra spacesRich Trott
In preparation for stricter linting, remove extra spaces. PR-URL: https://github.com/nodejs/node/pull/6645 Reviewed-By: Michaël Zasso <mic.besace@gmail.com> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Roman Reiss <me@silverwind.io>
2016-04-28test,tools: limit lint tolerance of gc globalRich Trott
Lint rules permitted the `gc` global in any test file. This change limits it to just the files that need it. PR-URL: https://github.com/nodejs/node/pull/6324 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2016-02-04tools: lint for spacing around unary operatorsRich Trott
Enable `space-unary-ops` in `.eslintrc`. This prohibits things like: i ++ // use `i++` instead typeof(foo) // use `typeof foo` or `typeof (foo)` instead Ref: https://github.com/nodejs/node/pull/4772#discussion_r51732299 PR-URL: https://github.com/nodejs/node/pull/5063 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Michaël Zasso <mic.besace@gmail.com> Reviewed-By: Roman Reiss <me@silverwind.io> Reviewed-By: James M Snell <jasnell@gmail.com>
2016-01-13test: fix style issues after eslint updateMichaël Zasso
Replace var keyword with const or let. PR-URL: https://github.com/nodejs/io.js/pull/2286 Reviewed-By: Roman Reiss <me@silverwind.io>
2016-01-11test: only include http module onceRich Trott
A few tests in test/gc include the http module twice. Remove duplicate require(). PR-URL: https://github.com/nodejs/node/pull/4606 Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Michaël Zasso <mic.besace@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
2015-12-30test: fix race condition in test-http-client-onerrorDevin Nakamura
Occasionally test-http-client-onerror will fail with a refused connection. This patch fixes the possibility that connections will be attempted before server is listening. PR-URL: https://github.com/nodejs/node/pull/4346 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Brian White <mscdex@mscdex.net> Reviewed-By: Johan Bergström <bugs@bergstroem.nu> Reviewed-By: James M Snell <jasnell@gmail.com>
2015-09-06src: replace usage of v8::Handle with v8::LocalMichaël Zasso
v8::Handle is deprecated: https://codereview.chromium.org/1224623004 PR-URL: https://github.com/nodejs/io.js/pull/2202 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-08-22test: add spaces after keywordsBrendan Ashworth
eg changes: if(x) { ... } to: if (x) { ... }
2015-05-19test: enable linting for testsRoman Reiss
Enable linting for the test directory. A number of changes was made so all tests conform the current rules used by lib and src directories. The only exception for tests is that unreachable (dead) code is allowed. test-fs-non-number-arguments-throw had to be excluded from the changes because of a weird issue on Windows CI. PR-URL: https://github.com/nodejs/io.js/pull/1721 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2015-02-22test: common.js -> commonBrendan Ashworth
This commit changes many test styles to change all references from require('./common.js'); to require('./common');. The latter is much more common, with the former only being used in 50 tests. It is just a stylistic change, and it seems that `common.js` was introduced by a rogue test and copied and pasted into the rest. Semver: patch PR-URL: https://github.com/iojs/io.js/pull/917 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
2014-03-17test: update our branched weakref to v8 3.24Timothy J Fontaine
2014-02-24test: backoff client connection ratesTimothy J Fontaine
We were being very aggressive in our connection creations, resulting in the pipeline flood detection to drop us. Relax how fast we're creating these connections so the gc can run all its tests.
2014-01-20test: refactor to use common testcfgTimothy J Fontaine
2013-10-23test: fix up weakref.cc after v8 api changeBen Noordhuis
2013-07-06test: fix up weakref.cc after v8 api changeBen Noordhuis
2013-06-12test: fix up weakref.cc after v8 api changeBen Noordhuis
2013-05-13test: fix up weakref.cc deprecation warningsBen Noordhuis
2013-05-13test: fix up weakref.cc after v8 api changeBen Noordhuis
2013-03-20test: fix up weakref.cc after v8 api changeBen Noordhuis
2012-06-13test: use the debug build of node-weak when necessaryNathan Rajlich
2012-06-13test: add a .gitignore file to ignore weak's compiled "build" dirNathan Rajlich
2012-06-14test: bundle node-weak in test/gc so that it doesn't need to be downloadedNathan Rajlich
2012-06-13test-net-timeout: make it pass on WindowsBert Belder
The test didn't take into account that some time might pass before libuv makes close callbacks. This is now fixed.
2012-05-11500 is a magic number for the GC for some reasonisaacs
2012-05-04Clean up gc testsisaacs
This fixes the additional issues brought up in #3179.
2012-05-03Tests for memory leaksisaacs