summaryrefslogtreecommitdiff
path: root/test/test.d/db-update.sh
diff options
context:
space:
mode:
Diffstat (limited to 'test/test.d/db-update.sh')
-rwxr-xr-xtest/test.d/db-update.sh15
1 files changed, 6 insertions, 9 deletions
diff --git a/test/test.d/db-update.sh b/test/test.d/db-update.sh
index c83d51b..48c243d 100755
--- a/test/test.d/db-update.sh
+++ b/test/test.d/db-update.sh
@@ -4,13 +4,12 @@ curdir=$(readlink -e "$(dirname "$0")")
. "${curdir}/../lib/common.inc"
testAddSimplePackages() {
- local arches=('i686' 'x86_64')
local pkgs=('pkg-simple-a' 'pkg-simple-b')
local pkgbase
local arch
for pkgbase in "${pkgs[@]}"; do
- for arch in "${arches[@]}"; do
+ for arch in "${ARCH_BUILD[@]}"; do
releasePackage extra "${pkgbase}" "${arch}"
done
done
@@ -18,7 +17,7 @@ testAddSimplePackages() {
../db-update
for pkgbase in "${pkgs[@]}"; do
- for arch in "${arches[@]}"; do
+ for arch in "${ARCH_BUILD[@]}"; do
checkPackage extra "${pkgbase}-1-1-${arch}.pkg.tar.xz" "${arch}"
done
done
@@ -52,14 +51,13 @@ testAddAnyPackages() {
}
testAddSplitPackages() {
- local arches=('i686' 'x86_64')
local pkgs=('pkg-split-a' 'pkg-split-b')
local pkg
local pkgbase
local arch
for pkgbase in "${pkgs[@]}"; do
- for arch in "${arches[@]}"; do
+ for arch in "${ARCH_BUILD[@]}"; do
releasePackage extra "${pkgbase}" "${arch}"
done
done
@@ -67,7 +65,7 @@ testAddSplitPackages() {
../db-update
for pkgbase in "${pkgs[@]}"; do
- for arch in "${arches[@]}"; do
+ for arch in "${ARCH_BUILD[@]}"; do
for pkg in "${pkgdir}/${pkgbase}"/*-"${arch}"${PKGEXT}; do
checkPackage extra "${pkg##*/}" "${arch}"
done
@@ -141,12 +139,11 @@ testUpdateSameAnyPackageToDifferentRepositories() {
testAddIncompleteSplitPackage() {
- local arches=('i686' 'x86_64')
local repo='extra'
local pkgbase='pkg-split-a'
local arch
- for arch in "${arches[@]}"; do
+ for arch in "${ARCH_BUILD[@]}"; do
releasePackage "${repo}" "${pkgbase}" "${arch}"
done
@@ -155,7 +152,7 @@ testAddIncompleteSplitPackage() {
../db-update >/dev/null 2>&1 && fail "db-update should fail when a split package is missing!"
- for arch in "${arches[@]}"; do
+ for arch in "${ARCH_BUILD[@]}"; do
( [ -r "${FTP_BASE}/${repo}/os/${arch}/${repo}${DBEXT%.tar.*}" ] \
&& bsdtar -xf "${FTP_BASE}/${repo}/os/${arch}/${repo}${DBEXT%.tar.*}" -O | grep -q "${pkgbase}") \
&& fail "${pkgbase} should not be in ${repo}/os/${arch}/${repo}${DBEXT%.tar.*}"