Skip to content

Commit 18645e2

Browse files
committed
ceph-pull-requests: run rbd unit tests when "rbd" label is present
even if the pull request doesn't modify any files owned by @ceph/rbd, the "rbd" label can be added to opt in to its unit tests Signed-off-by: Casey Bodley <cbodley@redhat.com>
1 parent 090dc29 commit 18645e2

2 files changed

Lines changed: 10 additions & 2 deletions

File tree

  • ceph-pull-requests-arm64/build
  • ceph-pull-requests/build

ceph-pull-requests-arm64/build/build

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@ export BUILD_MAKEOPTS="-j${n_build_jobs}"
1414
export WITH_CRIMSON=true
1515
export WITH_RBD_RWL=true
1616
# exclude run-rbd-unit-tests* for non-rbd pull requests
17-
if ! pr_matches_codeowner "@ceph/rbd"; then
17+
if pr_matches_codeowner "@ceph/rbd"; then
18+
echo "Pull request changes files owned by @ceph/rbd."
19+
elif pr_matches_label "rbd"; then
20+
echo "Pull request contains rbd label."
21+
else
1822
echo "No rbd files changed. No need to run rbd unit tests."
1923
CHECK_MAKEOPTS+=" -E run-rbd-unit-tests"
2024
fi

ceph-pull-requests/build/build

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,11 @@ export NPROC=$(nproc)
1111
export WITH_CRIMSON=true
1212
export WITH_RBD_RWL=true
1313
# exclude run-rbd-unit-tests* for non-rbd pull requests
14-
if ! pr_matches_codeowner "@ceph/rbd"; then
14+
if pr_matches_codeowner "@ceph/rbd"; then
15+
echo "Pull request changes files owned by @ceph/rbd."
16+
elif pr_matches_label "rbd"; then
17+
echo "Pull request contains rbd label."
18+
else
1519
echo "No rbd files changed. No need to run rbd unit tests."
1620
export CHECK_MAKEOPTS="-E run-rbd-unit-tests"
1721
fi

0 commit comments

Comments
 (0)