diff options
Diffstat (limited to 'test/integration/test-method-rred')
-rwxr-xr-x | test/integration/test-method-rred | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/test/integration/test-method-rred b/test/integration/test-method-rred index 5a885e9d2..00b4b7c0b 100755 --- a/test/integration/test-method-rred +++ b/test/integration/test-method-rred @@ -195,3 +195,40 @@ Package: supercoolstuff failrred 'Wrong order of commands' '7d 17d' failrred 'End before start' '7,6d' + +# deal correctly with patch merging +mergepatches() { + testsuccess runapt "${METHODSDIR}/rred" Packages.ed-* + cp -a rootdir/tmp/testsuccess.output patch.ed + testfileequal 'patch.ed' "$1" +} +createpatch() { + echo "$2" +} + +createpatch 'Change dog to cat + kitties' '19c + And a cat! + +Package: extra-kittens +Version: unavailable +Description: fix later +.' > Packages.ed-0 +createpatch 'Remove more stuff and fix later' '23d, +6d' > Packages.ed-1 +createpatch 'Remove (old) dog paragraph' '10,19d' > Packages.ed-2 +mergepatches '11,19c +Package: extra-kittens +Version: unavailable +. +6d' +testrred 'Apply' 'merged patch' "$(cat patch.ed)" 'Package: coolstuff +Version: 0.8.15 +Description: collection of stuff + A lot, too much to iterate all, but at least this: + - stuff + - even more stuff + . + And a cow. + +Package: extra-kittens +Version: unavailable' |