From b62eff9e0c76dcdab094bf9fe32355c543ea909f Mon Sep 17 00:00:00 2001 From: giraffedata Date: Mon, 6 Dec 2021 03:35:30 +0000 Subject: Add maze.pbm test image, update tests to use it git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@4200 9d0c8265-081b-0410-96cb-a4ca84ce46f8 --- test/targa-roundtrip.test | 27 ++++++++++----------------- 1 file changed, 10 insertions(+), 17 deletions(-) (limited to 'test/targa-roundtrip.test') diff --git a/test/targa-roundtrip.test b/test/targa-roundtrip.test index 79b01b61..39ea8bd7 100755 --- a/test/targa-roundtrip.test +++ b/test/targa-roundtrip.test @@ -4,24 +4,21 @@ tmpdir=${tmpdir:-/tmp} -#Test 1: Should print 2425386270 41, cksum of testgrid.pbm, ten times - -echo "Test 1" +echo "Test 1: Should print 281226646 481, cksum of maze.pbm, ten times" for mode in "-mono" "-mono -norle" \ "-cmap" "-cmap -norle" "-cmap16" "-cmap16 -norle" \ "-rgb" "-rgb -norle" "" "-norle" do - pamtotga ${mode} testgrid.pbm | \ + pamtotga ${mode} maze.pbm | \ tgatoppm | ppmtopgm | \ pgmtopbm -threshold -val 0.5 | cksum done -#Test 2: Should produce 1571496937 33838, cksum of testimg.red, ten times - -echo "Test 2" +echo \ + "Test 2: Should produce 1571496937 33838, cksum of testimg.red, ten times" -test_pam=${tmpdir}/testimg.pgm +test_pam=${tmpdir}/testimg.pam pamchannel -infile=testimg.ppm -tupletype="GRAYSCALE" 0 > ${test_pam} for mode in "-mono" "-mono -norle" \ @@ -34,18 +31,15 @@ for mode in "-mono" "-mono -norle" \ rm ${test_pam} -#Test 3: Should print 1926073387 101484, cksum of testimg.ppm, four times - -echo "Test 3" +echo \ + "Test 3: Should print 1926073387 101484, cksum of testimg.ppm, four times" for mode in "-rgb" "-rgb -norle" "" "-norle" do pamtotga ${mode} testimg.ppm | tgatoppm | cksum done -#Test 4: Should print 0 six times - -echo "Test 4" +echo "Test 4: Should print 0 0 0 : 0 six times" test256_ppm=${tmpdir}/test256.ppm pnmquant 256 testimg.ppm > ${test256_ppm} || echo "pnmquant failed" @@ -58,9 +52,8 @@ for mode in "-rgb" "-rgb -norle" "-cmap" "-cmap -norle" "" "-norle" done -#Test 5: Should print 0 eight times - -echo "Test 5" +echo \ + "Test 5: Should print 0 0 0 : 0 twice, then 0 0 0 0 : 0 six times" test256_31_ppm=${tmpdir}/test256-31.ppm pamdepth 31 ${test256_ppm} > ${test256_31_ppm} || echo "pamdepth failed" -- cgit 1.4.1