summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Jackson <ijackson@chiark.greenend.org.uk>2018-06-22 17:34:50 +0100
committerIan Jackson <ijackson@chiark.greenend.org.uk>2018-06-22 17:36:18 +0100
commit03234a4d7d5c99e71fb0f1447acdb2241d58c7d8 (patch)
tree82d02a217d8548eb75399ade46573b9de7ee37ca
parent866feb162b8f7e84039ed80e206c0df0def5f6c5 (diff)
test suite: lib-gdr: t-some-changes: Honour $2 `dum'
This allows for less thorough but faster test cases. Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
-rw-r--r--tests/lib-gdr33
1 files changed, 23 insertions, 10 deletions
diff --git a/tests/lib-gdr b/tests/lib-gdr
index 9eb7537..7b4f085 100644
--- a/tests/lib-gdr
+++ b/tests/lib-gdr
@@ -155,21 +155,34 @@ t-gdr-good () {
t-some-changes () {
local token=$1
+ local which=${2-dum}
t-git-next-date
- echo >>debian/zorkmid "// debian $token"
- git add debian/zorkmid
- git commit -m "DEBIAN add zorkmid ($token)"
+ case "$which" in
+ *d*)
+ echo >>debian/zorkmid "// debian $token"
+ git add debian/zorkmid
+ git commit -m "DEBIAN add zorkmid ($token)"
+ ;;
+ esac
- echo >>src.c "// upstream $token"
- git commit -a -m "UPSTREAM edit src.c ($token)"
+ case "$which" in
+ *u*)
+ echo >>src.c "// upstream $token"
+ git commit -a -m "UPSTREAM edit src.c ($token)"
+ ;;
+ esac
- for f in debian/zorkmid src.c; do
- echo "// both! $token" >>$f
- git add $f
- done
- git commit -m "MIXED add both ($token)"
+ case "$which" in
+ *m*)
+ for f in debian/zorkmid src.c; do
+ echo "// both! $token" >>$f
+ git add $f
+ done
+ git commit -m "MIXED add both ($token)"
+ ;;
+ esac
t-git-next-date
}