Skip to content

Instantly share code, notes, and snippets.

@muryoimpl
Last active August 5, 2020 04:39
Show Gist options
  • Save muryoimpl/a58824ebbfadee1c788b to your computer and use it in GitHub Desktop.
Save muryoimpl/a58824ebbfadee1c788b to your computer and use it in GitHub Desktop.
A configuration file of protractor for my Electron App
/*global browser*/
require('babel-register')({
presets: ['es2015', 'stage-0', 'stage-1', 'react'],
plugins: ['babel-plugin-espower'],
only: /e2e/,
extensions: ['.js']
});
exports.config = {
chromeDriver: './node_modules/protractor/selenium/chromedriver',
seleniumAddress: 'http://localhost:4444/wd/hub',
framework: 'mocha',
directConnect: true,
specs: [
'test/e2e/*.e2e.js'
],
capabilities: {
browserName: 'chrome',
platform: 'LINUX',
chromeOptions: {
binary: './node_modules/electron-prebuilt/dist/electron',
args: ['--test-type=webdriver', 'app=main.js']
}
},
onPrepare: function() {
browser.ignoreSynchronization = true; //not Angular な環境で protractor が使える
browser.resetUrl = 'file://';
},
mochaOpts: {
ui: '',
reporter: 'list',
slow: 3000,
enableTimeouts: false
}
};
@MoniRaj1
Copy link

MoniRaj1 commented Aug 5, 2020

Hi ,

I m looking for a similar solution as above.

We are trying to automate a electronjs desktop application using protractor , any help would be great.

Thanks,
Monica

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment