fix(ci): run and build right e2e tests artifacts on e2e-test-main (#8809)

* fix(ci): run and build right e2e tests artifacts on e2e-test-main

Signed-off-by: Ondrej Dockal <odockal@redhat.com>

* chore(test): add @update-install tag and adjust test:e2e:run target

Signed-off-by: Ondrej Dockal <odockal@redhat.com>
This commit is contained in:
Ondrej Dockal 2024-09-10 09:10:30 +02:00 committed by GitHub
parent 0ad301cddc
commit 4365ad99fe
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 10 additions and 11 deletions

View file

@ -102,12 +102,10 @@ jobs:
win-update-e2e-test:
name: win update e2e tests
runs-on: ${{ matrix.os }}
timeout-minutes: 40
strategy:
fail-fast: false
matrix:
os: [windows-2022]
runs-on: windows-2022
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
with:
@ -135,7 +133,6 @@ jobs:
run: pnpm install --frozen-lockfile
- name: Adjust/Downgrade local podman desktop version Windows
if: ${{ matrix.os=='windows-2022'}}
run: |
$version="1.0.0"
jq --arg version "$version" '.version = $version' package.json | Out-File -FilePath package.json_tmp

View file

@ -38,7 +38,7 @@
"test:unit": "npm run test:main && npm run test:preload && npm run test:preload-docker-extension && npm run test:preload-webview && npm run test:ui && npm run test:renderer && npm run test:scripts:stylesheet && npm run test:tools && npm run test:extensions",
"test:e2e": "npm run test:e2e:build && npm run test:e2e:run",
"test:e2e:build": "cross-env NODE_ENV=development MODE=development DEBUG=pw:browser npm run build",
"test:e2e:run": "xvfb-maybe --auto-servernum --server-args='-screen 0 1280x960x24' -- npx playwright test tests/playwright/src/specs/",
"test:e2e:run": "xvfb-maybe --auto-servernum --server-args='-screen 0 1280x960x24' -- npx playwright test tests/playwright/src/specs/ --grep-invert @update-install",
"test:e2e:smoke": "npm run test:e2e:build && npm run test:e2e:smoke:run",
"test:e2e:smoke:run": "xvfb-maybe --auto-servernum --server-args='-screen 0 1280x960x24' -- npx playwright test tests/playwright/src/specs/ -g @smoke",
"test:e2e:extension": "npm run test:e2e:build && npm run test:e2e:extension:run",
@ -46,8 +46,7 @@
"test:e2e:pw": "npm run test:e2e:build && npm run test:e2e:pw:run",
"test:e2e:pw:run": "xvfb-maybe --auto-servernum --server-args='-screen 0 1280x960x24' -- npx playwright test tests/playwright/src/specs/pod-smoke.spec.ts",
"test:e2e:update": "npm run test:e2e:build && npm run test:e2e:update:run",
"test:e2e:update:run": "xvfb-maybe --auto-servernum --server-args='-screen 0 1280x960x24' -- npx playwright test tests/playwright/src/specs/installation/update-install.spec.ts",
"test:e2e:copy": "cp ../podman-desktop-extension-bootc/tests/src/bootc-extension.spec.ts tests/src/",
"test:e2e:update:run": "xvfb-maybe --auto-servernum --server-args='-screen 0 1280x960x24' -- npx playwright test tests/playwright/src/specs/installation/ -g @update-install",
"test:main": "vitest run -r packages/main --passWithNoTests --coverage",
"test:preload": "vitest run -r packages/preload --passWithNoTests --coverage",
"test:preload-docker-extension": "vitest run -r packages/preload-docker-extension --passWithNoTests --coverage",

View file

@ -21,6 +21,7 @@ import type { Locator } from '@playwright/test';
import type { StatusBar } from '../../model/workbench/status-bar';
import { expect as playExpect, test } from '../../utility/fixtures';
import { handleConfirmationDialog } from '../../utility/operations';
import { isLinux } from '../../utility/platform';
let sBar: StatusBar;
let updateAvailableDialog: Locator;
@ -28,6 +29,8 @@ let updateDialog: Locator;
let updateDownloadedDialog: Locator;
const performUpdate = process.env.UPDATE_PODMAN_DESKTOP ? process.env.UPDATE_PODMAN_DESKTOP : false;
test.skip(isLinux, 'Update is not supported on Linux');
test.beforeAll(async ({ runner, page, statusBar }) => {
runner.setVideoAndTraceName('update-e2e');
@ -41,7 +44,7 @@ test.afterAll(async ({ runner }) => {
await runner.close();
});
test.describe.serial('Podman Desktop Update Update installation offering', () => {
test.describe.serial('Podman Desktop Update Update installation offering @update-install', () => {
test('Update is offered automatically on startup', async ({ welcomePage }) => {
await playExpect(updateAvailableDialog).toBeVisible();
const updateNowButton = updateAvailableDialog.getByRole('button', { name: 'Update Now' });