Skip to content

Commit 7ae0d6b

Browse files
authored
refactor: run atoms e2e when e2e label added (calcom#23281)
* refactor: run atoms e2e when e2e label added * refactor: rename atoms-e2e to e2e-atoms
1 parent e0dc2ba commit 7ae0d6b

3 files changed

Lines changed: 20 additions & 14 deletions

File tree

.github/workflows/all-checks.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,14 @@ jobs:
7474
uses: ./.github/workflows/e2e-embed-react.yml
7575
secrets: inherit
7676

77+
e2e-atoms:
78+
name: Tests
79+
needs: [lint, build, build-atoms, build-api-v2]
80+
uses: ./.github/workflows/e2e-atoms.yml
81+
secrets: inherit
82+
7783
required:
78-
needs: [lint, type-check, unit-test, integration-test, build, build-api-v1, build-api-v2, e2e, e2e-embed, e2e-embed-react, e2e-app-store]
84+
needs: [lint, type-check, unit-test, integration-test, build, build-api-v1, build-api-v2, e2e, e2e-embed, e2e-embed-react, e2e-app-store, e2e-atoms]
7985
if: always()
8086
runs-on: buildjet-2vcpu-ubuntu-2204
8187
steps:
Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,7 @@
11
name: Atoms E2E Tests
22

33
on:
4-
pull_request:
5-
branches:
6-
- main
7-
paths:
8-
- 'packages/platform/atoms/**'
9-
- 'packages/platform/examples/base/**'
10-
- 'apps/api/v2/**'
11-
- '.github/workflows/atoms-e2e.yml'
12-
4+
workflow_call:
135
permissions:
146
actions: write
157
contents: read
@@ -25,7 +17,7 @@ env:
2517
DATABASE_URL: ${{ secrets.CI_DATABASE_URL }}
2618

2719
jobs:
28-
atoms-e2e:
20+
e2e-atoms:
2921
timeout-minutes: 15
3022
name: Atoms E2E Tests
3123
runs-on: buildjet-4vcpu-ubuntu-2204
@@ -45,13 +37,13 @@ jobs:
4537
uses: actions/upload-artifact@v4
4638
if: always()
4739
with:
48-
name: atoms-e2e-test-results
40+
name: e2e-atoms-test-results
4941
path: test-results
5042
retention-days: 7
5143
- name: Upload Playwright Report
5244
uses: actions/upload-artifact@v4
5345
if: always()
5446
with:
55-
name: atoms-e2e-playwright-report
47+
name: e2e-atoms-playwright-report
5648
path: playwright-report
5749
retention-days: 7

.github/workflows/pr.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,13 @@ jobs:
195195
uses: ./.github/workflows/e2e-embed-react.yml
196196
secrets: inherit
197197

198+
e2e-atoms:
199+
name: Tests
200+
needs: [changes, check-label, build, build-atoms, build-api-v2]
201+
if: ${{ needs.check-label.outputs.run-e2e == 'true' && needs.changes.outputs.has-files-requiring-all-checks == 'true' }}
202+
uses: ./.github/workflows/e2e-atoms.yml
203+
secrets: inherit
204+
198205
analyze:
199206
name: Analyze Build
200207
needs: [build]
@@ -204,7 +211,7 @@ jobs:
204211
merge-reports:
205212
name: Merge reports
206213
if: ${{ !cancelled() && needs.check-label.outputs.run-e2e == 'true' && needs.changes.outputs.has-files-requiring-all-checks == 'true' }}
207-
needs: [changes, check-label, e2e, e2e-embed, e2e-embed-react, e2e-app-store]
214+
needs: [changes, check-label, e2e, e2e-embed, e2e-embed-react, e2e-app-store, e2e-atoms]
208215
uses: ./.github/workflows/merge-reports.yml
209216
secrets: inherit
210217

@@ -249,6 +256,7 @@ jobs:
249256
e2e-embed,
250257
e2e-embed-react,
251258
e2e-app-store,
259+
e2e-atoms,
252260
]
253261
if: always()
254262
runs-on: buildjet-2vcpu-ubuntu-2204

0 commit comments

Comments
 (0)