chiark / gitweb /
Tests: Check that --deliberately-include-questionable-history actually works
[dgit.git] / tests / tests / debpolicy-newreject
index 7cf2a3a47357004ae2a6d22a66b25e2a94e26770..bf9824ac9cb82130bae41c78cde4864d3e1f6403 100755 (executable)
@@ -19,4 +19,26 @@ t-dgit build
 t-expect-fail 'forbidden for testing' \
 t-dgit push --new
 
+git reset --hard HEAD~
+git commit --allow-empty -m 'will vanish from NEW'
+t-dgit build
+t-dgit push --new
+
+t-policy-periodic
+
+# pretend it vanished from new:
+rm $tmp/incoming/*
+t-archive-none example
+touch -d 'last year' $tmp/git/$p.git
+
+t-policy-periodic
+
+git commit --allow-empty -m 'should require --deliberately...questionable'
+t-dgit build
+
+t-expect-fail 'tag debian/1.0 referred to this object.*all previously pushed versions were found to have been removed' \
+t-dgit push --new
+
+t-dgit push --new --deliberately-include-questionable-history
+
 echo xxx up to here