Skip to content

Commit

Permalink
Update AndroidX versions (#4756)
Browse files Browse the repository at this point in the history
Task/Issue URL:
https://app.asana.com/0/1200204095367872/1207761853531200/f

### Description
Brings AndroidX dependencies up-to-date:
```
- androidx.browser=1.7.0 → 1.8.0
- androidx.core=1.12.0 → 1.13.1
- androidx.fragment=1.5.2 → 1.8.1
- androidx.lifecycle=2.5.1 → 2.8.3
- androidx.test.orchestrator=1.4.2 → 1.5.0
- androidx.test.espresso=3.5.0 → 3.6.1
- androidx.test.ext.junit=1.1.4 → 1.2.1
- androidx.test.rules=1.5.0 → 1.6.1
- androidx.test.runner=1.5.1 → 1.6.1
- androidx.webkit=1.9.0 → 1.11.0
- androidx.work=2.7.1 → 2.9.0
- androidx.viewpager2=1.0.0 → 1.1.0
```

**Test runs**

- End-to-end:
https://github.com/duckduckgo/Android/actions/runs/9909564980 ✅
-
Nightly: https://github.com/duckduckgo/Android/actions/runs/9909423866 ✅
- Custom
tabs: https://github.com/duckduckgo/Android/actions/runs/9909541427 ✅
- Design system:
https://github.com/duckduckgo/Android/actions/runs/9909810696 ✅
- Autofill:
https://github.com/duckduckgo/Android/actions/runs/9909863851 ✅

### Steps to test this PR
- [x] Smoke test
  • Loading branch information
joshliebe authored Jul 15, 2024
1 parent b063675 commit dd66296
Show file tree
Hide file tree
Showing 15 changed files with 33 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ class ManageRecentAppsProtectionActivity :
}

override fun onBackPressed() {
super.onBackPressed()
onSupportNavigateUp()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,7 @@ class TrackingProtectionExclusionListActivity :
}

override fun onBackPressed() {
super.onBackPressed()
onSupportNavigateUp()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ class ReportBreakageAppListActivity : DuckDuckGoActivity(), ReportBreakageAppLis
}

override fun onBackPressed() {
super.onBackPressed()
onSupportNavigateUp()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ class VpnOnboardingActivity : DuckDuckGoActivity() {
}

override fun onBackPressed() {
super.onBackPressed()
// go back to previous screen or get out if first page
onSupportNavigateUp()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ class DeviceShieldAppTrackersInfo : DuckDuckGoActivity() {
}

override fun onBackPressed() {
super.onBackPressed()
finish()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,7 @@ class AppTPCompanyTrackersActivity : DuckDuckGoActivity() {
}

override fun onBackPressed() {
super.onBackPressed()
finish()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ class DeviceShieldMostRecentActivity : DuckDuckGoActivity() {
}

override fun onBackPressed() {
super.onBackPressed()
finish()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,7 @@ class DeviceShieldTrackerActivity :
}

override fun onBackPressed() {
super.onBackPressed()
onSupportNavigateUp()
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

package com.duckduckgo.app.fire

import android.content.Context
import android.content.Intent
import android.net.Uri
import androidx.lifecycle.LifecycleOwner
Expand All @@ -24,6 +25,7 @@ import com.duckduckgo.app.browser.BrowserActivity
import com.duckduckgo.app.pixels.AppPixelName
import com.duckduckgo.app.statistics.pixels.Pixel
import com.duckduckgo.app.systemsearch.SystemSearchActivity
import org.junit.Before
import org.junit.Test
import org.mockito.kotlin.mock
import org.mockito.kotlin.verify
Expand All @@ -34,6 +36,12 @@ class DataClearerForegroundAppRestartPixelTest {
private val pixel = mock<Pixel>()
private val testee = DataClearerForegroundAppRestartPixel(context, pixel)

@Before
fun setUp() {
val preferences = context.getSharedPreferences(DataClearerForegroundAppRestartPixel.FILENAME, Context.MODE_PRIVATE)
preferences.edit().clear().apply()
}

@Test
fun whenAppRestartsAfterOpenSearchWidgetThenPixelWithIntentIsSent() {
val intent = SystemSearchActivity.fromWidget(context)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ class FeedbackActivity :
}

override fun onBackPressed() {
super.onBackPressed()
viewModel.onBackPressed()
}

Expand Down
4 changes: 0 additions & 4 deletions app/src/main/java/com/duckduckgo/app/fire/FireActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,6 @@ class FireActivity : AppCompatActivity() {
killProcess()
}

override fun onBackPressed() {
// do nothing - the activity will kill itself soon enough
}

companion object {
private const val KEY_RESTART_INTENTS = "KEY_RESTART_INTENTS"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ class OnboardingActivity : DuckDuckGoActivity() {
}

override fun onBackPressed() {
super.onBackPressed()
val currentPage = viewPager.currentItem
if (currentPage == 0) {
finish()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ class SurveyActivity : DuckDuckGoActivity() {
}

override fun onBackPressed() {
super.onBackPressed()
if (webView.canGoBack()) {
webView.goBack()
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ class AddWidgetInstructionsActivity : DuckDuckGoActivity() {
}

override fun onBackPressed() {
super.onBackPressed()
viewModel.onClosePressed()
}

Expand Down
26 changes: 13 additions & 13 deletions versions.properties
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ version.androidx.appcompat=1.7.0

version.androidx.arch.core=2.2.0

version.androidx.browser=1.7.0
version.androidx.browser=1.8.0

version.androidx.constraintlayout=2.1.4

Expand All @@ -25,31 +25,31 @@ version.androidx.localbroadcastmanager=1.1.0

version.androidx.recyclerview=1.3.2

version.androidx.core=1.12.0
version.androidx.core=1.13.1

version.androidx.fragment=1.5.2
version.androidx.fragment=1.8.1

version.androidx.legacy=1.0.0

version.androidx.lifecycle=2.5.1
version.androidx.lifecycle=2.8.3

version.androidx.room=2.6.1

version.androidx.swiperefreshlayout=1.1.0

version.androidx.test.orchestrator=1.4.2
version.androidx.test.orchestrator=1.5.0

version.androidx.test.espresso=3.5.0
version.androidx.test.espresso=3.6.1

version.androidx.test.ext.junit=1.1.4
version.androidx.test.ext.junit=1.2.1

version.androidx.test.rules=1.5.0
version.androidx.test.rules=1.6.1

version.androidx.test.runner=1.5.1
version.androidx.test.runner=1.6.1

version.androidx.webkit=1.9.0
version.androidx.webkit=1.11.0

version.androidx.work=2.7.1
version.androidx.work=2.9.0

version.androidx.security-crypto=1.1.0-alpha06

Expand Down Expand Up @@ -101,7 +101,7 @@ version.okhttp3=4.12.0

version.net.zetetic..android-database-sqlcipher=4.5.1

version.okio=3.2.0
version.okio=3.2.0

version.org.apache.commons..commons-math3=3.6.1

Expand All @@ -117,7 +117,7 @@ version.org.jsoup..jsoup=1.15.3

version.com.jakewharton.retrofit..retrofit2-kotlin-coroutines-adapter=0.9.2

version.androidx.viewpager2=1.0.0
version.androidx.viewpager2=1.1.0

version.robolectric=4.12.2

Expand Down

0 comments on commit dd66296

Please sign in to comment.