diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2017-07-08 22:23:50 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2017-07-08 22:23:50 +0000 |
commit | 0ad98b7828165b438ee4d17e43fdbe72223abfb6 (patch) | |
tree | 579ebb403f8bf80f2dbb86b7afe85f1276aa7296 | |
parent | 6b7a1ddc5d4573b25a61ad232c38b92d4980c03d (diff) | |
download | netpbm-mirror-0ad98b7828165b438ee4d17e43fdbe72223abfb6.tar.gz netpbm-mirror-0ad98b7828165b438ee4d17e43fdbe72223abfb6.tar.xz netpbm-mirror-0ad98b7828165b438ee4d17e43fdbe72223abfb6.zip |
Pnmquantall test: Remove temporary files
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@3030 9d0c8265-081b-0410-96cb-a4ca84ce46f8
-rw-r--r-- | test/pnmquantall.ok | 6 | ||||
-rwxr-xr-x | test/pnmquantall.test | 20 |
2 files changed, 18 insertions, 8 deletions
diff --git a/test/pnmquantall.ok b/test/pnmquantall.ok index bd5bbc05..172eb0aa 100644 --- a/test/pnmquantall.ok +++ b/test/pnmquantall.ok @@ -1,5 +1,5 @@ got color map -2373957371 33838 testimg.red -3892560659 33838 testimg.grn -1383839923 33838 testimg.blu +2373957371 33838 +3892560659 33838 +1383839923 33838 1 diff --git a/test/pnmquantall.test b/test/pnmquantall.test index 7d9ddf82..cd01bb8d 100755 --- a/test/pnmquantall.test +++ b/test/pnmquantall.test @@ -2,16 +2,26 @@ # This script tests: pnmquantall # Also requires: ppmtorgb3 pgmhist -ppmtorgb3 testimg.ppm +tmpdir=${tmpdir:-/tmp} +test_ppm=${tmpdir}/testimg.ppm -pnmquantall 20 testimg.red testimg.grn testimg.blu +cp testimg.ppm ${tmpdir} && +ppmtorgb3 ${test_ppm} -for i in testimg.red testimg.grn testimg.blu +test_red=${tmpdir}/testimg.red +test_grn=${tmpdir}/testimg.grn +test_blu=${tmpdir}/testimg.blu + +pnmquantall 20 ${test_red} ${test_grn} ${test_blu} + +for i in ${test_red} ${test_grn} ${test_blu} do -cksum $i +cat $i | cksum done # Should print 1 -pnmcat testimg.red testimg.grn testimg.blu -tb | \ +pnmcat ${test_red} ${test_grn} ${test_blu} -tb | \ pgmhist -m | awk '$2>0 {s++}; END { print (s<=20) }' + +rm ${test_red} ${test_grn} ${test_blu} ${test_ppm} \ No newline at end of file |