Eclipse Theia is a framework for building IDE. After extending the Theia framework, one can package the distribution as an Electron App. The current version of Electron that is used is 9.3.2. I am trying to use Spectron version 11.0.0 to test Eclipse Theia. My test script is shown below:
var Application = require('spectron').Application
var assert = require('assert')
var app = new Application({
path: '/home/karan/test-ide/electron-app/dist/Test IDE-0.0.1.AppImage',
webdriverOptions: ({deprecationWarnings : false})
});
app.start().then(function () {
// Check if the window is visible
console.log("In func Start")
debugger;
return app.browserWindow.isVisible()
}).then(function (isVisible) {
// Verify the window is visible
console.log("Window visible")
debugger;
assert.equal(isVisible, true)
}).then(function () {
// Get the window's title
console.log("Windows Title")
debugger;
return app.client.getTitle()
}).then(function (title) {
// Verify the window's title
assert.equal(title, 'My App')
debugger;
}).then(function () {
// Stop the application
console.log("App Stop")
debugger;
return app.stop()
}).catch(function (error) {
// Log any failures
console.error('Test failed', error.message)
})
Once I execute the test script Spectron is not able to launch Eclipse Theia.
Please suggest what I am missing ?
Eclipse Theia is a framework for building IDE. After extending the Theia framework, one can package the distribution as an Electron App. The current version of Electron that is used is 9.3.2. I am trying to use Spectron version 11.0.0 to test Eclipse Theia. My test script is shown below:
var Application = require('spectron').Application var assert = require('assert')
var app = new Application({ path: '/home/karan/test-ide/electron-app/dist/Test IDE-0.0.1.AppImage', webdriverOptions: ({deprecationWarnings : false}) });
app.start().then(function () { // Check if the window is visible console.log("In func Start") debugger; return app.browserWindow.isVisible() }).then(function (isVisible) { // Verify the window is visible console.log("Window visible") debugger; assert.equal(isVisible, true) }).then(function () { // Get the window's title console.log("Windows Title") debugger; return app.client.getTitle() }).then(function (title) { // Verify the window's title assert.equal(title, 'My App') debugger; }).then(function () { // Stop the application console.log("App Stop") debugger; return app.stop() }).catch(function (error) { // Log any failures console.error('Test failed', error.message) })
Once I execute the test script Spectron is not able to launch Eclipse Theia. Please suggest what I am missing ?