summaryrefslogtreecommitdiff
path: root/ext/exif/tests
diff options
context:
space:
mode:
Diffstat (limited to 'ext/exif/tests')
-rwxr-xr-xext/exif/tests/bug34704.jpgbin9976 -> 0 bytes
-rwxr-xr-xext/exif/tests/bug34704.phpt43
-rw-r--r--ext/exif/tests/exif000.phpt57
-rw-r--r--ext/exif/tests/exif001.phpt84
-rw-r--r--ext/exif/tests/exif002.phpt24
-rw-r--r--ext/exif/tests/exif003.phpt91
-rw-r--r--ext/exif/tests/exif004.phpt38
-rw-r--r--ext/exif/tests/exif005.phpt22
-rw-r--r--ext/exif/tests/exif006.phpt89
-rw-r--r--ext/exif/tests/test1.jpgbin523 -> 0 bytes
-rw-r--r--ext/exif/tests/test2.jpgbin1240 -> 0 bytes
-rw-r--r--ext/exif/tests/test3.jpgbin1240 -> 0 bytes
-rw-r--r--ext/exif/tests/test4.jpgbin713 -> 0 bytes
-rw-r--r--ext/exif/tests/test5.jpgbin603 -> 0 bytes
-rw-r--r--ext/exif/tests/test6.jpgbin1240 -> 0 bytes
15 files changed, 0 insertions, 448 deletions
diff --git a/ext/exif/tests/bug34704.jpg b/ext/exif/tests/bug34704.jpg
deleted file mode 100755
index 42b14c1908..0000000000
--- a/ext/exif/tests/bug34704.jpg
+++ /dev/null
Binary files differ
diff --git a/ext/exif/tests/bug34704.phpt b/ext/exif/tests/bug34704.phpt
deleted file mode 100755
index b6b26de78d..0000000000
--- a/ext/exif/tests/bug34704.phpt
+++ /dev/null
@@ -1,43 +0,0 @@
---TEST--
-Bug #34704 (Infinite recursion due to corrupt JPEG)
---SKIPIF--
-<?php if (!extension_loaded('exif')) print 'skip exif extension not available';?>
---INI--
-magic_quotes_runtime=0
-output_handler=
-zlib.output_compression=0
---FILE--
-<?php
-$infile = dirname(__FILE__).'/bug34704.jpg';
-var_dump(exif_read_data($infile));
-?>
-===DONE===
---EXPECTF--
-array(7) {
- ["FileName"]=>
- string(12) "bug34704.jpg"
- ["FileDateTime"]=>
- int(%d)
- ["FileSize"]=>
- int(9976)
- ["FileType"]=>
- int(2)
- ["MimeType"]=>
- string(10) "image/jpeg"
- ["SectionsFound"]=>
- string(4) "IFD0"
- ["COMPUTED"]=>
- array(5) {
- ["html"]=>
- string(24) "width="386" height="488""
- ["Height"]=>
- int(488)
- ["Width"]=>
- int(386)
- ["IsColor"]=>
- int(1)
- ["ByteOrderMotorola"]=>
- int(0)
- }
-}
-===DONE===
diff --git a/ext/exif/tests/exif000.phpt b/ext/exif/tests/exif000.phpt
deleted file mode 100644
index eea16438cf..0000000000
--- a/ext/exif/tests/exif000.phpt
+++ /dev/null
@@ -1,57 +0,0 @@
---TEST--
-Check for exif_read_data default behaviour
---SKIPIF--
-<?php if (!extension_loaded('exif')) print 'skip exif extension not available';?>
---INI--
-output_handler=
-zlib.output_compression=0
---FILE--
-<?php
-/*
- test1.jpg is a 1*1 image that does not contain any Exif/Comment information
- test2.jpg is the same image but contains Exif/Comment information and a
- copy of test1.jpg as a thumbnail.
-*/
-print_r(exif_read_data(dirname(__FILE__).'/test2.jpg'));
-?>
---EXPECTF--
-Array
-(
- [FileName] => test2.jpg
- [FileDateTime] => %d
- [FileSize] => 1240
- [FileType] => 2
- [MimeType] => image/jpeg
- [SectionsFound] => ANY_TAG, IFD0, THUMBNAIL, COMMENT
- [COMPUTED] => Array
- (
- [html] => width="1" height="1"
- [Height] => 1
- [Width] => 1
- [IsColor] => 1
- [ByteOrderMotorola] => 1
- [UserComment] => Exif test image.
- [UserCommentEncoding] => ASCII
- [Copyright] => Photo (c) M.Boerger, Edited by M.Boerger.
- [Copyright.Photographer] => Photo (c) M.Boerger
- [Copyright.Editor] => Edited by M.Boerger.
- [Thumbnail.FileType] => 2
- [Thumbnail.MimeType] => image/jpeg
- )
-
- [Copyright] => Photo (c) M.Boerger
- [UserComment] => ASCII
- [THUMBNAIL] => Array
- (
- [JPEGInterchangeFormat] => 134
- [JPEGInterchangeFormatLength] => 523
- )
-
- [COMMENT] => Array
- (
- [0] => Comment #1.
- [1] => Comment #2.
- [2] => Comment #3end
- )
-
-)
diff --git a/ext/exif/tests/exif001.phpt b/ext/exif/tests/exif001.phpt
deleted file mode 100644
index 8fac4286ca..0000000000
--- a/ext/exif/tests/exif001.phpt
+++ /dev/null
@@ -1,84 +0,0 @@
---TEST--
-Check for exif_read_data
---SKIPIF--
-<?php if (!extension_loaded('exif')) print 'skip exif extension not available';?>
---INI--
-output_handler=
-zlib.output_compression=0
---FILE--
-<?php
-/*
- test1.jpg is a 1*1 image that does not contain any Exif/Comment information
- test2.jpg is the same image but contains Exif/Comment information and a
- copy of test1.jpg as a thumbnail.
-*/
-var_dump(exif_read_data(dirname(__FILE__).'/test2.jpg','',true,false));
-?>
---EXPECTF--
-array(5) {
- ["FILE"]=>
- array(6) {
- ["FileName"]=>
- string(9) "test2.jpg"
- ["FileDateTime"]=>
- int(%d)
- ["FileSize"]=>
- int(1240)
- ["FileType"]=>
- int(2)
- ["MimeType"]=>
- string(10) "image/jpeg"
- ["SectionsFound"]=>
- string(33) "ANY_TAG, IFD0, THUMBNAIL, COMMENT"
- }
- ["COMPUTED"]=>
- array(12) {
- ["html"]=>
- string(20) "width="1" height="1""
- ["Height"]=>
- int(1)
- ["Width"]=>
- int(1)
- ["IsColor"]=>
- int(1)
- ["ByteOrderMotorola"]=>
- int(1)
- ["UserComment"]=>
- string(16) "Exif test image."
- ["UserCommentEncoding"]=>
- string(5) "ASCII"
- ["Copyright"]=>
- string(41) "Photo (c) M.Boerger, Edited by M.Boerger."
- ["Copyright.Photographer"]=>
- string(19) "Photo (c) M.Boerger"
- ["Copyright.Editor"]=>
- string(20) "Edited by M.Boerger."
- ["Thumbnail.FileType"]=>
- int(2)
- ["Thumbnail.MimeType"]=>
- string(10) "image/jpeg"
- }
- ["IFD0"]=>
- array(2) {
- ["Copyright"]=>
- string(19) "Photo (c) M.Boerger"
- ["UserComment"]=>
- string(5) "ASCII"
- }
- ["THUMBNAIL"]=>
- array(2) {
- ["JPEGInterchangeFormat"]=>
- int(134)
- ["JPEGInterchangeFormatLength"]=>
- int(523)
- }
- ["COMMENT"]=>
- array(3) {
- [0]=>
- string(11) "Comment #1."
- [1]=>
- string(11) "Comment #2."
- [2]=>
- string(13) "Comment #3end"
- }
-} \ No newline at end of file
diff --git a/ext/exif/tests/exif002.phpt b/ext/exif/tests/exif002.phpt
deleted file mode 100644
index 1b1220c600..0000000000
--- a/ext/exif/tests/exif002.phpt
+++ /dev/null
@@ -1,24 +0,0 @@
---TEST--
-Check for exif_thumbnail
---SKIPIF--
-<?php if (!extension_loaded('exif')) print 'skip exif extension not available';?>
---INI--
-magic_quotes_runtime=0
-output_handler=
-zlib.output_compression=0
---FILE--
-<?php
-/*
- test1.jpg is a 1*1 image that does not contain any Exif/Comment information
- test2.jpg is the same image but contains Exif/Comment information and a
- copy of test1.jpg as a thumbnail.
-*/
-$infile = dirname(__FILE__).'/test1.jpg';
-echo md5_file($infile).'_'.filesize($infile);
-$thumb = exif_thumbnail(dirname(__FILE__).'/test2.jpg');
-echo " == ";
-echo md5($thumb).'_'.strlen($thumb);
-echo "\n";
-?>
---EXPECT--
-27bbfd9fc10e1e663d749f5225447905_523 == 27bbfd9fc10e1e663d749f5225447905_523
diff --git a/ext/exif/tests/exif003.phpt b/ext/exif/tests/exif003.phpt
deleted file mode 100644
index 20cb61ee17..0000000000
--- a/ext/exif/tests/exif003.phpt
+++ /dev/null
@@ -1,91 +0,0 @@
---TEST--
-Check for exif_read_data, Unicode user comment
---SKIPIF--
-<?php
- if (!extension_loaded('exif')) die('skip exif extension not available');
- if (!extension_loaded('mbstring')) die('skip mbstring extension not available');
- if (!defined("EXIF_USE_MBSTRING") || !EXIF_USE_MBSTRING) die ('skip mbstring loaded by dl');
-?>
---INI--
-output_handler=
-zlib.output_compression=0
-exif.decode_unicode_motorola=UCS-2BE
-exif.encode_unicode=ISO-8859-15
---FILE--
-<?php
-/*
- test1.jpg is a 1*1 image that does not contain any Exif/Comment information
- test2.jpg is the same image but contains Exif/Comment information and a
- copy of test1.jpg as a thumbnail.
- test3.jpg is the same as test2.jpg but with a UNICODE UserComment: &Auml;&Ouml;&&Uuml;&szlig;&auml;&ouml;&uuml;
-*/
-var_dump(exif_read_data(dirname(__FILE__).'/test3.jpg','',true,false));
-?>
---EXPECTF--
-array(5) {
- ["FILE"]=>
- array(6) {
- ["FileName"]=>
- string(9) "test3.jpg"
- ["FileDateTime"]=>
- int(%s)
- ["FileSize"]=>
- int(1240)
- ["FileType"]=>
- int(2)
- ["MimeType"]=>
- string(10) "image/jpeg"
- ["SectionsFound"]=>
- string(33) "ANY_TAG, IFD0, THUMBNAIL, COMMENT"
- }
- ["COMPUTED"]=>
- array(12) {
- ["html"]=>
- string(20) "width="1" height="1""
- ["Height"]=>
- int(1)
- ["Width"]=>
- int(1)
- ["IsColor"]=>
- int(1)
- ["ByteOrderMotorola"]=>
- int(1)
- ["UserComment"]=>
- string(7) "ÄÖÜßäöü"
- ["UserCommentEncoding"]=>
- string(7) "UNICODE"
- ["Copyright"]=>
- string(41) "Photo (c) M.Boerger, Edited by M.Boerger."
- ["Copyright.Photographer"]=>
- string(19) "Photo (c) M.Boerger"
- ["Copyright.Editor"]=>
- string(20) "Edited by M.Boerger."
- ["Thumbnail.FileType"]=>
- int(2)
- ["Thumbnail.MimeType"]=>
- string(10) "image/jpeg"
- }
- ["IFD0"]=>
- array(2) {
- ["Copyright"]=>
- string(19) "Photo (c) M.Boerger"
- ["UserComment"]=>
- string(7) "UNICODE"
- }
- ["THUMBNAIL"]=>
- array(2) {
- ["JPEGInterchangeFormat"]=>
- int(134)
- ["JPEGInterchangeFormatLength"]=>
- int(523)
- }
- ["COMMENT"]=>
- array(3) {
- [0]=>
- string(11) "Comment #1."
- [1]=>
- string(11) "Comment #2."
- [2]=>
- string(13) "Comment #3end"
- }
-} \ No newline at end of file
diff --git a/ext/exif/tests/exif004.phpt b/ext/exif/tests/exif004.phpt
deleted file mode 100644
index 229f49e145..0000000000
--- a/ext/exif/tests/exif004.phpt
+++ /dev/null
@@ -1,38 +0,0 @@
---TEST--
-Check for exif_read_data, Unicode WinXP tags
---SKIPIF--
-<?php
- if (!extension_loaded('exif')) die('skip exif extension not available');
- if (!extension_loaded('mbstring')) die('skip mbstring extension not available');
- if (!defined("EXIF_USE_MBSTRING") || !EXIF_USE_MBSTRING) die ('skip mbstring loaded by dl');
-?>
---INI--
-output_handler=
-zlib.output_compression=0
-exif.decode_unicode_intel=UCS-2LE
-exif.decode_unicode_motorola=UCS-2BE
-exif.encode_unicode=ISO-8859-1
---FILE--
-<?php
-/*
- test4.jpg is a 1*1 image that contains Exif tags written by WindowsXP
-*/
-$image = exif_read_data(dirname(__FILE__).'/test4.jpg','',true,false);
-echo var_dump($image['WINXP']);
-?>
---EXPECT--
-array(5) {
- ["Subject"]=>
- string(10) "Subject..."
- ["Keywords"]=>
- string(11) "Keywords..."
- ["Author"]=>
- string(9) "Rui Carmo"
- ["Comments"]=>
- string(29) "Comments
-Line2
-Line3
-Line4"
- ["Title"]=>
- string(8) "Title..."
-}
diff --git a/ext/exif/tests/exif005.phpt b/ext/exif/tests/exif005.phpt
deleted file mode 100644
index e34e3a0421..0000000000
--- a/ext/exif/tests/exif005.phpt
+++ /dev/null
@@ -1,22 +0,0 @@
---TEST--
-Check for exif_read_data, unusual IFD start
---SKIPIF--
-<?php if (!extension_loaded('exif')) print 'skip exif extension not available';?>
---INI--
-output_handler=
-zlib.output_compression=0
---FILE--
-<?php
-/* Do not change this test it is a README.TESTING example.
- * test5.jpg is a 1*1 image that contains an Exif section with ifd = 00000009h
- */
-$image = exif_read_data(dirname(__FILE__).'/test5.jpg','',true,false);
-var_dump($image['IFD0']);
-?>
---EXPECT--
-array(2) {
- ["ImageDescription"]=>
- string(11) "Ifd00000009"
- ["DateTime"]=>
- string(19) "2002:10:18 20:06:00"
-} \ No newline at end of file
diff --git a/ext/exif/tests/exif006.phpt b/ext/exif/tests/exif006.phpt
deleted file mode 100644
index bad74ee4fa..0000000000
--- a/ext/exif/tests/exif006.phpt
+++ /dev/null
@@ -1,89 +0,0 @@
---TEST--
-Check for exif_read_data, magic_quotes_runtime
---SKIPIF--
-<?php
- if (!extension_loaded('exif')) die('skip exif extension not available');
- if (version_compare(PHP_VERSION, "4.4.0-dev", "<")) die('skip PHP 4.4 required');
-?>
---INI--
-output_handler=
-zlib.output_compression=0
-magic_quotes_runtime=1
---FILE--
-<?php
-/*
- test1.jpg is a 1*1 image that does not contain any Exif/Comment information
- test2.jpg is the same image but contains Exif/Comment information and a
- copy of test1.jpg as a thumbnail.
- test6.jpg is the same as test2.jpg but with a UNICODE UserComment: &Auml;&Ouml;&&Uuml;&szlig;&auml;&ouml;&uuml;
-*/
-var_dump(exif_read_data(dirname(__FILE__).'/test6.jpg','',true,false));
-?>
---EXPECTF--
-array(5) {
- ["FILE"]=>
- array(6) {
- ["FileName"]=>
- string(9) "test6.jpg"
- ["FileDateTime"]=>
- int(%d)
- ["FileSize"]=>
- int(1240)
- ["FileType"]=>
- int(2)
- ["MimeType"]=>
- string(10) "image/jpeg"
- ["SectionsFound"]=>
- string(33) "ANY_TAG, IFD0, THUMBNAIL, COMMENT"
- }
- ["COMPUTED"]=>
- array(12) {
- ["html"]=>
- string(24) "width=\"1\" height=\"1\""
- ["Height"]=>
- int(1)
- ["Width"]=>
- int(1)
- ["IsColor"]=>
- int(1)
- ["ByteOrderMotorola"]=>
- int(1)
- ["UserComment"]=>
- string(16) "Hallo \'Du\'+da!"
- ["UserCommentEncoding"]=>
- string(5) "ASCII"
- ["Copyright"]=>
- string(45) "Photo \"M. Boerger\"., Edited \'M. Boerger\'."
- ["Copyright.Photographer"]=>
- string(21) "Photo \"M. Boerger\"."
- ["Copyright.Editor"]=>
- string(22) "Edited \'M. Boerger\'."
- ["Thumbnail.FileType"]=>
- int(2)
- ["Thumbnail.MimeType"]=>
- string(10) "image/jpeg"
- }
- ["IFD0"]=>
- array(2) {
- ["Copyright"]=>
- string(21) "Photo \"M. Boerger\"."
- ["UserComment"]=>
- string(5) "ASCII"
- }
- ["THUMBNAIL"]=>
- array(2) {
- ["JPEGInterchangeFormat"]=>
- int(134)
- ["JPEGInterchangeFormatLength"]=>
- int(523)
- }
- ["COMMENT"]=>
- array(3) {
- [0]=>
- string(13) "Comment \"1\""
- [1]=>
- string(13) "Comment \'2\'"
- [2]=>
- string(13) "Comment #3end"
- }
-}
diff --git a/ext/exif/tests/test1.jpg b/ext/exif/tests/test1.jpg
deleted file mode 100644
index 121decb65a..0000000000
--- a/ext/exif/tests/test1.jpg
+++ /dev/null
Binary files differ
diff --git a/ext/exif/tests/test2.jpg b/ext/exif/tests/test2.jpg
deleted file mode 100644
index f60ecded6f..0000000000
--- a/ext/exif/tests/test2.jpg
+++ /dev/null
Binary files differ
diff --git a/ext/exif/tests/test3.jpg b/ext/exif/tests/test3.jpg
deleted file mode 100644
index 7547a16630..0000000000
--- a/ext/exif/tests/test3.jpg
+++ /dev/null
Binary files differ
diff --git a/ext/exif/tests/test4.jpg b/ext/exif/tests/test4.jpg
deleted file mode 100644
index 8a23a7b658..0000000000
--- a/ext/exif/tests/test4.jpg
+++ /dev/null
Binary files differ
diff --git a/ext/exif/tests/test5.jpg b/ext/exif/tests/test5.jpg
deleted file mode 100644
index d03cac18a3..0000000000
--- a/ext/exif/tests/test5.jpg
+++ /dev/null
Binary files differ
diff --git a/ext/exif/tests/test6.jpg b/ext/exif/tests/test6.jpg
deleted file mode 100644
index 073cefdfe0..0000000000
--- a/ext/exif/tests/test6.jpg
+++ /dev/null
Binary files differ