summaryrefslogtreecommitdiff
path: root/test/lib
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2010-08-13 09:47:31 +0200
committerPierre Schmitz <pierre@archlinux.de>2010-08-13 09:47:31 +0200
commita422060414670bb49d2422a38467b73ae01e7ecb (patch)
treef67c7216398ea6bf0aced46828235ca07fdbcf90 /test/lib
parente2c005b490df6762e23da3223944151c17d1de80 (diff)
Use common functions to print messages, warnings and errors
These functions are copied from makepkg
Diffstat (limited to 'test/lib')
-rw-r--r--test/lib/common.inc10
1 files changed, 4 insertions, 6 deletions
diff --git a/test/lib/common.inc b/test/lib/common.inc
index 795d01a..5c76eb5 100644
--- a/test/lib/common.inc
+++ b/test/lib/common.inc
@@ -6,7 +6,7 @@ oneTimeSetUp() {
local p
pkgdir="$(mktemp -d /dev/shm/$(basename $0).XXXXXXXXXX)"
cp -r ${curdir}/packages/* "${pkgdir}"
- echo -n 'Building packages...'
+ msg 'Building packages...'
for p in "${pkgdir}"/*; do
pushd $p >/dev/null
linux32 makepkg -cf --config ${curdir}/lib/makepkg-i686.conf >/dev/null 2>&1 || die 'makepkg failed'
@@ -15,7 +15,6 @@ oneTimeSetUp() {
|| die 'makepkg failed'
popd >/dev/null
done
- echo 'done'
echo
}
@@ -29,14 +28,14 @@ setUp() {
#[ -f "${curdir}/../config.local" ] && die "${curdir}/../config.local exists"
TMP="$(mktemp -d /dev/shm/$(basename $0).XXXXXXXXXX)"
- #echo "Using ${TMP}"
+ #msg "Using ${TMP}"
mkdir -p "${TMP}/"{ftp,tmp,staging,{package,source}-cleanup,svn-{packages,community}-{copy,repo}}
mkdir -p "${TMP}/ftp/"{core,extra,community,testing,community-testing}/os/{i686,any,x86_64}
mkdir -p "${TMP}/ftp/pool/"{packages,community}
mkdir -p "${TMP}/staging/"{core,extra,community,testing,community-testing}
- echo -n 'Creating svn repository...'
+ msg 'Creating svn repository...'
svnadmin create "${TMP}/svn-packages-repo"
svnadmin create "${TMP}/svn-community-repo"
svn checkout -q "file://${TMP}/svn-packages-repo" "${TMP}/svn-packages-copy"
@@ -49,7 +48,6 @@ setUp() {
svn add -q "${TMP}/svn-packages-copy"/${pkg}
svn commit -q -m"initial commit of ${pkg}" "${TMP}/svn-packages-copy"
done
- echo 'done'
cat <<eot > "${curdir}/../config.local"
FTP_BASE="${TMP}/ftp"
@@ -152,4 +150,4 @@ checkRemovedAnyPackage() {
svn up -q "${TMP}/svn-packages-copy/${pkgbase}"
[ -d "${TMP}/svn-packages-copy/${pkgbase}/repos/${repo}-any" ] \
&& fail "svn-packages-copy/${pkgbase}/repos/${repo}-any should not exist"
-} \ No newline at end of file
+}