Closed adamschneider closed 5 years ago
Does this work on earlier versions of node 8? I'm trying to recommend something and node-replay looks great, but we will need to move to node 8 quite soon.
This project appears to have lost the attention of it's maintainer. There are a couple other alternatives, like: sepia, vcr, or yakbak. I haven't investigated to see if those are maintained. Sorry.
Thats a real shame, because this is a great tool.
Do you know what's wrong with the tests?
On Tue, Mar 6, 2018 at 9:48 AM, adamschneider notifications@github.com wrote:
This project appears to have lost the attention of it's maintainer. There are a couple other alternatives, like: sepia, vcr, or yakbak. I haven't investigated to see if those are maintained. Sorry.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/assaf/node-replay/issues/146#issuecomment-370805232, or mute the thread https://github.com/notifications/unsubscribe-auth/ACSGbi21CZiksazRpH8_z1rNqJxY6CGrks5tbqHOgaJpZM4SSsuT .
Gregory G. Bishop Sr. Software Engineer
3088 Downs Cove Rd. Windermere FL 34786 321-276-8588 ggb667@gmail.com
I haven't looked into this library since my initial comment.
I've recently had success using this library: https://github.com/node-nock/nock
I'm using it with Node 9.8.0, but Linux + MacOS, not tested to work in Windows.
Can someone please test this on windows?
Works for me, at commit b01018e89faa260d3663c9d07f940ad47692d316. Windows 10 Pro Version 1803 Build 17134.48.
s25g5d4@DESKTOP-1QN2Q14 MINGW32 ~/Code/node-replay (master)
$ node -v
v8.9.4
s25g5d4@DESKTOP-1QN2Q14 MINGW32 ~/Code/node-replay (master)
$ npm -v
5.8.0
s25g5d4@DESKTOP-1QN2Q14 MINGW32 ~/Code/node-replay (master)
$ npm i
> replay@2.3.0 prepare C:\Users\s25g5d4\Code\node-replay
> gulp build
[11:03:10] Using gulpfile ~\Code\node-replay\gulpfile.js
[11:03:10] Starting 'clean'...
[11:03:10] Starting 'lint'...
[11:03:11] Finished 'clean' after 1.58 s
[11:03:12] Finished 'lint' after 2.35 s
[11:03:12] Starting 'build'...
[11:03:13] gulp-notify: [Gulp notification] node-replay: built!
[11:03:13] Finished 'build' after 1.39 s
npm WARN replay@2.3.0 No license field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.3 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
added 712 packages from 815 contributors in 39.587s
s25g5d4@DESKTOP-1QN2Q14 MINGW32 ~/Code/node-replay (master)
$ npm test
> replay@2.3.0 test C:\Users\s25g5d4\Code\node-replay
> mocha
Pass through
bloody
listeners
√ should return HTTP version
√ should return status code
√ should return response trailers
√ should return response headers
√ should return response body
callback
√ should return HTTP version
√ should return status code
√ should return response headers
√ should return response trailers
√ should return response body
ssl
get
√ should return HTTP version
√ should return status code
√ should return response headers
√ should return response trailers
√ should return response body
post
√ should return status code
√ should post the body
replay
listeners
√ should callback with error
localhost
√ should pass through by default
Replay
matching URL
listeners
√ should return HTTP version
√ should return status code
√ should return response headers
√ should return response trailers
Old http status line format
√ should return HTTP version
√ should return status code
√ should return response headers
√ should return response trailers
callback
√ should return HTTP version
√ should return status code
√ should return response headers
√ should return response trailers
matching on query strings
√ should select the correct fixture
matching an https url
√ should return HTTP version
√ should return status code
matching a regexp
√ should match the right fixture
matching a regexp url with flags
√ should match a fixture
matching when changing fixtures dir
original catalog
√ should match to response in original catalog
alternative catalog
√ should match to response in original catalog
recording query parameters
√ should create a fixture per unique URL path (53ms)
recording gzipped replay
√ should create unzipped fixture for gzipped reply
recording multiple of the same header
√ should create a fixture with multiple set-cookie headers
replaying multiple headers
√ should have both set-cookie headers
recording POST data
without record response control
√ should save POST request data
with record response control
that indicates response should be recorded
√ should save POST request data
that indicates response should not be recorded
√ should not save POST request data
recording multi-line POST data
√ should save POST request data
replaying with POST body
matching
√ should return status code
replaying with multi-line POST body
matching
√ should return status code
replaying with POST body regular expression
matching
√ should return status code
not matching
√ should callback with error
only specified headers
√ should not store the accept header
undefined path
√ should callback with error
undefined host
√ should callback with error
header
matching
√ should return status code
no match
√ should fail to connnect
method
matching
√ should return status code
√ should return headers
no match
√ should fail to connnect
corrupt replay file
√ should callback with error
minimal response
listeners
√ should return HTTP version
√ should return status code
√ should return no response headers
√ should return no response trailers
√ should return no response body
64 passing (697ms)
An error occured. { Error: spawn growlnotify ENOENT
at _errnoException (util.js:1022:11)
at Process.ChildProcess._handle.onexit (internal/child_process.js:190:19)
at onErrorNT (internal/child_process.js:372:16)
at _combinedTickCallback (internal/process/next_tick.js:138:11)
at process._tickCallback (internal/process/next_tick.js:180:9)
code: 'ENOENT',
errno: 'ENOENT',
syscall: 'spawn growlnotify',
path: 'growlnotify',
spawnargs:
[ '/i:C:\\Users\\s25g5d4\\Code\\node-replay\\node_modules\\mocha\\images\\ok.png',
'64 tests passed in 697ms',
'/t:Passed' ] }
Ignore the error at the end. That's notification for test pass, and I don't have the program installed.
First off, I love this tool. However, it seems to be broken in newer versions of Node (at least on Windows). I was going to take a stab at fixing some of the breakage but I'm noticing that the tests fail with no modification. I can observe that TravisCI passes when using Node8. Has anyone attempted developing this on Windows? Am I running this correctly? Below is the output of my attempt to test the library. Thanks!