chiark / gitweb /
git-debrebase: test suite: gdr-import-dgit: move gbp import (nfc)
[dgit.git] / tests / tests / gdr-import-dgit
1 #!/bin/bash
2 set -e
3 . tests/lib
4
5 t-dependencies git-buildpackage libfile-fnmatch-perl
6
7 t-setup-import gdr-convert-gbp
8
9 cd $p
10
11 nmu-upload-1 () {
12         nmubranch=$1
13         git checkout -f -b $nmubranch
14         t-git-debrebase
15         t-git-debrebase convert-to-gbp
16         # now we are on a gbp patched-unapplied branch
17 }
18
19
20 nmu-upload-2 () {
21         t-dch-commit -v $v -m "nmu $nmubranch $v"
22         t-some-changes "nmu $numbranch $v"
23         t-dch-commit -r sid
24
25         t-dgit -wgf build-source
26
27         cd ..
28         c=${p}_${v}_source.changes
29         debsign -kBCD22CD83243B79D3DFAC33EA3DBCBC039B13D8A $c
30         dput -c $tmp/dput.cf test-dummy $c
31
32         t-archive-process-incoming sid
33 }
34
35 : 'non-dgit upload (but we prepare it with dgit anyway)'
36
37 v=2.0-2+nmu1
38 nmu-upload-1 nmu
39 gbp pq import
40 nmu-upload-2
41
42 : 'done the nmu, switching back to the maintainer hat'
43
44 cd $p
45 git checkout master
46 t-dgit fetch
47 git merge --ff-only dgit/dgit/sid
48
49 git diff --exit-code patch-queue/nmu
50
51 git branch t.before
52
53 t-git-debrebase
54 t-gdr-good laundered
55
56 t-git-debrebase stitch
57 t-gdr-good stitched
58
59 t-ok