blob: 028f15c6b2ad618b612100d4e1058b1cc7af61d9 [file] [log] [blame]
cristy3ed852e2009-09-05 21:47:34 +00001#!/usr/bin/perl
cristy7e41fe82010-12-04 23:12:08 +00002# Copyright 1999-2011 ImageMagick Studio LLC, a non-profit organization
cristy3ed852e2009-09-05 21:47:34 +00003# dedicated to making software imaging solutions freely available.
4#
5# You may not use this file except in compliance with the License. You may
6# obtain a copy of the License at
7#
8# http://www.imagemagick.org/script/license.php
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15#
16# Test image blobs.
17#
18BEGIN { $| = 1; $test=1, print "1..1\n"; }
19END {print "not ok 1\n" unless $loaded;}
20use Image::Magick;
21$loaded=1;
22
23chdir 't' || die 'Cd failed';
24
25$image = new Image::Magick;
26$image->Read( 'input.miff' );
27@blob = $image->ImageToBlob();
28undef $image;
29
30$image=Image::Magick->new( magick=>'MIFF' );
31$image->BlobToImage( @blob );
32
33if ($image->Get('signature') ne
cristy11165b72011-09-28 17:26:49 +000034 '6a4a257921582768b774aeeac549b7c0c0b51f665395eddf921cce53a0ad2a33')
cristy3ed852e2009-09-05 21:47:34 +000035 { print "not ok $test\n"; }
36else
37 { print "ok $test\n"; }
38
391;