workspace test

pull/4791/head
Your Name 6 months ago
parent d29472da6b
commit ec5e66e32a
  1. 15
      apps/remix-ide-e2e/src/tests/workspace_git.test.ts
  2. 2
      libs/remix-ui/git/src/components/gitui.tsx

@ -40,6 +40,7 @@ module.exports = {
.click('[data-id="settingsTabSaveGistToken"]') .click('[data-id="settingsTabSaveGistToken"]')
}, },
'Should create and initialize a GIT repository #group1': function (browser: NightwatchBrowser) { 'Should create and initialize a GIT repository #group1': function (browser: NightwatchBrowser) {
browser browser
.clickLaunchIcon('filePanel') .clickLaunchIcon('filePanel')
@ -59,6 +60,20 @@ module.exports = {
.waitForElementVisible('[data-id="workspaceGitPanel"]') .waitForElementVisible('[data-id="workspaceGitPanel"]')
.waitForElementContainsText('[data-id="workspaceGitBranchesDropdown"]', 'main') .waitForElementContainsText('[data-id="workspaceGitBranchesDropdown"]', 'main')
}, },
'check git for the commit #group1 #group2 #group3': function (browser: NightwatchBrowser) {
browser.
clickLaunchIcon('dgit')
.click('*[data-id="commits-panel"]')
.waitForElementPresent({
selector: '//*[@data-id="commits-current-branch-main"]//*[@data-id="commit-summary-Initial commit: remix template blank-"]',
locateStrategy: 'xpath'
})
.click('*[data-id="branches-panel"]')
.waitForElementPresent({
selector: '//*[@data-id="branches-panel-content"]//*[@data-id="branches-current-branch-main"]',
locateStrategy: 'xpath'
})
},
// CLONE REPOSITORY E2E START // CLONE REPOSITORY E2E START

@ -80,7 +80,7 @@ export const GitUI = (props: IGitUi) => {
setSetup(!(username && email)) setSetup(!(username && email))
} }
checkconfig() checkconfig()
}, [gitState.gitHubAccessToken, gitState.gitHubUser, gitState.userEmails]) }, [gitState.gitHubAccessToken, gitState.gitHubUser, gitState.userEmails, gitState.commits, gitState.branches])
useEffect(() => { useEffect(() => {
if (!appLoaded) return if (!appLoaded) return

Loading…
Cancel
Save