Commit 020a0c35 authored by ioedeveloper's avatar ioedeveloper

execute click command in e2e

parent 7110cac0
...@@ -104,8 +104,7 @@ module.exports = { ...@@ -104,8 +104,7 @@ module.exports = {
.waitForElementVisible('*[data-id="fileExplorerNewFilepublishToGist"]') .waitForElementVisible('*[data-id="fileExplorerNewFilepublishToGist"]')
.click('*[data-id="fileExplorerNewFilepublishToGist"]') .click('*[data-id="fileExplorerNewFilepublishToGist"]')
.waitForElementVisible('[data-id="fileSystemModalDialogModalFooter-react"] .modal-ok') .waitForElementVisible('[data-id="fileSystemModalDialogModalFooter-react"] .modal-ok')
.click('[data-id="fileSystemModalDialogModalFooter-react"]') // focus on footer to ensure ok click .execute(function () { (document.querySelector('[data-id="fileSystemModalDialogModalFooter-react"] .modal-ok') as HTMLElement).click() })
.click('[data-id="fileSystemModalDialogModalFooter-react"] .modal-ok')
.pause(10000) .pause(10000)
.perform((done) => { .perform((done) => {
browser.getText('[data-id="fileSystemModalDialogModalBody-react"]', (result) => { browser.getText('[data-id="fileSystemModalDialogModalBody-react"]', (result) => {
......
...@@ -166,7 +166,7 @@ module.exports = { ...@@ -166,7 +166,7 @@ module.exports = {
// eslint-disable-next-line dot-notation // eslint-disable-next-line dot-notation
.execute(function () { document.querySelector('*[data-id="modalDialogCustomPromptTextCreate"]')['value'] = 'workspace_new' }) .execute(function () { document.querySelector('*[data-id="modalDialogCustomPromptTextCreate"]')['value'] = 'workspace_new' })
.waitForElementVisible('*[data-id="fileSystem-modal-footer-ok-react"]') .waitForElementVisible('*[data-id="fileSystem-modal-footer-ok-react"]')
.click('*[data-id="fileSystem-modal-footer-ok-react"]') .execute(function () { (document.querySelector('[data-id="fileSystem-modal-footer-ok-react"]') as HTMLElement).click() })
.waitForElementPresent('*[data-id="workspacesSelect"] option[value="workspace_new"]') .waitForElementPresent('*[data-id="workspacesSelect"] option[value="workspace_new"]')
// end of creating // end of creating
.clickLaunchIcon('solidityUnitTesting') .clickLaunchIcon('solidityUnitTesting')
...@@ -201,7 +201,6 @@ module.exports = { ...@@ -201,7 +201,6 @@ module.exports = {
if (runtimeBrowser !== 'chrome') { if (runtimeBrowser !== 'chrome') {
browser.clickLaunchIcon('filePanel') browser.clickLaunchIcon('filePanel')
.waitForElementVisible('[data-id="treeViewLitreeViewItemtests"]') .waitForElementVisible('[data-id="treeViewLitreeViewItemtests"]')
.click('[data-id="treeViewLitreeViewItemtests"]')
} }
done() done()
}) })
......
...@@ -68,7 +68,7 @@ module.exports = { ...@@ -68,7 +68,7 @@ module.exports = {
// eslint-disable-next-line dot-notation // eslint-disable-next-line dot-notation
.execute(function () { document.querySelector('*[data-id="modalDialogCustomPromptTextRename"]')['value'] = 'workspace_name_renamed' }) .execute(function () { document.querySelector('*[data-id="modalDialogCustomPromptTextRename"]')['value'] = 'workspace_name_renamed' })
.waitForElementPresent('[data-id="fileSystemModalDialogModalFooter-react"] .modal-ok') .waitForElementPresent('[data-id="fileSystemModalDialogModalFooter-react"] .modal-ok')
.click('[data-id="fileSystemModalDialogModalFooter-react"] .modal-ok') .execute(function () { (document.querySelector('[data-id="fileSystemModalDialogModalFooter-react"] .modal-ok') as HTMLElement).click() })
.waitForElementPresent('*[data-id="workspacesSelect"] option[value="workspace_name_1"]') .waitForElementPresent('*[data-id="workspacesSelect"] option[value="workspace_name_1"]')
.click('*[data-id="workspacesSelect"] option[value="workspace_name_1"]') .click('*[data-id="workspacesSelect"] option[value="workspace_name_1"]')
.pause(2000) .pause(2000)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment