19 $this->filePath = __DIR__ .
'/../../data/media/';
32 $this->assertEquals( [
'UTF-8 JPEG Comment — ¼' ],
$res[
'COM'] );
37 [
'jpeg-comment-utf.jpg' ],
38 [
'jpeg-padding-even.jpg' ],
39 [
'jpeg-padding-odd.jpg' ],
46 $this->assertEquals( [
'ISO-8859-1 JPEG Comment - ¼' ],
$res[
'COM'] );
55 $this->assertEmpty(
$res[
'COM'] );
63 $this->assertEquals( [
'foo',
'bar' ],
$res[
'COM'] );
68 $expected = file_get_contents( $this->filePath .
'jpeg-xmp-psir.xmp' );
69 $this->assertEquals( $expected,
$res[
'XMP'] );
74 $expected =
'50686f746f73686f7020332e30003842494d04040000000'
75 .
'000181c02190004746573741c02190003666f6f1c020000020004';
76 $this->assertEquals( $expected, bin2hex(
$res[
'PSIR'][0] ) );
81 $expected = file_get_contents( $this->filePath .
'jpeg-xmp-psir.xmp' );
82 $this->assertEquals( $expected,
$res[
'XMP'] );
89 $this->assertEquals(
'iptc-no-hash',
$res );
96 $this->assertEquals(
'iptc-bad-hash',
$res );
103 $this->assertEquals(
'iptc-good-hash',
$res );
109 $this->assertEquals( $expected,
$res[
'byteOrder'] );
116 $this->setExpectedException(
'MWException' );
125 $this->setExpectedException(
'MWException' );