4 TESTDIR
=$(readlink -f $(dirname $0)) 
   7 configarchitecture 
"i386" 
   8 confighashes 
'MD5' 'SHA1' 'SHA256' 'SHA512' 
  10 msgtest 
'Test apt-ftparchive source with missing hashes in .dsc' 
  12 touch aptarchive
/foo_1.0.
tar.gz
 
  13 cat > aptarchive
/foo_1.0.dsc 
<< EOF 
  22  d41d8cd98f00b204e9800998ecf8427e 0 foo_1.0.tar.gz 
  25 # check for the SHA hashes 
  26 testsuccess aptftparchive sources aptarchive
/ 
  27 cp rootdir
/tmp
/testsuccess.output aptarchive
/Sources
 
  28 testsuccess 
grep Checksums
-Sha512 aptarchive
/Sources
 
  30 for hash in sha512sum sha256sum 
sha1sum; do 
  31     for f 
in foo_1.0.
tar.gz foo_1.0.dsc
; do 
  32         SUM
=$($hash aptarchive/$f | cut -d' ' -f1) 
  33         NEEDLE
="$SUM $(stat -c%s aptarchive/$f) $f" 
  34         testsuccess 
test -n "$SUM" 
  35         msgtest 
"Test $hash hash matches for $f" 
  36         testsuccess 
--nomsg grep "$NEEDLE" aptarchive
/Sources