AttachmentRetrieverIntegrationTest fails on emulator
Several tests in AttachmentRetrieverIntegrationTest fail on the API 21 emulator. It looks like some of them failed in the original commit of the test (it was called AttachmentControllerTest at the time) and others have been broken by subsequent changes.
The failures from the original commit all seem to involve the same issue: the file extension being jpeg
rather than jpg
. I guess the platform's behaviour probably changed some time between API 21 and now, and it doesn't seem likely to cause problems beyond the test failure.
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.conversation.AttachmentControllerTest.testSmallJpegImageHealsWrongMimeType(AttachmentControllerTest.java:125)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.conversation.AttachmentControllerTest.testHighError(AttachmentControllerTest.java:317)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.conversation.AttachmentControllerTest.testWideError(AttachmentControllerTest.java:332)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.conversation.AttachmentControllerTest.testNoSizeJpeg(AttachmentControllerTest.java:71)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.conversation.AttachmentControllerTest.testSmallJpegImage(AttachmentControllerTest.java:109)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.conversation.AttachmentControllerTest.testBigJpegImage(AttachmentControllerTest.java:141)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.conversation.AttachmentControllerTest.testLottaPixels(AttachmentControllerTest.java:203)
The failures on current master involve content types as well as file extensions.
org.junit.ComparisonFailure: expected:<image/[gif]> but was:<image/[jpeg]>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testGimpCrash(AttachmentRetrieverIntegrationTest.java:156)
...
org.junit.ComparisonFailure: expected:<image/[gif]> but was:<image/[jpeg]>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testUberGif(AttachmentRetrieverIntegrationTest.java:111)
...
org.junit.ComparisonFailure: expected:<image/[pn]g> but was:<image/[jpe]g>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testImageIoCrash(AttachmentRetrieverIntegrationTest.java:141)
...
org.junit.ComparisonFailure: expected:<image/[gif]> but was:<image/[jpeg]>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testOptiPngAfl(AttachmentRetrieverIntegrationTest.java:171)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testHighError(AttachmentRetrieverIntegrationTest.java:241)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testWideError(AttachmentRetrieverIntegrationTest.java:256)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testSmallJpegImage(AttachmentRetrieverIntegrationTest.java:65)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testBigJpegImage(AttachmentRetrieverIntegrationTest.java:81)
...
org.junit.ComparisonFailure: expected:<jp[]g> but was:<jp[e]g>
at org.briarproject.briar.android.attachment.AttachmentRetrieverIntegrationTest.testLottaPixels(AttachmentRetrieverIntegrationTest.java:127)