ConstantBitrateSeekMap implements SeekMap { @Override public long getDurationUs() { return durationUs; } ConstantBitrateSeekMap(
      long inputLength, long firstFrameBytePosition, int bitrate, int frameSize); @Override boolean isSeekable(); @Override SeekPoints getSeekPoints(long timeUs); @Override long getDurationUs(); long getTimeUsAtPosition(long position);  }
@Test public void testGetDurationUs_forKnownInputLength_returnCorrectDuration() { constantBitrateSeekMap = new ConstantBitrateSeekMap( 2_300, 100, 8_000, 100); assertThat(constantBitrateSeekMap.getDurationUs()).isEqualTo(2_200_000); }
@Test public void testGetDurationUs_forUnnnownInputLength_returnUnknownDuration() { constantBitrateSeekMap = new ConstantBitrateSeekMap( C.LENGTH_UNSET, 100, 8_000, 100); assertThat(constantBitrateSeekMap.getDurationUs()).isEqualTo(C.TIME_UNSET); }