ref/ set default angular eslint rules
This commit is contained in:
@@ -1,14 +1,14 @@
|
||||
const Application = require('spectron').Application;
|
||||
const electronPath = require('electron'); // Require Electron from the binaries included in node_modules.
|
||||
const path = require('path');
|
||||
const APPLICATION = require('spectron').Application;
|
||||
const ELECTRON_PATH = require('electron'); // Require Electron from the binaries included in node_modules.
|
||||
const PATH = require('path');
|
||||
|
||||
export default function setup(): void {
|
||||
beforeEach(async function () {
|
||||
this.app = new Application({
|
||||
beforeEach(async () => {
|
||||
this.app = new APPLICATION({
|
||||
// Your electron path can be any binary
|
||||
// i.e for OSX an example path could be '/Applications/MyApp.app/Contents/MacOS/MyApp'
|
||||
// But for the sake of the example we fetch it from our node_modules.
|
||||
path: electronPath,
|
||||
path: ELECTRON_PATH,
|
||||
|
||||
// Assuming you have the following directory structure
|
||||
|
||||
@@ -23,14 +23,14 @@ export default function setup(): void {
|
||||
|
||||
// The following line tells spectron to look and use the main.js file
|
||||
// and the package.json located 1 level above.
|
||||
args: [path.join(__dirname, '..')],
|
||||
args: [PATH.join(__dirname, '..')],
|
||||
webdriverOptions: {}
|
||||
});
|
||||
|
||||
await this.app.start();
|
||||
});
|
||||
|
||||
afterEach(async function () {
|
||||
afterEach(async () => {
|
||||
if (this.app && this.app.isRunning()) {
|
||||
await this.app.stop();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user