@Test
public void checkFrameHeaderFromPeek_validData_doesNotUpdatePositions() throws Exception {

  String file = "flac/bear_one_metadata_block.flac";
  FlacStreamMetadataHolder streamMetadataHolder =
      new FlacStreamMetadataHolder(/* flacStreamMetadata= */ null);
  ExtractorInput input = buildExtractorInputReadingFromFirstFrame(file, streamMetadataHolder);
  int frameStartMarker = FlacMetadataReader.getFrameStartMarker(input);
  long peekPosition = input.getPosition();
  // Set read position to 0.
  input = buildExtractorInput(file);
  input.advancePeekPosition((int) peekPosition);
  FlacFrameReader.checkFrameHeaderFromPeek(
      input, streamMetadataHolder.flacStreamMetadata, frameStartMarker, new SampleNumberHolder());
  assertThat(input.getPosition()).isEqualTo(0);
  assertThat(input.getPeekPosition()).isEqualTo(peekPosition);
}