Skip to content

Commit 5666348

Browse files
committed
fix e2e
1 parent f4fbb11 commit 5666348

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

apps/remix-ide-e2e/src/tests/terminal.test.ts

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -373,7 +373,7 @@ module.exports = {
373373
function addr(bytes32 node) public virtual view returns (address);
374374
}
375375
376-
function resolve() public view returns(address) {
376+
function resolveENS() view {
377377
// Same address for Mainet, Ropsten, Rinkerby, Gorli and other networks;
378378
ENS ens = ENS(0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e);
379379
(,bytes32 node) = NameEncoder.dnsEncodeName("vitalik.eth");
@@ -382,14 +382,19 @@ module.exports = {
382382
}
383383
`
384384
browser
385+
.clickLaunchIcon('udapp')
386+
.switchEnvironment('vm-mainnet-fork')
387+
.clickLaunchIcon('filePanel')
385388
.addFile('test_mainnet.sol', { content: script })
386-
.scrollToLine(15)
387-
const path = "//*[@class='view-line' and contains(.,'resolve') and contains(.,'view')]//span//span[contains(.,'(')]"
388-
const pathRunFunction = `//li//*[@aria-label='Run the free function "resolve"']`
389-
browser.waitForElementVisible('#editorView')
389+
390+
const path = "//*[@class='view-line' and contains(.,'resolveENS') and contains(.,'view')]//span//span[contains(.,'(')]"
391+
const pathRunFunction = `//li//*[@aria-label='Run the free function "resolveENS"']`
392+
browser.waitForElementVisible('#editorView')
393+
//.waitForElementPresent(pathRunFunction)
394+
.pause(10000) // the parser need to parse the code
390395
.useXpath()
396+
.scrollToLine(16)
391397
.click(path)
392-
.pause(3000) // the parser need to parse the code
393398
.perform(function () {
394399
const actions = this.actions({ async: true });
395400
return actions

0 commit comments

Comments
 (0)