Disable flaky transformer emulator test on API 31.

videoEncoderFormatUnsupported_completesWithError() has recently
been flaky on API 31 emulators on presubmit because a different
exception than the expected exception is thrown.
This disables it on those emulators to reduce testing noise
until the underlying problem is investigated and resolved.

PiperOrigin-RevId: 456765512
This commit is contained in:
hschlueter 2022-06-23 15:44:02 +01:00 committed by Ian Baker
parent 1d2ad39a4d
commit 938d3c2e5b

View File

@ -24,6 +24,7 @@ import android.content.Context;
import android.net.Uri;
import androidx.media3.common.Format;
import androidx.media3.common.MediaItem;
import androidx.media3.common.util.Util;
import androidx.test.core.app.ApplicationProvider;
import androidx.test.ext.junit.runners.AndroidJUnit4;
import java.util.List;
@ -109,6 +110,11 @@ public class TransformerEndToEndTest {
@Test
public void videoEncoderFormatUnsupported_completesWithError() {
// TODO(b/236943611): Re-enable this test after investigating flakiness.
if (Util.SDK_INT == 31) {
return;
}
Transformer transformer =
new Transformer.Builder(context)
.setEncoderFactory(new VideoUnsupportedEncoderFactory(context))