Skip to content

Commit

Permalink
github_actions: run tests only on labels
Browse files Browse the repository at this point in the history
When a github PR is made, the unit tests will start only after a
maintainer labels the PR with 'ready-for-unit-testing' label.

Change-Id: I672843926f68c232907d603d91064422e414970e
  • Loading branch information
ader1990 committed Nov 21, 2023
1 parent 6b2372d commit 7ec2f72
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/unit_tests.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
name: Cloudbase-Init unit tests

on: [push, pull_request]
on:
push:
pull_request:
types: [ labeled ]

jobs:
build:
if: ${{ github.event_name == 'push' || contains(github.event.pull_request.labels.*.name, 'ready-for-unit-testing') }}
runs-on: ubuntu-22.04
strategy:
matrix:
Expand Down

0 comments on commit 7ec2f72

Please sign in to comment.