summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorIan Jackson <ijackson@chiark.greenend.org.uk>2023-06-14 21:31:13 +0100
committerIan Jackson <ijackson@chiark.greenend.org.uk>2023-06-14 22:00:31 +0100
commit2d914614233cd755166d63d0551d11c027516519 (patch)
treeaca57274ef183a28d35e84e0f7d117d24f23ca5a /tests
parent75f51308ebf63bc743f75eade60f719c5540eb4c (diff)
Abolish dgit-badcommit-fixup
git 2.40 rejects the bad commits. This means we can no longer conveniently test this script. And it also means it is not likely that such a bug would be reintroduced. So: * Delete the script. * Delete its test case and remove it from debian/tests/control. * No longer install it. * Remove the lintian suppression for its lack of manpage. Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
Diffstat (limited to 'tests')
-rwxr-xr-xtests/tests/badcommit-rewrite62
1 files changed, 0 insertions, 62 deletions
diff --git a/tests/tests/badcommit-rewrite b/tests/tests/badcommit-rewrite
deleted file mode 100755
index f116723..0000000
--- a/tests/tests/badcommit-rewrite
+++ /dev/null
@@ -1,62 +0,0 @@
-#!/bin/bash
-set -e
-. tests/lib
-
-t-setup-import examplegit
-t-tstunt-parsechangelog
-
-cd $tmp/git/$p.git
-git config core.sharedRepository true
-chmod -R g+w objects
-umask 022
-
-cd $tmp/example
-
-suite=stable
-
-t-commit 'No changes, just send to stable' '' stable
-
-t-make-badcommit
-git reset --hard $badcommit
-
-t-dgit -wgf build
-t-dgit push-built --overwrite=1.2 stable
-t-archive-process-incoming stable
-
-rstable=refs/remotes/dgit/dgit/stable
-
-t-dgit fetch stable
-t-has-parent-or-is $rstable $badcommit
-
-fixup=${DGIT_BADCOMMIT_FIXUP-dgit-badcommit-fixup}
-
-cd $tmp/git/$p.git
-git gc --aggressive --prune=all
-rmdir objects/* ||:
-
-$fixup --real
-
-cd $tmp/$p
-git symbolic-ref HEAD >../sym.before
-git rev-parse HEAD >../ref.before
-
-$fixup --real
-
-git symbolic-ref HEAD >../sym.after
-git rev-parse HEAD >../ref.after
-diff ../sym.before ../sym.after
-set +e; diff ../ref.before ../ref.after; rc=$?; set -e; test $rc = 1
-
-t-dgit fetch stable
-
-t-expect-fail "child $rstable lacks parent $badcommit" \
-t-has-parent-or-is $rstable $badcommit
-
-check_shared () {
- find "$1" -perm -200 \! -perm -020 -ls |tee $tmp/badperm
- test -f $tmp/badperm -a ! -s $tmp/badperm
-}
-
-check_shared $tmp/git/$p.git/objects
-
-t-ok