diff --git a/tests/snapshot-gating.fmf b/tests/snapshot-gating.fmf index 98b76df4..0d5f4489 100644 --- a/tests/snapshot-gating.fmf +++ b/tests/snapshot-gating.fmf @@ -10,13 +10,17 @@ summary: LLVM Tests for snapshot gating prepare: - # dnf5's copr plugin has trouble resolving the runtime dependency repos, so - # we need to use dnf4. Check https://github.com/fedora-copr/copr/issues/3387 - name: Enable copr repo how: shell - script: | - dnf install -y dnf-plugins-core - dnf-3 -y copr enable @fedora-llvm-team/$COPR_PROJECT $COPR_CHROOT + script: + - dnf install -y 'dnf5-command(copr)' || dnf install -y 'dnf-command(copr)' + - dnf -y copr enable @fedora-llvm-team/$COPR_PROJECT $COPR_CHROOT + # dnf5's copr plugin has trouble resolving the runtime dependency repos, + # and is not replacing the $distname special var. Hence we need to do that + # parsing ourselves. + # Check https://github.com/fedora-copr/copr/issues/3387 + - sed -i "s/\$distname/$(echo "$COPR_CHROOT" | cut -d '-' -f 1)/" /etc/yum.repos.d/*$COPR_PROJECT* + # Lower the priority of the testing-farm-tag-repository so that our copr repo is picked up. # See: https://docs.testing-farm.io/Testing%20Farm/0.1/test-environment.html#_tag_repository - how: shell