|
|
|
@ -19,16 +19,17 @@ module.exports = { |
|
|
|
|
}, |
|
|
|
|
'Should load the test file #group1': function (browser: NightwatchBrowser) { |
|
|
|
|
browser.openFile('contracts') |
|
|
|
|
.openFile('contracts/3_Ballot.sol') |
|
|
|
|
.waitForElementVisible('#editorView') |
|
|
|
|
.setEditorValue(BallotWithARefToOwner) |
|
|
|
|
.pause(4000) // wait for the compiler to finish
|
|
|
|
|
.addFile('contracts/3_BallotHover.sol', { |
|
|
|
|
content: BallotWithARefToOwner |
|
|
|
|
}) |
|
|
|
|
.scrollToLine(37) |
|
|
|
|
.useXpath().waitForElementVisible("//*[@class='view-line' and contains(.,'gas')]") |
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
'Should show hover over contract in editor #group1 #flaky': function (browser: NightwatchBrowser) { |
|
|
|
|
const path = "//*[contains(text(),'BallotHoverTest')]" |
|
|
|
|
checkEditorHoverContent(browser, path, 'contract BallotHoverTest is BallotHoverTest') |
|
|
|
|
checkEditorHoverContent(browser, path, 'contracts/3_Ballot.sol 10:0') |
|
|
|
|
checkEditorHoverContent(browser, path, 'contracts/3_BallotHover.sol 10:0') |
|
|
|
|
checkEditorHoverContent(browser, path, '@title Ballot') |
|
|
|
|
}, |
|
|
|
|
'Should show hover over var definition in editor #group1': function (browser: NightwatchBrowser) { |
|
|
|
@ -103,8 +104,12 @@ module.exports = { |
|
|
|
|
const expectedContent = 'contract ERC20Burnable is ERC20Burnable, ERC20, IERC20Errors, IERC20Metadata, IERC20, Context' |
|
|
|
|
checkEditorHoverContent(browser, path, expectedContent, 25) |
|
|
|
|
}, |
|
|
|
|
'Go back to ballot file': function (browser: NightwatchBrowser) { |
|
|
|
|
browser.openFile('contracts/3_Ballot.sol') |
|
|
|
|
'Go back to ballot file #group1': function (browser: NightwatchBrowser) { |
|
|
|
|
browser |
|
|
|
|
.waitForElementVisible('*[data-id="treeViewDivDraggableItem.deps"]') |
|
|
|
|
.click('*[data-id="treeViewDivDraggableItem.deps"]') |
|
|
|
|
.openFile('contracts/3_BallotHover.sol') |
|
|
|
|
.scrollToLine(37) |
|
|
|
|
.useXpath().waitForElementVisible("//*[@class='view-line' and contains(.,'gas')]") |
|
|
|
|
}, |
|
|
|
|
'Should show hover over function in editor again #group1': function (browser: NightwatchBrowser) { |
|
|
|
|