remix-project mirror
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
remix-project/apps/remixdesktop/test/tests/app/git.test.ts

28 lines
1.1 KiB

9 months ago
import { NightwatchBrowser } from 'nightwatch'
module.exports = {
7 months ago
'@isogit': true,
9 months ago
before: function (browser: NightwatchBrowser, done: VoidFunction) {
done()
},
'clone a repo': function (browser: NightwatchBrowser) {
browser
.waitForElementVisible('*[data-id="remixIdeIconPanel"]', 10000)
.waitForElementVisible('button[data-id="landingPageImportFromGit"]')
.click('button[data-id="landingPageImportFromGit"]')
.pause(1000)
.waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]')
.click('[data-id="fileSystemModalDialogModalBody-react"]')
.waitForElementVisible('[data-id="modalDialogCustomPromptTextClone"]')
.setValue('[data-id="modalDialogCustomPromptTextClone"]', 'https://github.com/ethereum/awesome-remix')
.click('[data-id="fileSystem-modal-footer-ok-react"]')
.pause(3000)
.windowHandles(function (result) {
console.log(result.value)
browser.switchWindow(result.value[1])
.waitForElementVisible('*[data-id="treeViewLitreeViewItem.git"]')
})
.end()
}
}