EZP-21342: Fixed an edge case in removeAliasFile()
EZP-21324: Added a test case (fails)

Tests the case where the published version of an image
has more aliases than the archived versions: during copy(),
references to those aliases are created by eZImageType::postStore(),
but are copied to new references instead of being removed,
since the attribute is not the image owner.

These ezimagefile entries are orphan ones, and aren't removed
when the object is deleted.
EZP-21324: Fixed test case tested in the previous commit