Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
afterEach(function () {
process.env.PATH = this.PATH;
delete process.env.DETECT_TEST_PATH;
delete process.env.DETECT_TEST_PATH2;
temp.cleanupSync();
});
function testCleanupSync() {
const cleanupResult: boolean | temp.Stats = temp.cleanupSync();
if (typeof cleanupResult === "boolean") {
const x = cleanupResult;
} else {
const { dirs, files } = cleanupResult;
dirs.toPrecision(4);
files.toPrecision(4);
}
}
afterEach(function () {
temp.cleanupSync()
})
afterEach(() => {
temp.cleanupSync()
})