X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=dgit.git;a=blobdiff_plain;f=tests%2Fsetup%2Fgdr-convert-gbp;h=93ed4b60b028d4980dbfc772e2b90821cb4692f7;hp=d64b867c66653482c1ae030df1a3ecbe0f0e1019;hb=8381243a5f0a311bdf8ef2c8d695d7993de76a9d;hpb=a47f1af332372a372bf5758d1e3d9eeffe14acbd diff --git a/tests/setup/gdr-convert-gbp b/tests/setup/gdr-convert-gbp index d64b867c..93ed4b60 100755 --- a/tests/setup/gdr-convert-gbp +++ b/tests/setup/gdr-convert-gbp @@ -11,42 +11,18 @@ t-dependencies GDR t-tstunt-parsechangelog not-gdr-processable () { + git branch gdr-unprocessable/$1 t-git-debrebase analyse | grep 'Unknown Unprocessable' } -p=example -t-worktree 1.1 +t-gdr-gbp-import-core-with-queue -cd example - -: 'fake up some kind of upstream' -git checkout -b upstream quilt-tip -rm -rf debian -mkdir debian -echo junk >debian/rules -git add debian -git commit -m "an upstream retcon ($0)" - -: 'fake up that our quilt-tip was descended from upstream' -git checkout quilt-tip -git merge --no-edit -s ours upstream - -: 'fake up that our quilt-tip had the patch queue in it' -git checkout patch-queue/quilt-tip -gbp pq export -git add debian/patches -git commit -m "patch queue update ($0)" - -not-gdr-processable +not-gdr-processable origin : 'fake up an upstream 2.0' git branch make-upstream upstream t-make-new-upstream-tarball 2.0 -: 'make branch names more conventional' -git branch -D master -git branch -m quilt-tip master - for b in \ quilt-tip-2 \ gitish-only \ @@ -61,11 +37,15 @@ done git checkout master gbp import-orig --upstream-version=2.0 ../$ust -not-gdr-processable +not-gdr-processable merge t-dch-commit -v 2.0-1 -m 'new upstream (did gbp import-orig)' t-dch-commit-r +echo garbage >debian/patches/garbage +git add debian/patches/garbage +git commit -m 'add garbage' debian/patches/garbage + $ifarchive t-archive-none $p $ifarchive t-git-none $ifarchive t-dgit -wgf --gbp push-source --new @@ -80,8 +60,16 @@ git push --set-upstream origin master # debian/2.0-1 archive/debian/2.0-1 # remotes/origin/master remotes/dgit/dgit/sid +t-expect-fail E:'identical in upstream files' \ +t-git-debrebase -fupstream-has-debian convert-from-gbp upstream/2.0~ + +t-expect-fail E:'Unused patch file garbage will be discarded' \ t-git-debrebase -fupstream-has-debian convert-from-gbp +t-git-debrebase -fupstream-has-debian -funused-patches convert-from-gbp + +git branch converted-from-gbp + v=2.0-2 t-dch-commit -v $v -m 'switch to git-debrebase, no other changes' t-dch-commit-r @@ -99,5 +87,3 @@ t-setup-done '' "$(echo $p*) salsa $($ifarchive echo git mirror aq)" ' p=example t-git-next-date ' - -t-ok