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

atom-test-runner-jest

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

atom-test-runner-jest - npm Package Compare versions

Comparing version 0.1.3 to 0.2.0

28

index.js
"use babel";
import { runCLI } from "jest-cli";
const tmp = require("tmp");
const pkgUp = require("pkg-up");
const remote = require("electron").remote;

@@ -9,20 +12,33 @@ export default ({

logFile,
testPaths
testPaths,
headless
}) => {
const cwd = pkgUp.sync(testPaths[0]);
global.atom = buildAtomEnvironment({
applicationDelegate: buildDefaultApplicationDelegate(),
window,
document: window.document,
configDirPath: process.env.ATOM_HOME,
document,
configDirPath: tmp.dirSync().name,
enablePersistence: false
});
if (headless) {
Object.defineProperties(process, {
stdout: { value: remote.process.stdout },
stderr: { value: remote.process.stderr }
});
} else {
process.on("uncaughtException", console.error.bind(console));
}
return runCLI(
{
cache: false,
cache: true,
_: testPaths,
outputFile: logFile
outputFile: logFile,
runInBand: true
},
[process.cwd()]
[cwd]
).then(resp => (resp.results.success ? 0 : 1));
};
{
"name": "atom-test-runner-jest",
"version": "0.1.3",
"version": "0.2.0",
"description": "Atom Test Runner for Jest",

@@ -24,4 +24,6 @@ "main": "index.js",

"dependencies": {
"jest-cli": "^22.0.3"
"jest-cli": "^22.0.3",
"pkg-up": "^2.0.0",
"tmp": "^0.0.33"
}
}

@@ -8,3 +8,3 @@ # atom-test-runner-jest

```
npm install atom-test-runner-jest --save-dev
npm install atom-test-runner-jest jest-preset-atom --save-dev
```

@@ -14,3 +14,3 @@

Add the following line to your `package.json`:
Add the following to your `package.json`:

@@ -20,5 +20,6 @@ ```json

"name": "my-package",
// ...
+ "atomTestRunner": "atom-test-runner-jest",
// ...
"atomTestRunner": "atom-test-runner-jest",
"jest": {
"preset": "jest-preset-atom"
}
}

@@ -25,0 +26,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