Skip to content

Commit f2f6b9d

Browse files
committed
ci: allow selecting test lanes to run
1 parent 3cd3dfd commit f2f6b9d

File tree

1 file changed

+23
-3
lines changed

1 file changed

+23
-3
lines changed

.github/workflows/ci.yml

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,16 @@
11
name: CI
22

33
on:
4+
workflow_dispatch:
5+
inputs:
6+
test-scope:
7+
description: Select test lanes to run
8+
required: false
9+
default: all
10+
type: choice
11+
options:
12+
- all
13+
- fips
414
release:
515
types: [published]
616
pull_request:
@@ -464,7 +474,7 @@ jobs:
464474
name: 📦 Track Image Sizes
465475
needs: [build-gh-docker-publish, release-versions]
466476
runs-on: ubuntu-24.04-arm
467-
if: github.event_name == 'pull_request' || github.ref == 'refs/heads/develop'
477+
if: github.event_name != 'workflow_dispatch' && (github.event_name == 'pull_request' || github.ref == 'refs/heads/develop')
468478
permissions:
469479
pull-requests: write
470480
contents: write
@@ -496,6 +506,7 @@ jobs:
496506
test-storybook:
497507
name: 🔨 Test Storybook
498508
needs: [packages-build, release-versions]
509+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
499510

500511
uses: ./.github/workflows/ci-test-storybook.yml
501512
with:
@@ -507,6 +518,7 @@ jobs:
507518
test-unit:
508519
name: 🔨 Test Unit
509520
needs: [packages-build, release-versions]
521+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
510522

511523
uses: ./.github/workflows/ci-test-unit.yml
512524
with:
@@ -519,6 +531,7 @@ jobs:
519531
test-api:
520532
name: 🔨 Test API (CE)
521533
needs: [checks, build-gh-docker-publish, release-versions]
534+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
522535

523536
uses: ./.github/workflows/ci-test-e2e.yml
524537
with:
@@ -535,6 +548,7 @@ jobs:
535548
test-api-livechat:
536549
name: 🔨 Test API Livechat (CE)
537550
needs: [checks, build-gh-docker-publish, release-versions]
551+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
538552

539553
uses: ./.github/workflows/ci-test-e2e.yml
540554
with:
@@ -551,6 +565,7 @@ jobs:
551565
test-ui:
552566
name: 🔨 Test UI (CE)
553567
needs: [checks, build-gh-docker-publish, release-versions]
568+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
554569

555570
uses: ./.github/workflows/ci-test-e2e.yml
556571
with:
@@ -576,6 +591,7 @@ jobs:
576591
test-api-ee:
577592
name: 🔨 Test API (EE)
578593
needs: [checks, build-gh-docker-publish, release-versions]
594+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
579595

580596
uses: ./.github/workflows/ci-test-e2e.yml
581597
with:
@@ -596,6 +612,7 @@ jobs:
596612
test-api-livechat-ee:
597613
name: 🔨 Test API Livechat (EE)
598614
needs: [checks, build-gh-docker-publish, release-versions]
615+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
599616

600617
uses: ./.github/workflows/ci-test-e2e.yml
601618
with:
@@ -616,6 +633,7 @@ jobs:
616633
test-ui-ee:
617634
name: 🔨 Test UI (EE)
618635
needs: [checks, build-gh-docker-publish, release-versions]
636+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
619637

620638
uses: ./.github/workflows/ci-test-e2e.yml
621639
with:
@@ -708,6 +726,7 @@ jobs:
708726
test-federation-matrix:
709727
name: 🔨 Test Federation Matrix
710728
needs: [checks, build-gh-docker-publish, packages-build, release-versions]
729+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
711730
runs-on: ubuntu-24.04
712731

713732
steps:
@@ -804,6 +823,7 @@ jobs:
804823
name: 📊 Report Coverage
805824
runs-on: ubuntu-24.04
806825
needs: [release-versions, test-api-ee, test-api-livechat-ee, test-ui-ee]
826+
if: ${{ github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips' }}
807827

808828
steps:
809829
- uses: actions/checkout@v6
@@ -856,7 +876,7 @@ jobs:
856876
name: ✅ Tests Done
857877
runs-on: ubuntu-24.04-arm
858878
needs: [checks, test-unit, test-api, test-ui, test-api-ee, test-ui-ee, test-api-livechat, test-api-livechat-ee, test-api-fips, test-api-livechat-fips, test-ui-fips, test-federation-matrix]
859-
if: always()
879+
if: ${{ always() && (github.event_name != 'workflow_dispatch' || inputs.test-scope != 'fips') }}
860880
steps:
861881
- name: Test finish aggregation
862882
run: |
@@ -913,7 +933,7 @@ jobs:
913933
deploy:
914934
name: 🚀 Publish build assets
915935
runs-on: ubuntu-24.04-arm
916-
if: github.event_name == 'release' || github.ref == 'refs/heads/develop'
936+
if: github.event_name != 'workflow_dispatch' && (github.event_name == 'release' || github.ref == 'refs/heads/develop')
917937
needs: [build-gh-docker-publish, release-versions]
918938

919939
steps:

0 commit comments

Comments
 (0)