Skip to content

Commit

Permalink
Fix PlayerTimeSlider not being draggable (#447)
Browse files Browse the repository at this point in the history
  • Loading branch information
MGaetan89 authored Feb 20, 2024
1 parent 4d104df commit 49eed2c
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 3 deletions.
6 changes: 6 additions & 0 deletions pillarbox-analytics/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import org.gradle.api.tasks.testing.logging.TestExceptionFormat

/*
* Copyright (c) SRG SSR. All rights reserved.
* License information is available from the LICENSE file.
Expand Down Expand Up @@ -58,6 +60,10 @@ android {
}
}

tasks.withType<Test>().configureEach {
testLogging.exceptionFormat = TestExceptionFormat.FULL
}

dependencies {
implementation(libs.comscore)
implementation(libs.tagcommander.core)
Expand Down
6 changes: 6 additions & 0 deletions pillarbox-core-business/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import org.gradle.api.tasks.testing.logging.TestExceptionFormat

/*
* Copyright (c) SRG SSR. All rights reserved.
* License information is available from the LICENSE file.
Expand Down Expand Up @@ -53,6 +55,10 @@ android {
}
}

tasks.withType<Test>().configureEach {
testLogging.exceptionFormat = TestExceptionFormat.FULL
}

dependencies {
api(project(":pillarbox-analytics"))
api(project(":pillarbox-player"))
Expand Down
6 changes: 6 additions & 0 deletions pillarbox-player/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import org.gradle.api.tasks.testing.logging.TestExceptionFormat

/*
* Copyright (c) SRG SSR. All rights reserved.
* License information is available from the LICENSE file.
Expand Down Expand Up @@ -65,6 +67,10 @@ android {
}
}

tasks.withType<Test>().configureEach {
testLogging.exceptionFormat = TestExceptionFormat.FULL
}

dependencies {
implementation(libs.androidx.annotation)
implementation(libs.androidx.core)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -566,15 +566,18 @@ class MediaItemTrackerTest {
)
prepare()
play()
seekTo(FakeMediaItemSource.NEAR_END_POSITION_MS)
}

TestPlayerRunHelper.runUntilPlaybackState(player, Player.STATE_READY)
TestPlayerRunHelper.runUntilTimelineChanged(player)

fakeClock.advanceTime(FakeMediaItemSource.NEAR_END_POSITION_MS)

verifyOrder {
fakeMediaItemTracker.start(any(), FakeMediaItemTracker.Data(firstMediaId))
fakeMediaItemTracker.stop(any(), MediaItemTracker.StopReason.EoF, any())
fakeMediaItemTracker.start(any(), FakeMediaItemTracker.Data(secondMediaId))
fakeMediaItemTracker.start(player, FakeMediaItemTracker.Data(firstMediaId))
fakeMediaItemTracker.stop(player, MediaItemTracker.StopReason.EoF, any())
fakeMediaItemTracker.start(player, FakeMediaItemTracker.Data(secondMediaId))
}
confirmVerified(fakeMediaItemTracker)
}
Expand Down
6 changes: 6 additions & 0 deletions pillarbox-ui/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import org.gradle.api.tasks.testing.logging.TestExceptionFormat

/*
* Copyright (c) SRG SSR. All rights reserved.
* License information is available from the LICENSE file.
Expand Down Expand Up @@ -50,6 +52,10 @@ android {
}
}

tasks.withType<Test>().configureEach {
testLogging.exceptionFormat = TestExceptionFormat.FULL
}

dependencies {
api(project(":pillarbox-player"))

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@
*/
package ch.srgssr.pillarbox.ui

import androidx.compose.runtime.Stable
import androidx.media3.common.Player
import kotlinx.coroutines.flow.StateFlow
import kotlin.time.Duration

/**
* Interface used to subscribe to and update the [Player] progression.
*/
@Stable
interface ProgressTrackerState {
/**
* Emits the current progress, which can be either the value being manually set, or the actual [Player] progress.
Expand Down

0 comments on commit 49eed2c

Please sign in to comment.