@Test
public void testContinueLoadingOnlyAllowFurthestBehindLoaderToLoadIfNotBehindPlaybackPosition() {

  FakeSequenceableLoader loader1 =
      new FakeSequenceableLoader(/* bufferedPositionUs */ 1000, /* nextLoadPositionUs */ 2000);
  FakeSequenceableLoader loader2 =
      new FakeSequenceableLoader(/* bufferedPositionUs */ 1001, /* nextLoadPositionUs */ 2001);
  CompositeSequenceableLoader compositeSequenceableLoader = new CompositeSequenceableLoader(
      new SequenceableLoader[] {loader1, loader2});
  compositeSequenceableLoader.continueLoading(100);
  assertThat(loader1.numInvocations).isEqualTo(1);
  assertThat(loader2.numInvocations).isEqualTo(0);
}