Skip to content

Commit

Permalink
Fix ExoPlayerTest to use C.TIME_UNSET instead of C.POSITION_UNSET
Browse files Browse the repository at this point in the history
This inconsistency was exposed by an upcoming change to deprecate
`POSITION_UNSET` in favour of `INDEX_UNSET` because position is an
ambiguous term between 'byte offset' and 'media position', as shown
here.

PiperOrigin-RevId: 492470241
  • Loading branch information
icbaker committed Dec 12, 2022
1 parent 5f6fde4 commit 2f8cf94
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2514,7 +2514,7 @@ public void sendMessagesSeekAfterDeliveryTimeDuringPreparation() throws Exceptio
.build()
.start()
.blockUntilEnded(TIMEOUT_MS);
assertThat(target.positionMs).isEqualTo(C.POSITION_UNSET);
assertThat(target.positionMs).isEqualTo(C.TIME_UNSET);
}

@Test
Expand All @@ -2536,7 +2536,7 @@ public void sendMessagesSeekAfterDeliveryTimeAfterPreparation() throws Exception
.build()
.start()
.blockUntilEnded(TIMEOUT_MS);
assertThat(target.positionMs).isEqualTo(C.POSITION_UNSET);
assertThat(target.positionMs).isEqualTo(C.TIME_UNSET);
}

@Test
Expand Down Expand Up @@ -12282,7 +12282,7 @@ private static final class PositionGrabbingMessageTarget extends PlayerTarget {

public PositionGrabbingMessageTarget() {
mediaItemIndex = C.INDEX_UNSET;
positionMs = C.POSITION_UNSET;
positionMs = C.TIME_UNSET;
}

@Override
Expand Down

0 comments on commit 2f8cf94

Please sign in to comment.