summaryrefslogtreecommitdiff
path: root/tests/lib
diff options
context:
space:
mode:
authorIan Jackson <ijackson@chiark.greenend.org.uk>2022-12-27 12:59:40 +0000
committerIan Jackson <ijackson@chiark.greenend.org.uk>2022-12-28 13:28:56 +0000
commitac196dfca334e75dee55d8db132742959cafe740 (patch)
tree2723615058dc19cd226be6cfc98393004b0cd970 /tests/lib
parent748505d79d881ba89497a55cb15f5cdd52178dae (diff)
tests: Provide t-expect-push-fail-retriably
Our new checks on tainted objects will use this. Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
Diffstat (limited to 'tests/lib')
-rw-r--r--tests/lib7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/lib b/tests/lib
index c636f09..2f8d09c 100644
--- a/tests/lib
+++ b/tests/lib
@@ -165,6 +165,7 @@ t-expect-push-fail () {
t-reporefs pre-push
t-expect-fail "$mpat" "$@"
+ cp $tmp/t.output $tmp/t.push-output
t-reporefs post-push
diff $tmp/show-refs.{pre,post}-push
@@ -173,6 +174,12 @@ t-expect-push-fail () {
eval "$t_expect_push_fail_hook"
}
+t-expect-push-fail-retriably () {
+ t-expect-push-fail "$@"
+ grep 'You can retry the push, after fixing the problem, if you like' \
+ $tmp/t.push-output
+}
+
t-git-objects-not-present () {
# t-git-objects-not-present GITDIR|'' OBJID [...]
# specifying '' means the repo for package $p