#
# main()
#
-TESTDIR=$(readlink -f $(dirname $0))
-. $TESTDIR/framework
+TESTDIR="$(readlink -f "$(dirname "$0")")"
+. "$TESTDIR/framework"
setupenvironment
configarchitecture "i386"
confighashes 'MD5' 'SHA1' 'SHA256' 'SHA512'
msgtest 'generate with --db option'
cd aptarchive
-aptftparchive --db ./test.db sources pool/main/ -q=0 -o APT::FTPArchive::ShowCacheMisses=1 > dists/test/main/source/Sources 2>stats-out.txt && msgpass || msgfail
+aptftparchive --db ./test.db sources pool/main/ -o APT::FTPArchive::ShowCacheMisses=1 > dists/test/main/source/Sources 2>stats-out.txt && msgpass || msgfail
testsuccess grep Misses stats-out.txt
testfileequal '../rootdir/tmp/testsuccess.output' ' Misses in Cache: 2'
cd ..
msgtest 'generate with --db option (again to ensure its in the cache)'
cd aptarchive
-aptftparchive --db ./test.db sources pool/main/ -q=0 -o APT::FTPArchive::ShowCacheMisses=1 > dists/test/main/source/Sources 2>stats-out.txt && msgpass || msgfail
+aptftparchive --db ./test.db sources pool/main/ -o APT::FTPArchive::ShowCacheMisses=1 > dists/test/main/source/Sources 2>stats-out.txt && msgpass || msgfail
testsuccess grep Misses stats-out.txt
testfileequal '../rootdir/tmp/testsuccess.output' ' Misses in Cache: 0'
cd ..
EOF
msgtest 'generate (empty cachedb)'
-testsuccess aptftparchive generate apt-ftparchive.conf -q=0 -o APT::FTPArchive::ShowCacheMisses=1
+testsuccess aptftparchive generate apt-ftparchive.conf -o APT::FTPArchive::ShowCacheMisses=1
cp rootdir/tmp/testsuccess.output stats-out.txt
testsuccess grep Misses stats-out.txt
testfileequal rootdir/tmp/testsuccess.output ' Misses in Cache: 2'
msgtest 'generate again out of the cache'
rm -f ./aptarchive/dists/test/main/source/Sources
-testsuccess aptftparchive generate apt-ftparchive.conf -q=0 -o APT::FTPArchive::ShowCacheMisses=1
+testsuccess aptftparchive generate apt-ftparchive.conf -o APT::FTPArchive::ShowCacheMisses=1
cp rootdir/tmp/testsuccess.output stats-out.txt
testsuccess grep Misses stats-out.txt
testfileequal rootdir/tmp/testsuccess.output ' Misses in Cache: 0'
# ensure clean works
rm -f aptarchive/pool/main/*
-testsuccess aptftparchive clean apt-ftparchive.conf -q=0 -o Debug::APT::FTPArchive::Clean=1
+testsuccess aptftparchive clean apt-ftparchive.conf -o Debug::APT::FTPArchive::Clean=1
cp rootdir/tmp/testsuccess.output clean-out.txt
testsuccess grep unique clean-out.txt
testfileequal 'rootdir/tmp/testsuccess.output' "0 Number of unique keys in the tree"