You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given this project is based on Nock, I supposed that it handled RegExp for specifying paths as Nock does.
I tested using the code provided in the README.md with some changes to match a path using a RegExp. Here follows
consthttp=require('http')consthock=require('hock')constrequest=require('request')constmock=hock.createHock()mock.get(/source$/).reply(200,'Hello!')constserver=http.createServer(mock.handler)server.listen(1337,function(){console.log('Hock server listening at http://localhost:1337')})process.on('uncaughtException',(err)=>{console.log('Whoops! There was an uncaught error\n',err)})
When accessing http://localhost:1337/source I get an error for a non-matching route. Do you have any plan to support RegExp as Nock does?
The text was updated successfully, but these errors were encountered:
Given this project is based on Nock, I supposed that it handled RegExp for specifying paths as Nock does.
I tested using the code provided in the README.md with some changes to match a path using a RegExp. Here follows
When accessing http://localhost:1337/source I get an error for a non-matching route. Do you have any plan to support RegExp as Nock does?
The text was updated successfully, but these errors were encountered: