phpDocumentor Exif
PHPUnit
[ class tree: Exif ] [ index: Exif ] [ all elements ]

Class: ExifHelperTest

Source Location: /modules/exif/test/phpunit/ExifHelperTest.class

Class ExifHelperTest

Class Overview

Test Exif Helper functionality

Located in /modules/exif/test/phpunit/ExifHelperTest.class [line 72]

TestCase
   |
   --GalleryTestCase
      |
      --ExifHelperTest
Author(s):
Information Tags:
Todo:  (xlerb) more tests, to be really sure, that our new underlying lib/JPEG does it's job well. This will ensure a working G2 even in case, lib/JPEG changes (especially because the lib/JPEG author has delegated some work on the lib to me). Also, there are plans to reduce include penalties for lib/JPEG. Let us protect against failures before actually changing the lib. And, by definition/specs, IPTC data may be spread throughout JPEG files, responsible to follow specs is the application writing IPTC data. Theoretically one could create mock files to test all variants of allowed (per spec) meta data distribution ... when I someday will be able to do that, I'll do for G2 (then as the author of the "final" EXIF/IPTC/XMP application and surely senior developer at Adobe Inc. :). Until then I'm happy to "keep G2 running" and fall back to just test common IPTC apps around and the correctness of lib/exifer and lib/JPEG to handle the resulting binaries. Tests to add are especially JPEG files manipulated by more than one IPTC capable application in turn, e.g. PS->Exifer->IrfanView. Also the current jpeg files are all produced on little endian machines. Small jpeg files produced on big endian machines and stored as big endian would provide for another neccessary test.

Properties

Methods

[ Top ]
Inherited Properties, Constants, and Methods
Inherited Properties Inherited Methods Inherited Constants

Inherited From GalleryTestCase

GalleryTestCase::$_cleanup

Inherited From GalleryTestCase

GalleryTestCase::GalleryTestCase()
GalleryTestCase::assert()
GalleryTestCase::assertEquals()
GalleryTestCase::assertErrorEquals()
Fail if the provided GalleryStatus object does not contain the given error code.
GalleryTestCase::assertEventFired()
Fail if the provided event name was not fired.
GalleryTestCase::assertEventNotFired()
Fail if the provided event name was fired
GalleryTestCase::DeepCompare()
GalleryTestCase::failWithStatus()
This is deprecated in Gallery 2.3 -- now tests should just return $ret and let the framework generate the right failure message.
GalleryTestCase::getEntityCounter()
Get the entity counter listener which contains the types and number of elements deleted.
GalleryTestCase::setUp()
GalleryTestCase::tearDown()
GalleryTestCase::_array_unshift_key_value()
Utility method to array_unshift a single key => value pair.
GalleryTestCase::_becomeGuestUser()
GalleryTestCase::_createDerivative()
GalleryTestCase::_createLinkedItem()
Create a random link item
GalleryTestCase::_createRandomAlbum()
Create a random album
GalleryTestCase::_createRandomDataItem()
Create a random data item
GalleryTestCase::_createRandomGroup()
Create a random group
GalleryTestCase::_createRandomUser()
Create a random user
GalleryTestCase::_createUser()
GalleryTestCase::_deleteAndVerifyEntity()
GalleryTestCase::_disableUserName()
Convenience method to mark a username as disabled.
GalleryTestCase::_getRootId()
GalleryTestCase::_getUnusedId()
Get an id that is not used for anything.
GalleryTestCase::_initEventListenersForTest()
Disable all but some core event listeners by default.
GalleryTestCase::_markEventListenersForCleanup()
Create a backup of the registered event listeners which will be restored in tearDown.
GalleryTestCase::_markFactoryForCleanup()
Create a backup of the factory data which will be restored in tearDown.
GalleryTestCase::_markFactoryModuleForCleanup()
GalleryTestCase::_markForCleanup()
GalleryTestCase::_markPluginParametersForCleanup()
Store plugin parameters to be restored in tearDown
GalleryTestCase::_markToolkitForCleanup()
GalleryTestCase::_registerEventListener()
Register a The NullEventListener for a test
GalleryTestCase::_registerFactoryImplementationForTest()
Register a factory implementation temporarily for this test.
GalleryTestCase::_registerTestEventListener()
Register and event name and associated listener (deprecated).
GalleryTestCase::_setMarkupType()
Set core parameter for markup type.
GalleryTestCase::_signUrl()
Adds an authToken to the given URL
GalleryTestCase::_unregisterFactoryImplementationForTest()
Unregister a specific factory implementation or all implementations of a spefific type temporarily for this test.
GalleryTestCase::_verifyEntity()
GalleryTestCase::_verifyFields()
GalleryTestCase::_verifyMissing()

