1
0
mirror of https://github.com/actions/labeler synced 2026-05-10 23:51:03 +02:00
This commit is contained in:
David Kale
2020-09-08 13:25:36 -04:00
parent e4246d2b5b
commit 91fcbb0108
4227 changed files with 416837 additions and 457884 deletions

View File

@@ -1,8 +1,6 @@
MIT License
For Jest software
Copyright (c) 2014-present, Facebook, Inc.
Copyright (c) Facebook, Inc. and its affiliates.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

View File

@@ -12,11 +12,11 @@ let reference = {};
const detector = new LeakDetector(reference);
// Reference is held in memory.
console.log(detector.isLeaked()); // true
console.log(detector.isLeaking()); // true
// We destroy the only reference to the object.
reference = null;
// Reference is gone.
console.log(detector.isLeaked()); // false
console.log(detector.isLeaking()); // false
```

View File

@@ -9,6 +9,5 @@ export default class {
constructor(value: unknown);
isLeaking(): boolean;
private _runGarbageCollector;
private _isPrimitive;
}
//# sourceMappingURL=index.d.ts.map

View File

@@ -1 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAMH,MAAM,CAAC,OAAO;IACZ,OAAO,CAAC,qBAAqB,CAAU;gBAE3B,KAAK,EAAE,OAAO;IAiC1B,SAAS,IAAI,OAAO;IAMpB,OAAO,CAAC,oBAAoB;IAa5B,OAAO,CAAC,YAAY;CAGrB"}
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAOH,MAAM,CAAC,OAAO;IACZ,OAAO,CAAC,qBAAqB,CAAU;gBAE3B,KAAK,EAAE,OAAO;IAiC1B,SAAS,IAAI,OAAO;IAMpB,OAAO,CAAC,oBAAoB;CAY7B"}

View File

@@ -35,6 +35,16 @@ function _prettyFormat() {
return data;
}
function _jestGetType() {
const data = require('jest-get-type');
_jestGetType = function _jestGetType() {
return data;
};
return data;
}
function _interopRequireDefault(obj) {
return obj && obj.__esModule ? obj : {default: obj};
}
@@ -57,7 +67,7 @@ class _default {
constructor(value) {
_defineProperty(this, '_isReferenceBeingHeld', void 0);
if (this._isPrimitive(value)) {
if ((0, _jestGetType().isPrimitive)(value)) {
throw new TypeError(
[
'Primitives cannot leak memory.',
@@ -109,10 +119,6 @@ class _default {
_v().default.setFlagsFromString('--no-expose-gc');
}
}
_isPrimitive(value) {
return value !== Object(value);
}
}
exports.default = _default;

View File

@@ -1,39 +1,36 @@
{
"_args": [
[
"jest-leak-detector@24.8.0",
"/Users/pjquirk/Source/GitHub/actions/labeler"
]
],
"_development": true,
"_from": "jest-leak-detector@24.8.0",
"_id": "jest-leak-detector@24.8.0",
"_from": "jest-leak-detector@^24.9.0",
"_id": "jest-leak-detector@24.9.0",
"_inBundle": false,
"_integrity": "sha512-cG0yRSK8A831LN8lIHxI3AblB40uhv0z+SsQdW3GoMMVcK+sJwrIIyax5tu3eHHNJ8Fu6IMDpnLda2jhn2pD/g==",
"_integrity": "sha512-tYkFIDsiKTGwb2FG1w8hX9V0aUb2ot8zY/2nFg087dUageonw1zrLMP4W6zsRO59dPkTSKie+D4rhMuP9nRmrA==",
"_location": "/jest-leak-detector",
"_phantomChildren": {},
"_requested": {
"type": "version",
"type": "range",
"registry": true,
"raw": "jest-leak-detector@24.8.0",
"raw": "jest-leak-detector@^24.9.0",
"name": "jest-leak-detector",
"escapedName": "jest-leak-detector",
"rawSpec": "24.8.0",
"rawSpec": "^24.9.0",
"saveSpec": null,
"fetchSpec": "24.8.0"
"fetchSpec": "^24.9.0"
},
"_requiredBy": [
"/jest-runner"
],
"_resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-24.8.0.tgz",
"_spec": "24.8.0",
"_where": "/Users/pjquirk/Source/GitHub/actions/labeler",
"_resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-24.9.0.tgz",
"_shasum": "b665dea7c77100c5c4f7dfcb153b65cf07dcf96a",
"_spec": "jest-leak-detector@^24.9.0",
"_where": "/Users/dakale/dev/GitHub/actions/labeler/node_modules/jest-runner",
"bugs": {
"url": "https://github.com/facebook/jest/issues"
},
"bundleDependencies": false,
"dependencies": {
"pretty-format": "^24.8.0"
"jest-get-type": "^24.9.0",
"pretty-format": "^24.9.0"
},
"deprecated": false,
"description": "Module for verifying whether an object has been garbage collected or not.",
"devDependencies": {
"@types/weak": "^1.0.0",
@@ -42,7 +39,7 @@
"engines": {
"node": ">= 6"
},
"gitHead": "845728f24b3ef41e450595c384e9b5c9fdf248a4",
"gitHead": "9ad0f4bc6b8bdd94989804226c28c9960d9da7d1",
"homepage": "https://github.com/facebook/jest#readme",
"license": "MIT",
"main": "build/index.js",
@@ -56,5 +53,5 @@
"directory": "packages/jest-leak-detector"
},
"types": "build/index.d.ts",
"version": "24.8.0"
"version": "24.9.0"
}

View File

@@ -1,10 +0,0 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"rootDir": "src",
"outDir": "build"
},
"references": [
{"path": "../pretty-format"}
]
}

File diff suppressed because it is too large Load Diff