updated the warning msg

e2e
pull/3380/head
lianahus 2 years ago
parent b7f3e227b9
commit 2015846858
  1. 2
      apps/remix-ide-e2e/src/tests/workspace.test.ts
  2. 40
      apps/remix-ide-e2e/src/tests/workspace_git.test.ts
  3. 2
      apps/remix-ide/src/app/tabs/locales/en/filePanel.json
  4. 2
      apps/remix-ide/src/app/tabs/locales/zh/filePanel.json
  5. 4
      libs/remix-ui/helper/src/lib/components/custom-dropdown.tsx

@ -410,7 +410,7 @@ module.exports = {
browser browser
.useXpath() .useXpath()
.waitForElementPresent({ .waitForElementPresent({
selector: '//i[@data-icon="workspaceDropdownMenuIcon"]', selector: '//i[@data-id="workspaceDropdownMenuIcon"]',
locateStrategy: 'xpath', locateStrategy: 'xpath',
}) })
.click('//*[@id="workspacesMenuDropdown"]/span/i') .click('//*[@id="workspacesMenuDropdown"]/span/i')

@ -58,18 +58,16 @@ module.exports = {
.waitForElementContainsText('[data-id="workspaceGitBranchesDropdown"]', 'main') .waitForElementContainsText('[data-id="workspaceGitBranchesDropdown"]', 'main')
}, },
// CLONE REPOSITORY E2E START // CLONE REPOSITORY E2E START
'Should clone a repository #group2': function (browser: NightwatchBrowser) { 'Should clone a repository #group2': function (browser: NightwatchBrowser) {
browser browser
.clickLaunchIcon('filePanel') .clickLaunchIcon('filePanel')
.useXpath() .useXpath()
.click('//*[@id="workspacesMenuDropdown"]/span/i') .waitForElementVisible('[data-id="workspaceDropdownMenuIcon"]')
.waitForElementVisible('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .click('[data-id="workspaceDropdownMenuIcon"]')
.click('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .waitForElementVisible('[data-id="initGitRepositoryLabel"]')
.click('[data-id="workspaceclone]"')
.useCss() .useCss()
.waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]') .waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]')
.click('[data-id="fileSystemModalDialogModalBody-react"]') .click('[data-id="fileSystemModalDialogModalBody-react"]')
@ -94,9 +92,9 @@ module.exports = {
'Should display non-clashing names for duplicate clone #group2': '' + function (browser: NightwatchBrowser) { 'Should display non-clashing names for duplicate clone #group2': '' + function (browser: NightwatchBrowser) {
browser browser
.useXpath() .useXpath()
.click('//*[@id="workspacesMenuDropdown"]/span/i') .click('[data-id="workspaceDropdownMenuIcon"]')
.waitForElementVisible('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .waitForElementVisible('[data-id="workspaceclone]"')
.click('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .click('[data-id="workspaceclone]"')
.useCss() .useCss()
.waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]') .waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]')
.click('[data-id="fileSystemModalDialogModalBody-react"]') .click('[data-id="fileSystemModalDialogModalBody-react"]')
@ -106,9 +104,9 @@ module.exports = {
.pause(5000) .pause(5000)
.waitForElementContainsText('[data-id="workspacesSelect"]', 'awesome-remix1') .waitForElementContainsText('[data-id="workspacesSelect"]', 'awesome-remix1')
.useXpath() .useXpath()
.click('//*[@id="workspacesMenuDropdown"]/span/i') .click('[data-id="workspaceDropdownMenuIcon"]')
.waitForElementVisible('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .waitForElementVisible('[data-id="workspaceclone]"')
.click('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .click('[data-id="workspaceclone]"')
.useCss() .useCss()
.waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]') .waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]')
.click('[data-id="fileSystemModalDialogModalBody-react"]') .click('[data-id="fileSystemModalDialogModalBody-react"]')
@ -118,8 +116,8 @@ module.exports = {
.pause(5000) .pause(5000)
.waitForElementContainsText('[data-id="workspacesSelect"]', 'awesome-remix2') .waitForElementContainsText('[data-id="workspacesSelect"]', 'awesome-remix2')
.useXpath() .useXpath()
.click('//*[@id="workspacesMenuDropdown"]/span/i') .click('[data-id="workspaceDropdownMenuIcon"]')
.waitForElementVisible('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .waitForElementVisible('[data-id="workspaceclone]"')
.useCss() .useCss()
.waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]') .waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]')
.click('[data-id="fileSystemModalDialogModalBody-react"]') .click('[data-id="fileSystemModalDialogModalBody-react"]')
@ -138,12 +136,12 @@ module.exports = {
browser browser
.useXpath() .useXpath()
.waitForElementPresent({ .waitForElementPresent({
selector: '//i[@data-icon="workspaceDropdownMenuIcon"]', selector: '[data-id="workspaceDropdownMenuIcon"]',
locateStrategy: 'xpath', locateStrategy: 'xpath',
}) })
.click('//*[@id="workspacesMenuDropdown"]/span/i') .click('[data-id="workspaceDropdownMenuIcon"]')
.waitForElementVisible('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .waitForElementVisible('[data-id="workspaceclone]"')
.click('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .click('[data-id="workspaceclone]"')
.useCss() .useCss()
.waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]') .waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]')
.click('[data-id="fileSystemModalDialogModalBody-react"]') .click('[data-id="fileSystemModalDialogModalBody-react"]')
@ -164,9 +162,9 @@ module.exports = {
.clickLaunchIcon('filePanel') .clickLaunchIcon('filePanel')
.waitForElementNotVisible('[data-id="workspaceGitPanel"]') .waitForElementNotVisible('[data-id="workspaceGitPanel"]')
.useXpath() .useXpath()
.click('//*[@id="workspacesMenuDropdown"]/span/i') .click('[data-id="workspaceDropdownMenuIcon"]')
.waitForElementVisible('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .waitForElementVisible('[data-id="workspaceclone]"')
.click('//*[@id="workspacesMenuDropdown"]/div/ul/a[6]') .click('[data-id="workspaceclone]"')
.useCss() .useCss()
.waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]') .waitForElementVisible('[data-id="fileSystemModalDialogModalBody-react"]')
.click('[data-id="fileSystemModalDialogModalBody-react"]') .click('[data-id="fileSystemModalDialogModalBody-react"]')

@ -10,7 +10,7 @@
"filePanel.workspace.delete": "Delete Workspace", "filePanel.workspace.delete": "Delete Workspace",
"filePanel.workspace.deleteConfirm": "Are you sure to delete the current workspace?", "filePanel.workspace.deleteConfirm": "Are you sure to delete the current workspace?",
"filePanel.workspace.deleteAll": "Delete All Workspaces", "filePanel.workspace.deleteAll": "Delete All Workspaces",
"filePanel.workspace.deleteAllConfirm": "Are you absolutely sure you want to delete all your workspace?", "filePanel.workspace.deleteAllConfirm": "Are you absolutely sure you want to delete all your workspaces? Deleted workspaces can not be restored in any manner.",
"filePanel.workspace.name": "Workspace name", "filePanel.workspace.name": "Workspace name",
"filePanel.workspace.chooseTemplate": "Choose a template", "filePanel.workspace.chooseTemplate": "Choose a template",
"filePanel.workspace.download": "Download Workspace", "filePanel.workspace.download": "Download Workspace",

@ -10,7 +10,7 @@
"filePanel.workspace.delete": "删除工作空间", "filePanel.workspace.delete": "删除工作空间",
"filePanel.workspace.deleteConfirm": "确定要删除当前工作空间?", "filePanel.workspace.deleteConfirm": "确定要删除当前工作空间?",
"filePanel.workspace.deleteAll": "Delete All Workspaces", "filePanel.workspace.deleteAll": "Delete All Workspaces",
"filePanel.workspace.deleteAllConfirm": "Are you absolutely sure you want to delete all your workspace?", "filePanel.workspace.deleteAllConfirm": "Are you absolutely sure you want to delete all your workspaces? Deleted workspaces can not be restored in any manner.",
"filePanel.workspace.name": "工作空间名称", "filePanel.workspace.name": "工作空间名称",
"filePanel.workspace.chooseTemplate": "选择一个工作空间模板", "filePanel.workspace.chooseTemplate": "选择一个工作空间模板",
"filePanel.workspace.download": "下载工作空间", "filePanel.workspace.download": "下载工作空间",

@ -30,7 +30,7 @@ export const CustomIconsToggle = React.forwardRef(({ onClick, icon, className =
className={`${className.replace('dropdown-toggle', '')} mb-0 pb-0 d-flex justify-content-end align-items-end remixuimenuicon_shadow fs-3`} className={`${className.replace('dropdown-toggle', '')} mb-0 pb-0 d-flex justify-content-end align-items-end remixuimenuicon_shadow fs-3`}
data-id="workspaceMenuDropdown" data-id="workspaceMenuDropdown"
> >
{ icon && <i style={{ fontSize: 'large' }} className={`${icon}`} data-icon="workspaceDropdownMenuIcon"></i> } { icon && <i style={{ fontSize: 'large' }} className={`${icon}`} data-id="workspaceDropdownMenuIcon"></i> }
</span> </span>
)) ))
@ -48,7 +48,7 @@ export const CustomMenu = React.forwardRef(
> >
<ul className="overflow-auto list-unstyled mb-0" style={{ maxHeight: height+'px' }}> <ul className="overflow-auto list-unstyled mb-0" style={{ maxHeight: height+'px' }}>
{ {
children children
} }
</ul> </ul>
</div> </div>

Loading…
Cancel
Save