summaryrefslogtreecommitdiffstats
path: root/tests/imgPPM.test
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2013-11-03 11:33:26 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2013-11-03 11:33:26 (GMT)
commit7ded508e048d5e2df7f3c81b053ceeb9521f61ec (patch)
tree4a2849681d065fc10389b6fb902117fb2c4b3a2d /tests/imgPPM.test
parenta839e8bd1116069997b2e67a866505afa34c623a (diff)
parentb6582079d155de64ebb161f0e9a334c7e980f448 (diff)
downloadtk-7ded508e048d5e2df7f3c81b053ceeb9521f61ec.zip
tk-7ded508e048d5e2df7f3c81b053ceeb9521f61ec.tar.gz
tk-7ded508e048d5e2df7f3c81b053ceeb9521f61ec.tar.bz2
[1632447]: Allow the PPM maxval to go up to 65535, to conform with a format
definition change from around 2000 (even if that's a rare format).
Diffstat (limited to 'tests/imgPPM.test')
-rw-r--r--tests/imgPPM.test11
1 files changed, 7 insertions, 4 deletions
diff --git a/tests/imgPPM.test b/tests/imgPPM.test
index 456427f..b5955df 100644
--- a/tests/imgPPM.test
+++ b/tests/imgPPM.test
@@ -21,7 +21,7 @@ proc put {file data} {
puts -nonewline $f $data
close $f
}
-
+
test imgPPM-1.1 {FileReadPPM procedure} -body {
put test.ppm "P6\n0 256\n255\nabcdef"
image create photo p1 -file test.ppm
@@ -39,9 +39,9 @@ test imgPPM-1.4 {FileReadPPM procedure} -body {
image create photo p1 -file test.ppm
} -returnCodes error -result {PPM image file "test.ppm" has dimension(s) <= 0}
test imgPPM-1.5 {FileReadPPM procedure} -body {
- put test.ppm "P6\n10 20\n256\nabcdef"
+ put test.ppm "P6\n10 20\n100000\nabcdef"
image create photo p1 -file test.ppm
-} -returnCodes error -result {PPM image file "test.ppm" has bad maximum intensity value 256}
+} -returnCodes error -result {PPM image file "test.ppm" has bad maximum intensity value 100000}
test imgPPM-1.6 {FileReadPPM procedure} -body {
put test.ppm "P6\n10 20\n0\nabcdef"
image create photo p1 -file test.ppm
@@ -161,7 +161,7 @@ test imgPPM-4.1 {StringReadPPM procedure, data too short [Bug 1822391]} -body {
} -cleanup {
image delete I
} -returnCodes error -result {truncated PPM data}
-
+
imageFinish
# cleanup
@@ -169,3 +169,6 @@ catch {file delete test.ppm}
cleanupTests
return
+# Local Variables:
+# mode: tcl
+# End: