{
  "manifest": {
    "name": "jest-mock",
    "version": "27.5.1",
    "repository": {
      "type": "git",
      "url": "https://github.com/facebook/jest.git",
      "directory": "packages/jest-mock"
    },
    "engines": {
      "node": "^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0"
    },
    "dependencies": {
      "@jest/types": "^27.5.1",
      "@types/node": "*"
    },
    "license": "MIT",
    "main": "./build/index.js",
    "types": "./build/index.d.ts",
    "exports": {
      ".": {
        "types": "./build/index.d.ts",
        "default": "./build/index.js"
      },
      "./package.json": "./package.json"
    },
    "publishConfig": {
      "access": "public"
    },
    "gitHead": "67c1aa20c5fec31366d733e901fee2b981cb1850",
    "_registry": "npm",
    "_loc": "/homez.1033/heliovt/.cache/yarn/v6/npm-jest-mock-27.5.1-19948336d49ef4d9c52021d34ac7b5f36ff967d6-integrity/node_modules/jest-mock/package.json",
    "readmeFilename": "README.md",
    "readme": "# jest-mock\n\n## API\n\n```js\nimport {ModuleMocker} from 'jest-mock';\n```\n\n### `constructor(global)`\n\nCreates a new module mocker that generates mocks as if they were created in an environment with the given global object.\n\n### `generateFromMetadata(metadata)`\n\nGenerates a mock based on the given metadata (Metadata for the mock in the schema returned by the getMetadata method of this module). Mocks treat functions specially, and all mock functions have additional members, described in the documentation for `fn` in this module.\n\nOne important note: function prototypes are handled specially by this mocking framework. For functions with prototypes, when called as a constructor, the mock will install mocked function members on the instance. This allows different instances of the same constructor to have different values for its mocks member and its return values.\n\n### `getMetadata(component)`\n\nInspects the argument and returns its schema in the following recursive format:\n\n```\n{\n  type: ...\n  members: {}\n}\n```\n\nWhere type is one of `array`, `object`, `function`, or `ref`, and members is an optional dictionary where the keys are member names and the values are metadata objects. Function prototypes are defined by defining metadata for the `member.prototype` of the function. The type of a function prototype should always be `object`. For instance, a class might be defined like this:\n\n```js\nconst classDef = {\n  type: 'function',\n  members: {\n    staticMethod: {type: 'function'},\n    prototype: {\n      type: 'object',\n      members: {\n        instanceMethod: {type: 'function'},\n      },\n    },\n  },\n};\n```\n\nMetadata may also contain references to other objects defined within the same metadata object. The metadata for the referent must be marked with `refID` key and an arbitrary value. The referrer must be marked with a `ref` key that has the same value as object with refID that it refers to. For instance, this metadata blob:\n\n```js\nconst refID = {\n  type: 'object',\n  refID: 1,\n  members: {\n    self: {ref: 1},\n  },\n};\n```\n\ndefines an object with a slot named `self` that refers back to the object.\n\n### `fn`\n\nGenerates a stand-alone function with members that help drive unit tests or confirm expectations. Specifically, functions returned by this method have the following members:\n\n##### `.mock`\n\nAn object with three members, `calls`, `instances` and `invocationCallOrder`, which are all lists. The items in the `calls` list are the arguments with which the function was called. The \"instances\" list stores the value of 'this' for each call to the function. This is useful for retrieving instances from a constructor. The `invocationCallOrder` lists the order in which the mock was called in relation to all mock calls, starting at 1.\n\n##### `.mockReturnValueOnce(value)`\n\nPushes the given value onto a FIFO queue of return values for the function.\n\n##### `.mockReturnValue(value)`\n\nSets the default return value for the function.\n\n##### `.mockImplementationOnce(function)`\n\nPushes the given mock implementation onto a FIFO queue of mock implementations for the function.\n\n##### `.mockImplementation(function)`\n\nSets the default mock implementation for the function.\n\n##### `.mockReturnThis()`\n\nSyntactic sugar for .mockImplementation(function() {return this;})\n\nIn case both `mockImplementationOnce()/mockImplementation()` and `mockReturnValueOnce()/mockReturnValue()` are called. The priority of which to use is based on what is the last call:\n\n- if the last call is mockReturnValueOnce() or mockReturnValue(), use the specific return value or default return value. If specific return values are used up or no default return value is set, fall back to try mockImplementation();\n- if the last call is mockImplementationOnce() or mockImplementation(), run the specific implementation and return the result or run default implementation and return the result.\n",
    "description": "## API",
    "licenseText": "MIT License\n\nCopyright (c) Facebook, Inc. and its affiliates.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n"
  },
  "artifacts": [],
  "remote": {
    "resolved": "https://registry.yarnpkg.com/jest-mock/-/jest-mock-27.5.1.tgz#19948336d49ef4d9c52021d34ac7b5f36ff967d6",
    "type": "tarball",
    "reference": "https://registry.yarnpkg.com/jest-mock/-/jest-mock-27.5.1.tgz",
    "hash": "19948336d49ef4d9c52021d34ac7b5f36ff967d6",
    "integrity": "sha512-K4jKbY1d4ENhbrG2zuPWaQBvDly+iZ2yAW+T1fATN78hc0sInwn7wZB8XtlNnvHug5RMwV897Xm4LqmPM4e2Og==",
    "registry": "npm",
    "packageName": "jest-mock",
    "cacheIntegrity": "sha512-K4jKbY1d4ENhbrG2zuPWaQBvDly+iZ2yAW+T1fATN78hc0sInwn7wZB8XtlNnvHug5RMwV897Xm4LqmPM4e2Og== sha1-GZSDNtSe9NnFICHTSse182/5Z9Y="
  },
  "registry": "npm",
  "hash": "19948336d49ef4d9c52021d34ac7b5f36ff967d6"
}