Comparing version 13.4.0 to 13.5.0
@@ -289,2 +289,6 @@ 'use strict' | ||
} | ||
clone() { | ||
return new Scope(this.basePath, this.scopeOptions) | ||
} | ||
} | ||
@@ -291,0 +295,0 @@ |
@@ -10,3 +10,3 @@ { | ||
], | ||
"version": "13.4.0", | ||
"version": "13.5.0", | ||
"author": "Pedro Teixeira <pedro.teixeira@gmail.com>", | ||
@@ -48,3 +48,3 @@ "repository": { | ||
"nyc": "^15.0.0", | ||
"prettier": "3.0.3", | ||
"prettier": "3.1.0", | ||
"proxyquire": "^2.1.0", | ||
@@ -51,0 +51,0 @@ "rimraf": "^3.0.0", |
@@ -1069,2 +1069,13 @@ # Nock | ||
### .clone() | ||
You can clone a scope by calling `.clone()` on it: | ||
```js | ||
const scope = nock('http://example.test') | ||
const getScope = scope.get('/').reply(200) | ||
const postScope = scope.clone().post('/').reply(200) | ||
``` | ||
## Restoring | ||
@@ -1071,0 +1082,0 @@ |
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
185782
3616
1726