Skip to content

Commit

Permalink
Merge a390d8e into 15ad6c1
Browse files Browse the repository at this point in the history
  • Loading branch information
oleg-mtr committed Aug 10, 2019
2 parents 15ad6c1 + a390d8e commit fe9ec1d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ let cssSpy = new RequestSpy('**/*.css');
let responseFaker = new ResponseFaker('**/*.jpg', someFakeResponse);

let requestInterceptor = new RequestInterceptor(minimatch);
responseFaker.addFaker(responseFaker);
requestInterceptor.addFaker(responseFaker);
requestInterceptor.addSpy(cssSpy);
requestInterceptor.block('**/*.js');

Expand All @@ -98,7 +98,7 @@ await page.goto('https://www.example.com');

assert.ok(cssSpy.hasMatch() && cssSpy.getMatchCount() > 0);
for (let matchedRequest of cssSpy.getMatchedRequests()) {
assert.ok(match.response().status() === 200);
assert.ok(matchedRequest.response().status() === 200);
}
```
## API
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "puppeteer-request-spy",
"version": "1.3.0",
"version": "1.3.1",
"description": "watch, fake or block requests from puppeteer matching patterns",
"main": "build/src/index.js",
"scripts": {
Expand Down

0 comments on commit fe9ec1d

Please sign in to comment.