summaryrefslogtreecommitdiff
path: root/contrib/cirrus/lib.sh.t
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2019-10-30 21:31:32 +0100
committerGitHub <noreply@github.com>2019-10-30 21:31:32 +0100
commit45e0bd3891f96aed251cc3bbc99b3d16bfc7b8ab (patch)
treef1403db49270c962d16ba660dcaaa6ed6ee328e6 /contrib/cirrus/lib.sh.t
parent32266d155fe156ef562d8fed27112d5644fd8c77 (diff)
parent326ef19d942c8922ebba68e96d870d5117f67472 (diff)
downloadpodman-45e0bd3891f96aed251cc3bbc99b3d16bfc7b8ab.tar.gz
podman-45e0bd3891f96aed251cc3bbc99b3d16bfc7b8ab.tar.bz2
podman-45e0bd3891f96aed251cc3bbc99b3d16bfc7b8ab.zip
Merge pull request #4379 from cevich/fix_upload_release_archive
Cirrus: Fix upload_release_archive on branch or tag
Diffstat (limited to 'contrib/cirrus/lib.sh.t')
-rwxr-xr-xcontrib/cirrus/lib.sh.t17
1 files changed, 10 insertions, 7 deletions
diff --git a/contrib/cirrus/lib.sh.t b/contrib/cirrus/lib.sh.t
index 9915b42a4..8f4080dd5 100755
--- a/contrib/cirrus/lib.sh.t
+++ b/contrib/cirrus/lib.sh.t
@@ -138,16 +138,19 @@ function test_is_release() {
}
# FROM TO TAG RET MSG
-#test_is_release "" "" "" "" ""
-
-test_is_release "" "" "" "9" "FATAL: is_release() requires \$CIRRUS_BASE_SHA to be non-empty"
+test_is_release "" "" "" "9" "FATAL: is_release() requires \$CIRRUS_CHANGE_IN_REPO to be non-empty"
test_is_release "x" "" "" "9" "FATAL: is_release() requires \$CIRRUS_CHANGE_IN_REPO to be non-empty"
-test_is_release "unknown" "x" "" "11" "is_release() unusable range unknown..x or tag "
-test_is_release "x" "unknown" "" "11" "is_release() unusable range x..unknown or tag "
-test_is_release "x" "x" "unknown" "11" "is_release() unusable range x..x or tag unknown"
+# post-merge / tag-push testing, FROM will be set 'unknown' by (lib.sh default)
+test_is_release "unknown" "x" "" "1" ""
+# post-merge / tag-push testing, oddball tag is set, FROM will be set 'unknown'
+test_is_release "unknown" "unknown" "test-tag" "2" "Found \$RELVER test-tag"
+# post-merge / tag-push testing, sane tag is set, FROM will be set 'unknown'
+test_is_release "unknown" "unknown" "0.0.0" "0" "Found \$RELVER 0.0.0"
+# hack/get_ci_vm or PR testing, FROM and TO are set, no tag is set
+test_is_release "x" "x" "" "1" ""
-# Negative-testing git with this function is very difficult, assume it works
+# Negative-testing git with this function is very difficult, assume git works
# test_is_release ... "is_release() failed to fetch tags"
# test_is_release ... "is_release() failed to parse tags"