e2e tests fixed

pull/5370/head
aniket-engg 3 years ago committed by Aniket
parent 28db9d829e
commit 8484fbeff0
  1. 5
      apps/remix-ide-e2e/src/tests/search.test.ts
  2. 4
      apps/remix-ide-e2e/src/tests/terminal.test.ts

@ -49,10 +49,11 @@ module.exports = {
.clearValue('*[id="search_input"]') .clearValue('*[id="search_input"]')
.setValue('*[id="search_input"]', 'Contract').pause(1000) .setValue('*[id="search_input"]', 'Contract').pause(1000)
.elements('css selector','.search_plugin_search_line', (res) => { .elements('css selector','.search_plugin_search_line', (res) => {
Array.isArray(res.value) && browser.assert.equal(res.value.length, 6) Array.isArray(res.value) && browser.assert.equal(res.value.length, 9)
}) })
.waitForElementContainsText('*[data-id="search_results"]', 'DEPLOY_ETHERS.JS', 60000) .waitForElementContainsText('*[data-id="search_results"]', 'DEPLOY_ETHERS.JS', 60000)
.waitForElementContainsText('*[data-id="search_results"]', 'DEPLOY_WEB3.JS', 60000) .waitForElementContainsText('*[data-id="search_results"]', 'DEPLOY_WEB3.JS', 60000)
.waitForElementContainsText('*[data-id="search_results"]', 'STORAGE.TEST.JS', 60000)
.waitForElementContainsText('*[data-id="search_results"]', 'scripts', 60000) .waitForElementContainsText('*[data-id="search_results"]', 'scripts', 60000)
}, },
'Should find matchword': function (browser: NightwatchBrowser) { 'Should find matchword': function (browser: NightwatchBrowser) {

@ -121,13 +121,13 @@ module.exports = {
}, },
'Run tests using Mocha script and check result logging in the terminal #group4': function (browser: NightwatchBrowser) { 'Run tests using Mocha script and check result logging in the terminal #group4': function (browser: NightwatchBrowser) {
browser browser
.addFile('scripts/storage.test.js', { content: storageMochaTests }) .addFile('scripts/storage2.test.js', { content: storageMochaTests })
.pause(1000) .pause(1000)
.openFile('contracts/1_Storage.sol') .openFile('contracts/1_Storage.sol')
.clickLaunchIcon('solidity') .clickLaunchIcon('solidity')
.click('*[data-id="compilerContainerCompileBtn"]') .click('*[data-id="compilerContainerCompileBtn"]')
.pause(1000) // compile Storage .pause(1000) // compile Storage
.executeScript('remix.execute(\'scripts/storage.test.js\')') .executeScript('remix.execute(\'scripts/storage2.test.js\')')
.pause(1000) .pause(1000)
.waitForElementContainsText('*[data-id="terminalJournal"]', 'Running tests....') .waitForElementContainsText('*[data-id="terminalJournal"]', 'Running tests....')
.waitForElementContainsText('*[data-id="terminalJournal"]', 'storage contract Address:') .waitForElementContainsText('*[data-id="terminalJournal"]', 'storage contract Address:')

Loading…
Cancel
Save