Skip to content

Commit 9f0982f

Browse files
committed
Fix e2e tests
1 parent e496d70 commit 9f0982f

5 files changed

Lines changed: 17 additions & 14 deletions

File tree

.github/workflows/ci.yml

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -278,17 +278,17 @@ jobs:
278278
- name: Install app on macOS
279279
if: runner.os == 'macOS'
280280
run: |
281-
rm -rf "/Applications/GitHub Desktop.app"
282-
ditto "dist/GitHub Desktop-darwin-arm64/GitHub Desktop.app" "/Applications/GitHub Desktop.app"
283-
echo "DESKTOP_E2E_APP_PATH=/Applications/GitHub Desktop.app/Contents/MacOS/GitHub Desktop" >> "$GITHUB_ENV"
281+
rm -rf "/Applications/GitHub Desktop Plus.app"
282+
ditto "dist/GitHub Desktop Plus-darwin-arm64/GitHub Desktop Plus.app" "/Applications/GitHub Desktop Plus.app"
283+
echo "DESKTOP_E2E_APP_PATH=/Applications/GitHub Desktop Plus.app/Contents/MacOS/GitHub Desktop Plus" >> "$GITHUB_ENV"
284284
- name: Install app on Windows
285285
if: runner.os == 'Windows'
286286
shell: pwsh
287287
run: |
288288
function Write-SquirrelLogs {
289289
$logPaths = @(
290290
"$env:LOCALAPPDATA\SquirrelSetup.log",
291-
"$env:LOCALAPPDATA\GitHubDesktop\SquirrelSetup.log"
291+
"$env:LOCALAPPDATA\GitHubDesktopPlus\SquirrelSetup.log"
292292
)
293293
294294
foreach ($logPath in $logPaths) {
@@ -299,7 +299,14 @@ jobs:
299299
}
300300
}
301301
302-
$setupExe = "dist/GitHubDesktopSetup-${{ matrix.arch }}.exe"
302+
$setupExe = Get-ChildItem "dist/GitHubDesktopPlus-*-windows-${{ matrix.arch }}.exe" -ErrorAction SilentlyContinue |
303+
Sort-Object FullName -Descending |
304+
Select-Object -First 1 -ExpandProperty FullName
305+
306+
if (-not $setupExe) {
307+
throw "Unable to locate Windows installer executable"
308+
}
309+
303310
$installer = Start-Process -FilePath $setupExe -ArgumentList "/S" -PassThru
304311
305312
try {
@@ -309,11 +316,11 @@ jobs:
309316
throw "Windows installer timed out after 300 seconds"
310317
}
311318
312-
Get-Process GitHubDesktop -ErrorAction SilentlyContinue | Stop-Process -Force
319+
Get-Process GitHubDesktopPlus -ErrorAction SilentlyContinue | Stop-Process -Force
313320
314321
$installedExe = $null
315322
for ($attempt = 0; $attempt -lt 30 -and -not $installedExe; $attempt++) {
316-
$installedExe = Get-ChildItem "$env:LOCALAPPDATA\GitHubDesktop\app-*\GitHubDesktop.exe" -ErrorAction SilentlyContinue |
323+
$installedExe = Get-ChildItem "$env:LOCALAPPDATA\GitHubDesktopPlus\app-*\GitHubDesktopPlus.exe" -ErrorAction SilentlyContinue |
317324
Sort-Object FullName -Descending |
318325
Select-Object -First 1 -ExpandProperty FullName
319326

app/src/ui/branches/branch-list.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -373,7 +373,7 @@ export class BranchList extends React.Component<IBranchListProps> {
373373

374374
private onRenderNewButton = () => {
375375
return this.props.canCreateNewBranch ? (
376-
<Button onClick={this.onCreateNewBranch}>
376+
<Button className="new-branch-button" onClick={this.onCreateNewBranch}>
377377
<Octicon symbol={octicons.plus} className="mr" />
378378
{__DARWIN__ ? 'New Branch' : 'New branch'}
379379
</Button>

app/test/e2e/app-launch.e2e.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -252,10 +252,7 @@ test.describe('GitHub Desktop - App Launch', () => {
252252
// ── Auto-update tests ───────────────────────────────────────────────
253253

254254
test.describe('Auto-update', () => {
255-
test.skip(
256-
process.platform === 'win32' && !process.env.DESKTOP_E2E_APP_PATH,
257-
'Windows auto-update requires an installed Squirrel app, not a packaged app directory.'
258-
)
255+
test.skip(true, 'Auto-update has been removed in GitHub Desktop Plus.')
259256

260257
test.describe('startup update check', () => {
261258
test('sends an update check to the mock server on launch', async ({

app/test/e2e/e2e-fixtures.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ export function terminateWindowsUpdaterProcesses() {
101101
return
102102
}
103103

104-
for (const imageName of ['Update.exe', 'GitHubDesktop.exe']) {
104+
for (const imageName of ['Update.exe', 'GitHubDesktopPlus.exe']) {
105105
spawnSync('taskkill', ['/F', '/T', '/IM', imageName], {
106106
stdio: 'ignore',
107107
windowsHide: true,

script/testing-docker/entrypoint.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ set -e
66
cd /app
77

88
yarn test:unit
9-
yarn test:eslint
109
yarn test:script
1110

1211
echo '-------------------'

0 commit comments

Comments
 (0)