[ Top ]
Property Summary
mixed   $_save  

[ Top ]
Method Summary
ExifHelperTest   ExifHelperTest()  
void   setUp()  
void   tearDown()  
void   testAddDefaultIptcPropertiesDetailed()   Test adding default detailed IPTC properties, as used on upgrade.
void   testAddDefaultIptcPropertiesSummary()   Test adding default summary IPTC properties, as used on upgrade.
void   testGetExifData()   Test getting EXIF data from a test file.
void   testGetExifDataWithEmbeddedScript()   Make sure that we sanitize EXIF data as if it were any other input data
void   testGetExifKeys()   Test getting all the EXIF keys
void   testGetIptcDataWithEmbeddedScript()   Make sure that we sanitize IPTC data as if it were any other input data
void   testGetRawIptcDataAdobe()   Test getting IPTC data from an Adobe test file, actually having real IPTC data (as opposed to only XMP data, which is not distinguishable in current Adobe products).
void   testGetRawIptcDataExifer()   Test getting IPTC data from an Exifer for Windows test file, see (http://www.exifer.friedemann.info/) which does not know about XMP data. The author reports problems with some PHP software, so let's make sure, we are doing things right.
void   testGetRawIptcDataIrfanView()   Test getting IPTC data from an IrfanView test file, see (http://www.irfanview.com/) which does not know about XMP data.
void   testGetRawIptcDataISO_8859_1()   Test getting IPTC data from a test file with ISO-8859-1 german umlauts inside. These must be converted to UTF-8.
void   testPostProcessKeys()   Check post processing code.
void   testPostProcessValueDoesSanitize()  

[ Top ]
Methods
Constructor ExifHelperTest  [line 76]

  ExifHelperTest ExifHelperTest( $methodName  )

Parameters:
   $methodName: 


[ Top ]
setUp  [line 80]

  void setUp( )



Redefinition of:
GalleryTestCase::setUp()

[ Top ]
tearDown  [line 113]

  void tearDown( )



Redefinition of:
GalleryTestCase::tearDown()

[ Top ]
testAddDefaultIptcPropertiesDetailed  [line 540]

  void testAddDefaultIptcPropertiesDetailed( )

Test adding default detailed IPTC properties, as used on upgrade.



[ Top ]
testAddDefaultIptcPropertiesSummary  [line 499]

  void testAddDefaultIptcPropertiesSummary( )

Test adding default summary IPTC properties, as used on upgrade.



[ Top ]
testGetExifData  [line 139]

  void testGetExifData( )

Test getting EXIF data from a test file.



[ Top ]
testGetExifDataWithEmbeddedScript  [line 178]

  void testGetExifDataWithEmbeddedScript( )

Make sure that we sanitize EXIF data as if it were any other input data



[ Top ]
testGetExifKeys  [line 197]

  void testGetExifKeys( )

Test getting all the EXIF keys



[ Top ]
testGetIptcDataWithEmbeddedScript  [line 419]

  void testGetIptcDataWithEmbeddedScript( )

Make sure that we sanitize IPTC data as if it were any other input data



[ Top ]
testGetRawIptcDataAdobe  [line 210]

  void testGetRawIptcDataAdobe( )

Test getting IPTC data from an Adobe test file, actually having real IPTC data (as opposed to only XMP data, which is not distinguishable in current Adobe products).



[ Top ]
testGetRawIptcDataExifer  [line 303]

  void testGetRawIptcDataExifer( )

Test getting IPTC data from an Exifer for Windows test file, see (http://www.exifer.friedemann.info/) which does not know about XMP data. The author reports problems with some PHP software, so let's make sure, we are doing things right.



[ Top ]
testGetRawIptcDataIrfanView  [line 337]

  void testGetRawIptcDataIrfanView( )

Test getting IPTC data from an IrfanView test file, see (http://www.irfanview.com/) which does not know about XMP data.



[ Top ]
testGetRawIptcDataISO_8859_1  [line 401]

  void testGetRawIptcDataISO_8859_1( )

Test getting IPTC data from a test file with ISO-8859-1 german umlauts inside. These must be converted to UTF-8.



[ Top ]
testPostProcessKeys  [line 438]

  void testPostProcessKeys( )

Check post processing code.



[ Top ]
testPostProcessValueDoesSanitize  [line 484]

  void testPostProcessValueDoesSanitize( )



[ Top ]

Documentation generated on Fri, 08 Oct 2010 04:51:15 -0700 by phpDocumentor 1.3.0RC6