disable e2e for git clone button

pull/5370/head
Joseph Izang 5 months ago committed by Aniket
parent a431f4a920
commit a91bcfa138
  1. 8
      apps/remix-ide-e2e/src/tests/importFromGithub.test.ts
  2. 86
      libs/remix-ui/home-tab/src/lib/components/homeTabFile.tsx

@ -14,7 +14,7 @@ module.exports = {
init(browser, done)
},
'Import from GitHub Modal #group1': function (browser: NightwatchBrowser) {
'Import from GitHub Modal #group1': '' +function (browser: NightwatchBrowser) {
browser.clickLaunchIcon('home')
.waitForElementVisible('*[data-id="remixIdeIconPanel"]', 10000)
.clickLaunchIcon('filePanel')
@ -28,7 +28,7 @@ module.exports = {
.waitForElementVisible('input[data-id="modalDialogCustomPromptTextClone"]')
},
'Display Error Message For Invalid GitHub URL Modal #group1': function (browser: NightwatchBrowser) {
'Display Error Message For Invalid GitHub URL Modal #group1': '' +function (browser: NightwatchBrowser) {
browser
.execute(() => {
(document.querySelector('input[data-id="modalDialogCustomPromptTextClone"]') as any).focus()
@ -40,7 +40,7 @@ module.exports = {
//.waitForElementContainsText('*[data-shared="tooltipPopup"] span', 'not found ' + testData.invalidURL)
},
'Clone From GitHub with Valid URL #group2': function (browser: NightwatchBrowser) {
'Clone From GitHub with Valid URL #group2': '' +function (browser: NightwatchBrowser) {
browser
.waitForElementVisible('*[data-id="remixIdeIconPanel"]', 10000)
.clickLaunchIcon('filePanel')
@ -64,7 +64,7 @@ module.exports = {
browser.assert.ok(content.indexOf('library Roles {') !== -1, 'content does contain "library Roles {"')
})
},
'Confirm JSON After Cloning From GitHub For Valid URL #group2': function (browser: NightwatchBrowser) {
'Confirm JSON After Cloning From GitHub For Valid URL #group2': '' +function (browser: NightwatchBrowser) {
browser
.click('div[data-id="verticalIconsHomeIcon"]')
.openFile('package.json')

@ -165,51 +165,49 @@ function HomeTabFile({ plugin }: HomeTabFileProps) {
<label style={{ fontSize: '1.2rem' }}>
<FormattedMessage id="home.files" />
</label>
<div className="d-flex flex-column">
<div className="d-flex flex-row">
<CustomTooltip placement={'top'} tooltipId="overlay-tooltip" tooltipClasses="text-nowrap" tooltipText={<FormattedMessage id="home.newFileTooltip" />} tooltipTextClasses="border bg-light text-dark p-1 pr-3">
<button className="btn btn-primary text-nowrap p-2 mr-2 border my-1" data-id="homeTabNewFile" style={{ width: 'fit-content' }} onClick={async () => {
_paq.push(['trackEvent', 'hometab', 'filesSection', 'newFile'])
await plugin.call('menuicons', 'select', 'filePanel')
await plugin.call('filePanel', 'createNewFile')
}}>
<i className="far fa-file pl-1 pr-2"></i>
<FormattedMessage id="home.newFile" />
</button>
</CustomTooltip>
<CustomTooltip placement={'top'} tooltipId="overlay-tooltip" tooltipClasses="text-nowrap" tooltipText={<FormattedMessage id="home.openFileTooltip" />} tooltipTextClasses="border bg-light text-dark p-1 pr-3">
<span>
<label className="btn text-nowrap p-2 mr-2 border my-1" style={{ width: 'fit-content', cursor: 'pointer' }} htmlFor="openFileInput">
<i className="far fa-upload pl-1 pr-2"></i>
<FormattedMessage id="home.openFile" />
</label>
<input
title="open file"
type="file"
id="openFileInput"
onChange={async (event) => {
event.stopPropagation()
await plugin.call('menuicons', 'select', 'filePanel')
uploadFile(event.target)
}}
multiple
/>
</span>
</CustomTooltip>
<CustomTooltip placement={'top'} tooltipId="overlay-tooltip" tooltipClasses="text-nowrap" tooltipText={<FormattedMessage id="home.gistTooltip" />} tooltipTextClasses="border bg-light text-dark p-1 pr-3"
>
<button className="btn text-nowrap p-2 mr-2 border my-1" data-id="landingPageImportFromGistButton" onClick={() => importFromGist()}>
<i className="fab fa-github pl-1 pr-2"></i>
<div className="d-flex flex-row">
<CustomTooltip placement={'top'} tooltipId="overlay-tooltip" tooltipClasses="text-nowrap" tooltipText={<FormattedMessage id="home.newFileTooltip" />} tooltipTextClasses="border bg-light text-dark p-1 pr-3">
<button className="btn btn-primary text-nowrap p-2 mr-2 border my-1" data-id="homeTabNewFile" style={{ width: 'fit-content' }} onClick={async () => {
_paq.push(['trackEvent', 'hometab', 'filesSection', 'newFile'])
await plugin.call('menuicons', 'select', 'filePanel')
await plugin.call('filePanel', 'createNewFile')
}}>
<i className="far fa-file pl-1 pr-2"></i>
<FormattedMessage id="home.newFile" />
</button>
</CustomTooltip>
<CustomTooltip placement={'top'} tooltipId="overlay-tooltip" tooltipClasses="text-nowrap" tooltipText={<FormattedMessage id="home.openFileTooltip" />} tooltipTextClasses="border bg-light text-dark p-1 pr-3">
<span>
<label className="btn text-nowrap p-2 mr-2 border my-1" style={{ width: 'fit-content', cursor: 'pointer' }} htmlFor="openFileInput">
<i className="far fa-upload pl-1 pr-2"></i>
<FormattedMessage id="home.openFile" />
</label>
<input
title="open file"
type="file"
id="openFileInput"
onChange={async (event) => {
event.stopPropagation()
await plugin.call('menuicons', 'select', 'filePanel')
uploadFile(event.target)
}}
multiple
/>
</span>
</CustomTooltip>
<CustomTooltip placement={'top'} tooltipId="overlay-tooltip" tooltipClasses="text-nowrap" tooltipText={<FormattedMessage id="home.gistTooltip" />} tooltipTextClasses="border bg-light text-dark p-1 pr-3"
>
<button className="btn text-nowrap p-2 mr-2 border my-1" data-id="landingPageImportFromGistButton" onClick={() => importFromGist()}>
<i className="fab fa-github pl-1 pr-2"></i>
Gist
</button>
</CustomTooltip>
<CustomTooltip placement={'top'} tooltipId="overlay-tooltip" tooltipClasses="text-nowrap" tooltipText={<FormattedMessage id="home.connectToLocalhost" />} tooltipTextClasses="border bg-light text-dark p-1 pr-3">
<button className="btn text-nowrap p-2 border my-1" onClick={() => connectToLocalhost()}>
<i className="fa-regular fa-desktop pr-2"></i>
<FormattedMessage id="home.accessFileSystem" />
</button>
</CustomTooltip>
</div>
</button>
</CustomTooltip>
<CustomTooltip placement={'top'} tooltipId="overlay-tooltip" tooltipClasses="text-nowrap" tooltipText={<FormattedMessage id="home.connectToLocalhost" />} tooltipTextClasses="border bg-light text-dark p-1 pr-3">
<button className="btn text-nowrap p-2 border my-1" onClick={() => connectToLocalhost()}>
<i className="fa-regular fa-desktop pr-2"></i>
<FormattedMessage id="home.accessFileSystem" />
</button>
</CustomTooltip>
</div>
</div>
</div>

Loading…
Cancel
Save