diff options
author | Florian Pritz <bluewind@xinu.at> | 2014-10-07 14:43:32 +0200 |
---|---|---|
committer | Florian Pritz <bluewind@xinu.at> | 2015-05-27 15:46:05 +0200 |
commit | 83350c1fd555fb474a0572f639cc8364260f180a (patch) | |
tree | 40251649fad43d080b9e0ebe491370ab449e48ec | |
parent | ac0f4dc27423712cccb0cf30dd9a589f55ce5918 (diff) | |
download | dbscripts-83350c1fd555fb474a0572f639cc8364260f180a.tar.gz dbscripts-83350c1fd555fb474a0572f639cc8364260f180a.tar.xz |
make tests.d/db-remove work
Signed-off-by: Florian Pritz <bluewind@xinu.at>
-rwxr-xr-x | test/test.d/db-remove.sh | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/test/test.d/db-remove.sh b/test/test.d/db-remove.sh index 0a9a386..6905821 100755 --- a/test/test.d/db-remove.sh +++ b/test/test.d/db-remove.sh @@ -6,6 +6,7 @@ curdir=$(readlink -e $(dirname $0)) testRemovePackages() { local arches=('i686' 'x86_64') local pkgs=('pkg-simple-a' 'pkg-simple-b' 'pkg-split-a' 'pkg-split-b' 'pkg-simple-epoch') + local pkgnames=('pkg-simple-a' 'pkg-simple-b' 'pkg-split-a'{1,2} 'pkg-split-b'{1,2} 'pkg-simple-epoch') local pkgbase local arch @@ -17,12 +18,12 @@ testRemovePackages() { ../db-update - for pkgbase in ${pkgs[@]}; do + for pkgname in ${pkgnames[@]}; do for arch in ${arches[@]}; do # TODO: removing pkg-split-a/pkg-split-b won't work because # db-remove only removes single packages, not a group of split # packages. do we want that? - ../db-remove extra ${arch} ${pkgbase} + ../db-remove extra ${arch} ${pkgname} done done @@ -31,11 +32,18 @@ testRemovePackages() { checkRemovedPackage extra ${pkgbase} ${arch} done done + + for pkgname in ${pkgnames[@]}; do + for arch in ${arches[@]}; do + checkRemovedPackage extra ${pkgname} ${arch} + done + done } testRemoveMultiplePackages() { local arches=('i686' 'x86_64') local pkgs=('pkg-simple-a' 'pkg-simple-b' 'pkg-split-a' 'pkg-split-b' 'pkg-simple-epoch') + local pkgnames=('pkg-simple-a' 'pkg-simple-b' 'pkg-split-a'{1,2} 'pkg-split-b'{1,2} 'pkg-simple-epoch') local pkgbase local arch @@ -51,7 +59,7 @@ testRemoveMultiplePackages() { # TODO: removing pkg-split-a/pkg-split-b won't work because # db-remove only removes single packages, not a group of split # packages. do we want that? - ../db-remove extra ${arch} ${pkgs[@]} + ../db-remove extra ${arch} ${pkgnames[@]} done for pkgbase in ${pkgs[@]}; do @@ -59,6 +67,12 @@ testRemoveMultiplePackages() { checkRemovedPackage extra ${pkgbase} ${arch} done done + + for pkgname in ${pkgnames[@]}; do + for arch in ${arches[@]}; do + checkRemovedPackage extra ${pkgname} ${arch} + done + done } testRemoveAnyPackages() { |