Open diegohaz opened 8 years ago
I solve this by adding the following line before using nock
:
nock.restore() && nock.isActive() || nock.activate()
I reopened because maybe there's a better solution to be implemented inside nock-vcr-recorder. I've also submitted an issue on nock repo: https://github.com/node-nock/nock/issues/666
I'm using nock-vcr-recorder and nock on different test suites, but in the same execution. The first time nock-vcr-recorder runs (or has
{ mode: 'all' }
), subsequentnock('...')
fails. It seems like something has not been closed at the first vcr run and it doesn't allow nock to work.