Skip to content

Commit

Permalink
revert compileSdk to 33, downgrade deps, fix broken tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ashutoshgngwr committed Oct 1, 2023
1 parent 009fe33 commit 9f048a5
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 10 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ dependencies {
ksp "androidx.room:room-compiler:$roomVersion"

implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'androidx.browser:browser:1.6.0'
implementation 'androidx.browser:browser:1.5.0'

Check warning on line 107 in app/build.gradle

View workflow job for this annotation

GitHub Actions / Lint

Obsolete Gradle Dependency: A newer version of androidx.browser:browser than 1.5.0 is available: 1.6.0
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation "androidx.core:core-ktx:$deps.androidXCoreVersion"

Check warning on line 109 in app/build.gradle

View workflow job for this annotation

GitHub Actions / Lint

Obsolete Gradle Dependency: A newer version of androidx.core:core-ktx than 1.10.1 is available: 1.12.0
implementation "androidx.fragment:fragment-ktx:$fragmentVersion"
Expand Down Expand Up @@ -138,7 +138,7 @@ dependencies {
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:$deps.coroutinesVersion"
implementation project(":api-client")

fullImplementation 'androidx.mediarouter:mediarouter:1.6.0'
fullImplementation 'androidx.mediarouter:mediarouter:1.4.0'

Check warning on line 141 in app/build.gradle

View workflow job for this annotation

GitHub Actions / Lint

Obsolete Gradle Dependency: A newer version of androidx.mediarouter:mediarouter than 1.4.0 is available: 1.6.0
fullImplementation 'com.android.billingclient:billing-ktx:6.0.1'
fullImplementation 'com.google.android.gms:play-services-base:18.2.0'
fullImplementation 'com.google.android.gms:play-services-cast-framework:21.3.0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ class SoundPlaybackMediaSessionTest {
mediaSessionShadow.sendSetDeviceMuteCommand(false)
assertEquals(15, fakeVolumeProvider.getVolume())
assertEquals(false, fakeVolumeProvider.isMute())
// also check if changes propogate back to the media session.
// also check if changes propagate back to the media session.
assertEquals(15, mediaSessionShadow.deviceVolume)
assertEquals(false, mediaSessionShadow.isDeviceMute)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ import androidx.media3.common.DeviceInfo
import androidx.media3.common.MediaMetadata
import androidx.media3.common.Player
import androidx.media3.common.util.BitmapLoader
import androidx.media3.session.CommandButton
import androidx.media3.session.MediaSession
import com.google.common.collect.ImmutableList
import org.robolectric.annotation.Implementation
import org.robolectric.annotation.Implements
import org.robolectric.annotation.RealObject
Expand Down Expand Up @@ -44,6 +46,7 @@ class ShadowMediaSession : Player.Listener {
id: String,
player: Player,
sessionActivity: PendingIntent?,
customLayout: ImmutableList<CommandButton>,
callback: MediaSession.Callback,
tokenExtras: Bundle,
bitmapLoader: BitmapLoader,
Expand All @@ -55,6 +58,7 @@ class ShadowMediaSession : Player.Listener {
ReflectionHelpers.ClassParameter.from(String::class.java, id),
ReflectionHelpers.ClassParameter.from(Player::class.java, player),
ReflectionHelpers.ClassParameter.from(PendingIntent::class.java, sessionActivity),
ReflectionHelpers.ClassParameter.from(ImmutableList::class.java, customLayout),
ReflectionHelpers.ClassParameter.from(MediaSession.Callback::class.java, callback),
ReflectionHelpers.ClassParameter.from(Bundle::class.java, tokenExtras),
ReflectionHelpers.ClassParameter.from(BitmapLoader::class.java, bitmapLoader),
Expand Down
10 changes: 5 additions & 5 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ plugins {
project.ext {
deps = [
aboutLibrariesVersion: "${aboutLibrariesVersion}",
androidXCoreVersion : '1.12.0',
androidXCoreVersion : '1.10.1',
coroutinesVersion : '1.7.3',
hiltVersion : "${hiltVersion}",
kotlinVersion : "${kotlinVersion}",
Expand All @@ -39,11 +39,11 @@ subprojects {
}

android {
compileSdk 34
compileSdk 33

defaultConfig {
minSdk 21
targetSdk 34
targetSdk 33
}

compileOptions {
Expand Down Expand Up @@ -109,7 +109,7 @@ subprojects {
sourceDirectories.setFrom(files(srcDirs))
classDirectories.setFrom(files(
fileTree(
dir: "${project.buildDir}/tmp/kotlin-classes/${variant.name}",
dir: "${project.layout.buildDir}/tmp/kotlin-classes/${variant.name}",
excludes: ['**/R.class',
'**/R$*.class',
'**/*$ViewInjector*.*',
Expand Down Expand Up @@ -137,5 +137,5 @@ subprojects {
}

tasks.register('clean', Delete) {
delete rootProject.buildDir
delete rootProject.layout.buildDir
}
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@ kotlin.code.style=official
agpVersion=8.1.2
hiltVersion=2.48
kotlinVersion=1.9.10
navVersion=2.7.3
aboutLibrariesVersion=10.9.1
navVersion=2.6.0
aboutLibrariesVersion=10.8.3

0 comments on commit 9f048a5

Please sign in to comment.