Update addFile custom command

pull/668/head
ioedeveloper 4 years ago
parent a4a6c6185c
commit b997b19f56
  1. 8
      apps/remix-ide-e2e/src/commands/addFile.ts

@ -18,10 +18,10 @@ function addFile (browser: NightwatchBrowser, name: string, content: NightwatchC
.clickLaunchIcon('fileExplorers')
.click('li[data-id="treeViewLitreeViewItembrowser/README.txt"]') // focus on root directory
.click('.newFile')
.waitForElementVisible('[data-id="treeViewLitreeViewItembrowser/blank"] .remixui_items')
.click('[data-id="treeViewLitreeViewItembrowser/blank"] .remixui_items')
.sendKeys('[data-id="treeViewLitreeViewItembrowser/blank"] .remixui_items', name)
.sendKeys('[data-id="treeViewLitreeViewItembrowser/blank"] .remixui_items', browser.Keys.ENTER)
.waitForElementVisible('*[data-id="treeViewLitreeViewItembrowser/blank"]')
.click('*[data-id="treeViewLitreeViewItembrowser/blank"] .remixui_items')
.sendKeys('*[data-id="treeViewLitreeViewItembrowser/blank"] .remixui_items', name)
.sendKeys('*[data-id="treeViewLitreeViewItembrowser/blank"] .remixui_items', browser.Keys.ENTER)
.pause(2000)
.waitForElementVisible(`li[data-id="treeViewLitreeViewItembrowser/${name}"]`)
.click(`li[data-id="treeViewLitreeViewItembrowser/${name}"]`)

Loading…
Cancel
Save