paparazzi
paparazzi copied to clipboard
Add Gif verification support
Adds support by encoding a temp mov during verification and then comparing the golden mov to the temp mov by decoding/comparing each frame. This yielded better accuracy than comparing an unencoded frame to the golden decoded frame. Unfortunately it isn't perfect, encoding noise is slightly different across different arch's. The plugin test verifies with maxPercentDiff of 0.01 which was too strict for windows, had to bump the diff to 0.05 to get it to pass. This is still under the 0.1 that Paparazzi uses by default.
Example failure:
java.lang.AssertionError: 15 video frames differed by more than 0.1%
Mismatched video duration expected: 1.0333333333333334 actual: 0.5333333333333333
Mismatched frame count expected: 31 actual: 16
find delta video at /Users/cdrury/Development/paparazzi/sample/out/failures
at org.junit.Assert.fail(Assert.java:89)
at app.cash.paparazzi.internal.VideoUtils.assertVideoSimilar(VideoUtils.kt:116)
at app.cash.paparazzi.SnapshotVerifier$newFrameHandler$1.close(SnapshotVerifier.kt:77)
at kotlin.io.CloseableKt.closeFinally(Closeable.kt:57)
at app.cash.paparazzi.Paparazzi.takeSnapshots(Paparazzi.kt:280)
at app.cash.paparazzi.Paparazzi.gif(Paparazzi.kt:228)
at app.cash.paparazzi.sample.KeypadViewTest.testViews(KeypadViewTest.kt:69)
Rotation direction changed https://user-images.githubusercontent.com/672316/176577507-1097cbd8-41e0-4853-9870-d00639cc98f1.mov
Length of video changed https://user-images.githubusercontent.com/672316/176581246-7d7ea6c6-2993-4241-a029-d1b0865788cb.mov
I’m unable to login Cashapp on my device please help me out
Have you run spotless on this branch yet?
Have you run spotless on this branch yet?
Hmm I think @gamepro65 needs to rebase, branch was created prior to the Spotless integration.