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

jest-create-mock-instance

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jest-create-mock-instance - npm Package Compare versions

Comparing version 1.1.0 to 2.0.0

8

index.js

@@ -10,3 +10,9 @@ var jestMock = require("jest-mock");

function createMockInstance(cl) {
var Mock = jestMock.generateFromMetadata(jestMock.getMetadata(cl));
var mocker = jestMock;
// jest-mock 27 doesn't export an instance of ModuleMocker anymore.
if (jestMock.ModuleMocker) {
mocker = new jestMock.ModuleMocker(global);
}
var Mock = mocker.generateFromMetadata(mocker.getMetadata(cl));
return new Mock();

@@ -13,0 +19,0 @@ }

4

package.json
{
"name": "jest-create-mock-instance",
"version": "1.1.0",
"version": "2.0.0",
"description": "Create class mock instances easily with Jest",

@@ -20,4 +20,4 @@ "main": "index.js",

"devDependencies": {
"jest": "^21.2.1"
"jest": "^27.0.0"
}
}
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