Commit 44843304 by tofunmi Committed by Marc Baechinger

Update InternetConnection check to skip check when uri scheme is null

When we created androidTests, in the past, they always had a URI pointing to a resource, therefore we always had a URI scheme. With texture input, this will not longer be the case (EditedMediaItems's may have URI.EMPTY, which have a null scheme) so we need to check for this so tests don't falsely fail.

PiperOrigin-RevId: 528848411
parent 497c51b9
......@@ -274,8 +274,8 @@ public class TransformerAndroidTestRunner {
for (EditedMediaItemSequence sequence : composition.sequences) {
for (EditedMediaItem editedMediaItem : sequence.editedMediaItems) {
Uri mediaItemUri = checkNotNull(editedMediaItem.mediaItem.localConfiguration).uri;
String scheme = checkNotNull(mediaItemUri.getScheme());
if ((scheme.equals("http") || scheme.equals("https"))) {
String scheme = mediaItemUri.getScheme();
if (scheme != null && (scheme.equals("http") || scheme.equals("https"))) {
assumeTrue(
"Input network file requested on device with no network connection. Input file"
+ " name: "
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment