Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

playwright-msw

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

playwright-msw - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

9

CHANGELOG.md

@@ -5,2 +5,11 @@ # Changelog

## [1.0.4](https://github.com/valendres/playwright-msw/compare/playwright-msw@1.0.3...playwright-msw@1.0.4) "playwright-msw" (2022-11-05)<a name="1.0.4"></a>
### Bug Fixes
* internal cookie storage isn't reset on test teardown (#30) ([8ed4504](https://github.com/valendres/playwright-msw/commits/8ed4504))
## [1.0.3](https://github.com/valendres/playwright-msw/compare/playwright-msw@1.0.2...playwright-msw@1.0.3) "playwright-msw" (2022-10-28)<a name="1.0.3"></a>

@@ -7,0 +16,0 @@

1

lib/fixture.js

@@ -18,2 +18,3 @@ "use strict";

yield use(server);
server.resetCookieStore();
}),

@@ -20,0 +21,0 @@ {

@@ -17,2 +17,3 @@ "use strict";

const msw_1 = require("msw");
const cookies_1 = require("@mswjs/cookies");
const events_1 = __importDefault(require("events"));

@@ -73,4 +74,7 @@ const emitter = new events_1.default();

}),
resetCookieStore: () => {
cookies_1.store.clear();
},
};
});
exports.createServer = createServer;

@@ -5,2 +5,3 @@ import { RequestHandler } from "msw";

resetHandlers: (...customHandlers: RequestHandler[]) => Promise<void>;
resetCookieStore: () => void;
};

13

package.json
{
"name": "playwright-msw",
"version": "1.0.3",
"version": "1.0.4",
"description": "A Mock Service Worker API for Playwright.",

@@ -24,3 +24,4 @@ "main": "lib/index.js",

"clean": "rimraf lib",
"prepack": "yarn clean && yarn build"
"prepack": "yarn clean && yarn build",
"test": "jest"
},

@@ -31,10 +32,16 @@ "peerDependencies": {

},
"dependencies": {
"@mswjs/cookies": "^0.2.2"
},
"devDependencies": {
"@playwright/test": "^1.26.1",
"@playwright/test": "^1.27.1",
"@types/jest": "^29.2.0",
"@types/node": "^18.8.2",
"@types/rimraf": "^3.0.2",
"jest": "^29.2.2",
"msw": "0.47.4",
"rimraf": "^3.0.2",
"ts-jest": "^29.0.3",
"typescript": "4.7.4"
}
}

@@ -184,1 +184,2 @@ <h1 align="center">Playwright MSW</h1>

- `resetHandlers(...customHandlers: RequestHandler[])`: Resets request handlers to the initial list given to the createServer call, or to the explicit next request handlers list, if given.
- `resetCookieStore()`: Resets MSW's internal cookie store by removing all cookies from it.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc