From a919da16728fa4ae217bb77706c3e9fdcb4e14ab Mon Sep 17 00:00:00 2001 From: muellerfluri Date: Fri, 13 Sep 2024 09:07:19 +0200 Subject: [PATCH 1/5] test(citrus-simulator-ui): change path of artifacts and ensure that debug script is reached. --- .github/workflows/frontend.yml | 5 +++-- simulator-ui/playwright.config.ts | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/frontend.yml b/.github/workflows/frontend.yml index a0d2a590..f85a1fc9 100644 --- a/.github/workflows/frontend.yml +++ b/.github/workflows/frontend.yml @@ -85,15 +85,16 @@ jobs: echo "------------------------------are reports existent?-------------------------" ls working-directory: simulator-ui + continue-on-error: true - uses: actions/upload-artifact@v4 if: ${{ !cancelled() }} with: name: test-results - path: test-results/ + path: simulator-ui/test-results/ retention-days: 30 - uses: actions/upload-artifact@v4 if: ${{ !cancelled() }} with: name: playwright-report - path: playwright-report/ + path: simulator-ui/playwright-report/ retention-days: 30 diff --git a/simulator-ui/playwright.config.ts b/simulator-ui/playwright.config.ts index 18b78286..ed190f06 100644 --- a/simulator-ui/playwright.config.ts +++ b/simulator-ui/playwright.config.ts @@ -17,7 +17,7 @@ export default defineConfig({ /* Fail the build on CI if you accidentally left test.only in the source code. */ forbidOnly: !!process.env.CI, /* Retry on CI only */ - retries: process.env.CI ? 3 : 0, + retries: process.env.CI ? 2 : 0, /* Opt out of parallel tests on CI. */ workers: process.env.CI ? 1 : undefined, /* Reporter to use. See https://playwright.dev/docs/test-reporters */ From 6c8d6fe7854215beed93a5eac16dbf77a3156e12 Mon Sep 17 00:00:00 2001 From: muellerfluri Date: Fri, 13 Sep 2024 09:13:13 +0200 Subject: [PATCH 2/5] test(citrus-simulator-ui): change path of artifacts --- .github/workflows/frontend.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/frontend.yml b/.github/workflows/frontend.yml index f85a1fc9..730afc61 100644 --- a/.github/workflows/frontend.yml +++ b/.github/workflows/frontend.yml @@ -90,11 +90,11 @@ jobs: if: ${{ !cancelled() }} with: name: test-results - path: simulator-ui/test-results/ + path: test-results/ retention-days: 30 - uses: actions/upload-artifact@v4 if: ${{ !cancelled() }} with: name: playwright-report - path: simulator-ui/playwright-report/ + path: playwright-report/ retention-days: 30 From b92780eb4b8da2645113d4d76c581be62d80893e Mon Sep 17 00:00:00 2001 From: muellerfluri Date: Fri, 13 Sep 2024 11:13:08 +0200 Subject: [PATCH 3/5] ci(citrus-simulator-ui): add or for ls after e2e command and specify working directory --- .github/workflows/frontend.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/frontend.yml b/.github/workflows/frontend.yml index 730afc61..c94373ad 100644 --- a/.github/workflows/frontend.yml +++ b/.github/workflows/frontend.yml @@ -81,20 +81,21 @@ jobs: echo "Current directory is:" pwd ls - npm run e2e - echo "------------------------------are reports existent?-------------------------" - ls + npm run e2e || ls working-directory: simulator-ui - continue-on-error: true - uses: actions/upload-artifact@v4 if: ${{ !cancelled() }} with: name: test-results path: test-results/ retention-days: 30 + working-directory: simulator-ui + - uses: actions/upload-artifact@v4 if: ${{ !cancelled() }} with: name: playwright-report path: playwright-report/ retention-days: 30 + working-directory: simulator-ui + From 75fd919e017f48aebdb0b814aeff12c97e8ba299 Mon Sep 17 00:00:00 2001 From: muellerfluri Date: Fri, 13 Sep 2024 11:17:40 +0200 Subject: [PATCH 4/5] ci(citrus-simulator-ui): adapt artifact path --- .github/workflows/frontend.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/frontend.yml b/.github/workflows/frontend.yml index c94373ad..7a75e12e 100644 --- a/.github/workflows/frontend.yml +++ b/.github/workflows/frontend.yml @@ -87,15 +87,13 @@ jobs: if: ${{ !cancelled() }} with: name: test-results - path: test-results/ + path: simulator-ui/test-results/ retention-days: 30 - working-directory: simulator-ui - uses: actions/upload-artifact@v4 if: ${{ !cancelled() }} with: name: playwright-report - path: playwright-report/ + path: simulator-ui/playwright-report/ retention-days: 30 - working-directory: simulator-ui From f305968fcb1c16b2b86436c96658b168956b8c57 Mon Sep 17 00:00:00 2001 From: muellerfluri Date: Fri, 13 Sep 2024 11:25:46 +0200 Subject: [PATCH 5/5] ci(citrus-simulator-ui): remove ls debugging commands --- .github/workflows/frontend.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/frontend.yml b/.github/workflows/frontend.yml index 7a75e12e..123a7a03 100644 --- a/.github/workflows/frontend.yml +++ b/.github/workflows/frontend.yml @@ -77,11 +77,7 @@ jobs: run: npx playwright install --with-deps working-directory: simulator-ui - name: Run Playwright tests - run: | - echo "Current directory is:" - pwd - ls - npm run e2e || ls + run: npm run e2e working-directory: simulator-ui - uses: actions/upload-artifact@v4 if: ${{ !cancelled() }}