Paul Milham
7a8d51c079
test: replaced literals in errors with templates
PR-URL: https://github.com/nodejs/node/pull/15911
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
Russell Dempsey
beb23570dc
test: display better error message for assertion
This commit makes understanding assertion failures easier by
displaying the values that failed the assertion.
PR-URL: https://github.com/nodejs/node/pull/15883
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
7 years ago
heeeunkimmm
3f95a8a69e
test: changed buffer-zero output
Added interpolated strings to display the error value
PR-URL: https://github.com/nodejs/node/pull/15926
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
Alex McKenzie
8baa325185
test: replaced fixturesDir with fixtures module
PR-URL: https://github.com/nodejs/node/pull/15927
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
Faisal Yaqoob
ba6049f7f9
test: remove literal error messages
Assertions will now print the values that caused the assertions
to fail.
PR-URL: https://github.com/nodejs/node/pull/15928
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
Daniel Kostro
96221c2471
test: refactor test to use the fixtures module
PR-URL: https://github.com/nodejs/node/pull/15934
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
7 years ago
Greg Matthews
2bf182dc46
test: replace fixturesDir with fixtures module
PR-URL: https://github.com/nodejs/node/pull/15932
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
Alice Tsui
f96745a4d3
test: modify test messages to template literals
PR-URL: https://github.com/nodejs/node/pull/15931
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
BradLarson
3f5f847ed1
test: replace common.fixturesDir with fixture
PR-URL: https://github.com/nodejs/node/pull/15940
Reviewed-By: Sam Roberts <vieuxtech@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
7 years ago
joanne-jjb
31ab2ebbde
test: changes to use template literal
PR-URL: https://github.com/nodejs/node/pull/15937
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Mujtaba Al-Tameemi
3a265556ec
test: replace fixturesDir with fixtures
PR-URL: https://github.com/nodejs/node/pull/15949
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Luis Del Águila
fcb0079c5f
test: remove common.fixturesDir
Replace `common.fixturesDir` with usage of the `common.fixtures` module
PR-URL: https://github.com/nodejs/node/pull/15950
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
7 years ago
Emily Ford
e6e58fde8b
test: remove template literal
PR-URL: https://github.com/nodejs/node/pull/15953
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
dpaulino
582749e338
test: removed string from assert message arg
PR-URL: https://github.com/nodejs/node/pull/15954
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Brant Barger
b08ae3a8e4
test: replace literal with template string
PR-URL: https://github.com/nodejs/node/pull/15957
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
jacjam
ca4e549410
test: upgrade from fixturesDir to fixtures.path
The common/fixtures module provides convenience methods
for working with files in the test/fixtures directory.
PR-URL: https://github.com/nodejs/node/pull/15960
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Chris Budy
ab3c84fc25
test: use defaultHistoryPath instead of path.join
PR-URL: https://github.com/nodejs/node/pull/15969
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
BinarySo1o
37681b5e09
test: replace fixturesDir with fixtures module
PR-URL: https://github.com/nodejs/node/pull/15961
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
7 years ago
jopann
0dbff4c862
test: replaced fixturesDir with common.fixtures
PR-URL: https://github.com/nodejs/node/pull/15971
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
7 years ago
Eric Pemberton
55bb9c4128
test: improve assert messages
PR-URL: https://github.com/nodejs/node/pull/15972
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
Barry Tam
96eba098ef
test: replacing assert message with template
PR-URL: https://github.com/nodejs/node/pull/15974
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
Laura Cabrera
0d38e6d01f
test: use common.fixtures module in test-preload
PR-URL: https://github.com/nodejs/node/pull/15975
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
7 years ago
Alec Ferguson
91724cb2a1
test: more informative test failure messages
PR-URL: https://github.com/nodejs/node/pull/15977
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
7 years ago
Luke Greenleaf
99237cf00d
test: alter assert.strictEqual to default message
PR-URL: https://github.com/nodejs/node/pull/15978
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Anna Henningsen
037d9085f1
src: use more appropriate context-entered check
Make the context check in `MakeCallback` match what the comment says
(and what actually makes sense).
PR-URL: https://github.com/nodejs/node/pull/15691
Fixes: https://github.com/nodejs/node/issues/15672
Ref: https://github.com/nodejs/node/pull/15428
Ref: f27b5e4bda
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Eugene Ostroukhov <eostroukhov@google.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Sean Cox
b050c14d91
test: replaced common.fixturesDir with readKey
PR-URL: https://github.com/nodejs/node/pull/15933
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
7 years ago
Annie Weng
4457f4feb9
test: replace fixturesDir in tls-env-bad-extra-ca
PR-URL: https://github.com/nodejs/node/pull/15813
Reviewed-By: Ryan Graham <r.m.graham@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
7 years ago
Emily Marigold Klassen
41b65b9fa3
test: use common.fixtures in checkServerIdentity
PR-URL: https://github.com/nodejs/node/pull/15951
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
7 years ago
rhalldearn
b3a8bf3dca
test: replaced common.fixturesDir with readKey
PR-URL: https://github.com/nodejs/node/pull/15952
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
7 years ago
John Miller
b13e660a47
test: use fixtures.path for cmd string building
PR-URL: https://github.com/nodejs/node/pull/15982
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
7 years ago
Thomas Schorn
59e6791fe5
test: replace fixturesDir with fixtures.readKey
PR-URL: https://github.com/nodejs/node/pull/15948
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
7 years ago
ashleyraymaceli
86d803b385
test: replace common.fixturesDir with readKey
PR-URL: https://github.com/nodejs/node/pull/15946
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
7 years ago
Sam Skjonsberg
eb08e3e5fb
test: replace common.fixturesDir with fixtures.
Replaces the use of `common.fixturesDir` with the generic `fixtures`
mechanism.
PR-URL: https://github.com/nodejs/node/pull/15802
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
7 years ago
gbugaisky
5ca1c7a9c5
test: update test to use fixtures module
Updated the test-http2-create-client-connect tests to
use the test fixures module instead of the common
module.
PR-URL: https://github.com/nodejs/node/pull/15955
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
7 years ago
rachelnicole
bdf711dc62
test: replace fixturesDir with common.fixtures
PR-URL: https://github.com/nodejs/node/pull/16051
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
7 years ago
Saeed H
5843b2c945
test: remove messages in assert.strictEqual
PR-URL: https://github.com/nodejs/node/pull/16014
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Ruxandra Fediuc
09d8b3576f
test: improve coverage for 'internal/errors'
PR-URL: https://github.com/nodejs/node/pull/16055
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
7 years ago
bitandbang
d56f03caeb
test: update fixturesDir to fixtures.readKey
PR-URL: https://github.com/nodejs/node/pull/16016
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Refael Ackermann <refack@gmail.com>
7 years ago
Paul Berry
6e1948ea06
test: replace fixturesDir with common.fixtures
PR-URL: https://github.com/nodejs/node/pull/15973
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Pooya Paridel
d2c0978831
test: replace fixturesDir with common.fixtures
PR-URL: https://github.com/nodejs/node/pull/15837
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
7 years ago
James M. Greene
1c97fa76f3
test: update 'fixturesDir' refs in a test file
This was a task from Code & Learn at NINA17.
PR-URL: https://github.com/nodejs/node/pull/15824
Reviewed-By: Ryan Graham <r.m.graham@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Jonathan Eskew
ee587f39ae
test: add tests of querystring benchmark
PR-URL: https://github.com/nodejs/node/pull/16052
Reviewed-By: Evan Lucas <evanlucas@me.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
7 years ago
Chowdhurian
e14fd570fd
test: replace common.fixturesDir in test-exception
Replace common.fixturesDir with usage of the common.fixtures module in
text-exception.js
PR-URL: https://github.com/nodejs/node/pull/15964
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
7 years ago
Greg Byram
d36433e1b6
test: use fixtures.readKey in https-agent test
PR-URL: https://github.com/nodejs/node/pull/15913
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
7 years ago
Bruce Fletcher
baa156f39d
test: add common.fixtures to https-req-split
Replaced readFileSync with fixtures.readKey.
PR-URL: https://github.com/nodejs/node/pull/15801
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
7 years ago
Trivikram Kamat
fabd618eef
test: http2 stored settings returned when present
Refs: #14985
PR-URL: https://github.com/nodejs/node/pull/15751
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
7 years ago
Timothy Gu
3aea4c884b
src: fix ^ in stack trace with vm's columnOffset
While VM module's columnOffset option does succeed in applying an offset
to the column number in the stack trace, the wavy diagram printed does
not account for potential offsets, resulting in erroneous location of
`^` in the first line of the script.
Before:
```
> vm.runInThisContext('throw new Error()', { columnOffset: 5 })
evalmachine.<anonymous>:1
throw new Error()
^
Error
at evalmachine.<anonymous>:1:12
at ContextifyScript.Script.runInThisContext (vm.js:44:33)
at Object.runInThisContext (vm.js:116:38)
```
After:
```
> vm.runInThisContext('throw new Error()', { columnOffset: 5 })
evalmachine.<anonymous>:1
throw new Error()
^
Error
at evalmachine.<anonymous>:1:12
at ContextifyScript.Script.runInThisContext (vm.js:50:33)
at Object.runInThisContext (vm.js:139:38)
at repl:1:4
```
PR-URL: https://github.com/nodejs/node/pull/15771
Refs: https://github.com/tmpvar/jsdom/pull/2003
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
7 years ago
Trivikram Kamat
d6031bc1c6
test: http2 client destroy tests in one file
Refs: #14985
PR-URL: https://github.com/nodejs/node/pull/15749
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
7 years ago
Anatoli Papirovski
2da7d9b820
http2: near full http1 compatibility, add tests
Extensive re-work of http1 compatibility layer based on tests in
express, on-finished and finalhandler. Fix handling of HEAD
method to match http1. Adjust write, end, etc. to call writeHead
as in http1 and as expected by user-land modules. Add socket
proxy that instead uses the Http2Stream for the vast majority of
socket interactions. Add and change tests to closer represent
http1 behaviour.
Refs: https://github.com/nodejs/node/pull/15633
Refs: https://github.com/expressjs/express/tree/master/test
Refs: https://github.com/jshttp/on-finished/blob/master/test/test.js
Refs: https://github.com/pillarjs/finalhandler/blob/master/test/test.js
PR-URL: https://github.com/nodejs/node/pull/15702
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
7 years ago
Rich Trott
ad652afbe3
test: fix flaky async-hooks/test-tlswrap
There is a race condition in async-hooks/test-tlswrap. This addresses it
by waiting 5 more ticks if the client has not been destroyed yet.
PR-URL: https://github.com/nodejs/node/pull/15744
Fixes: https://github.com/nodejs/node/issues/14404
Reviewed-By: Refael Ackermann <refack@gmail.com>
7 years ago