fetch-mock
Advanced tools
Comparing version 3.1.2 to 3.1.3
{ | ||
"name": "fetch-mock", | ||
"version": "3.1.2", | ||
"version": "3.1.3", | ||
"description": "Mock http requests made using fetch (or isomorphic-fetch)", | ||
@@ -5,0 +5,0 @@ "main": "src/server.js", |
@@ -77,11 +77,11 @@ # fetch-mock [![Build Status](https://travis-ci.org/wheresrhys/fetch-mock.svg?branch=master)](https://travis-ci.org/wheresrhys/fetch-mock) | ||
``` | ||
responses: { | ||
session: function (url, opts) { | ||
if (opts.headers.authorized) { | ||
return {user: 'dummy-authorized-user'}; | ||
} else { | ||
return {user: 'dummy-unauthorized-user'}; | ||
responses: { | ||
session: function (url, opts) { | ||
if (opts.headers.Authorization) { | ||
return {user: 'dummy-authorized-user'}; | ||
} else { | ||
return {user: 'dummy-unauthorized-user'}; | ||
} | ||
} | ||
} | ||
} | ||
} | ||
``` | ||
@@ -88,0 +88,0 @@ * `greed`: Determines how the mock handles unmatched requests |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
77727