### Question:
SaveToFileTransformer implements Transformer<Photo, Void> { @Override public Void transform(Photo input) { BufferedOutputStream outputStream = outputStream(); try { saveImage(input, outputStream); exifOrientationWriter.writeExifOrientation(file, input); } catch (IOException e) { throw new FileSaveException(e); } return null; } SaveToFileTransformer(File file,
                          ExifOrientationWriter exifOrientationWriter); static SaveToFileTransformer create(File file); @Override Void transform(Photo input);  }### Answer:
@Test public void savePhoto() throws Exception { Photo photo = new Photo( new byte[]{1, 2, 3}, 0 ); testee.transform(photo); assertTrue(FILE.exists()); assertEquals( photo.encodedImage.length, FILE.length() ); verify(exifOrientationWriter).writeExifOrientation(FILE, photo); }