chiark / gitweb /
git-debrebase: test suite: gdr-import-dgit: introduce nmu-upload-1, -2
[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         gbp pq import
22
23         t-dch-commit -v $v -m "nmu $nmubranch $v"
24         t-some-changes "nmu $numbranch $v"
25         t-dch-commit -r sid
26
27         t-dgit -wgf build-source
28
29         cd ..
30         c=${p}_${v}_source.changes
31         debsign -kBCD22CD83243B79D3DFAC33EA3DBCBC039B13D8A $c
32         dput -c $tmp/dput.cf test-dummy $c
33
34         t-archive-process-incoming sid
35 }
36
37 : 'non-dgit upload (but we prepare it with dgit anyway)'
38
39 v=2.0-2+nmu1
40 nmu-upload-1 nmu
41 nmu-upload-2
42
43 : 'done the nmu, switching back to the maintainer hat'
44
45 cd $p
46 git checkout master
47 t-dgit fetch
48 git merge --ff-only dgit/dgit/sid
49
50 git diff --exit-code patch-queue/nmu
51
52 git branch t.before
53
54 t-git-debrebase
55 t-gdr-good laundered
56
57 t-git-debrebase stitch
58 t-gdr-good stitched
59
60 t-ok