'Test image which gets cleaned in forms.py.
Bug 921243 was caused of a valid image, without EXIF
data. That caused image._get_exif() in
phonebook.forms.ProfileForm.clean_photo to raise an
AttributeError and clean the image.
Cleaning the image (by re-saving) did not set the new file
size in the `photo` variable. If the cleaned image was larger
than the original image, this behavior resulted in corrupted
images being fed into PIL, which raises IOErrors.
This test reproduces that behavior and should fail if we don\'t
update the size of `photo` with the new cleaned image size.'

def test_converted_larger_image(self):

    user = UserFactory.create()
    file_path = os.path.join(os.path.dirname(__file__), 'broken_marshal.jpg')
    self._upload_photo(user, file_path)
