diff --git a/app/src/androidTest/java/org/kiwix/kiwixmobile/ObjectBoxToRoomMigratorTest.kt b/app/src/androidTest/java/org/kiwix/kiwixmobile/ObjectBoxToRoomMigratorTest.kt index b667ed8ef..0ea1de241 100644 --- a/app/src/androidTest/java/org/kiwix/kiwixmobile/ObjectBoxToRoomMigratorTest.kt +++ b/app/src/androidTest/java/org/kiwix/kiwixmobile/ObjectBoxToRoomMigratorTest.kt @@ -119,8 +119,11 @@ class ObjectBoxToRoomMigratorTest { val expectedSearchTerm = "test search" val expectedZimId = "8812214350305159407L" val expectedUrl = "http://kiwix.app/mainPage" - val recentSearchEntity = - RecentSearchEntity(searchTerm = expectedSearchTerm, zimId = expectedZimId, url = expectedUrl) + val recentSearchEntity = RecentSearchEntity( + searchTerm = expectedSearchTerm, + zimId = expectedZimId, + url = expectedUrl + ) // insert into object box box.put(recentSearchEntity) // migrate data into room database diff --git a/app/src/androidTest/java/org/kiwix/kiwixmobile/nav/destination/library/OnlineLibraryFragmentTest.kt b/app/src/androidTest/java/org/kiwix/kiwixmobile/nav/destination/library/OnlineLibraryFragmentTest.kt index 5473c6db8..1f4586c03 100644 --- a/app/src/androidTest/java/org/kiwix/kiwixmobile/nav/destination/library/OnlineLibraryFragmentTest.kt +++ b/app/src/androidTest/java/org/kiwix/kiwixmobile/nav/destination/library/OnlineLibraryFragmentTest.kt @@ -22,6 +22,7 @@ import androidx.core.content.edit import androidx.lifecycle.Lifecycle import androidx.preference.PreferenceManager import androidx.test.core.app.ActivityScenario +import androidx.test.espresso.Espresso import androidx.test.espresso.accessibility.AccessibilityChecks import androidx.test.platform.app.InstrumentationRegistry import androidx.test.uiautomator.UiDevice @@ -100,7 +101,7 @@ class OnlineLibraryFragmentTest : BaseActivityTest() { waitForDataToLoad() clickOnSearchIcon() searchWikipediaZIMFiles() - pressBack() + Espresso.closeSoftKeyboard() clickLibraryOnBottomNav() clickDownloadOnBottomNav() assertPreviousSearchRemainsActive() @@ -119,7 +120,7 @@ class OnlineLibraryFragmentTest : BaseActivityTest() { clickOnSearchIcon() searchWikipediaZIMFiles() clickOnClearSearchIcon() - pressBack() + Espresso.closeSoftKeyboard() clickLibraryOnBottomNav() clickDownloadOnBottomNav() assertSearchViewIsNotActive(kiwixMainActivity) diff --git a/buildSrc/src/main/kotlin/Config.kt b/buildSrc/src/main/kotlin/Config.kt index b7bf08ad7..f661f3e92 100644 --- a/buildSrc/src/main/kotlin/Config.kt +++ b/buildSrc/src/main/kotlin/Config.kt @@ -24,7 +24,7 @@ object Config { // levels: https://apilevels.com/ const val compileSdk = 36 // SDK version used by Gradle to compile our app. const val minSdk = 25 // Minimum SDK (Minimum Support Device) is 25 (Android 7.1 Nougat). - const val targetSdk = 36 // Target SDK (Maximum Support Device) is Baklava (Android 16). + const val targetSdk = 36 // Target SDK (Maximum Support Device) is 36 (Android 16). val javaVersion = JavaVersion.VERSION_17 diff --git a/contrib/instrumentation-customapps.sh b/contrib/instrumentation-customapps.sh index 51e82804b..762a0caf8 100644 --- a/contrib/instrumentation-customapps.sh +++ b/contrib/instrumentation-customapps.sh @@ -21,6 +21,10 @@ # Enable Wi-Fi on the emulator adb shell svc wifi enable adb logcat -c +# Check if the stylus_handwriting_enabled setting exists before disabling +if adb shell settings list secure | grep -q "stylus_handwriting_enabled"; then + adb shell settings put secure stylus_handwriting_enabled 0 +fi # shellcheck disable=SC2035 adb logcat *:E -v color & @@ -61,6 +65,10 @@ while [ $retry -le 3 ]; do # Enable Wi-Fi on the emulator adb shell svc wifi enable adb logcat -c + # Check if the stylus_handwriting_enabled setting exists before disabling + if adb shell settings list secure | grep -q "stylus_handwriting_enabled"; then + adb shell settings put secure stylus_handwriting_enabled 0 + fi # shellcheck disable=SC2035 adb logcat *:E -v color & diff --git a/contrib/instrumentation-file-opening-on-tablet.sh b/contrib/instrumentation-file-opening-on-tablet.sh index 08535b0fc..db8b7e919 100644 --- a/contrib/instrumentation-file-opening-on-tablet.sh +++ b/contrib/instrumentation-file-opening-on-tablet.sh @@ -3,6 +3,10 @@ # Enable Wi-Fi on the emulator adb shell svc wifi enable adb logcat -c +# Check if the stylus_handwriting_enabled setting exists before disabling +if adb shell settings list secure | grep -q "stylus_handwriting_enabled"; then + adb shell settings put secure stylus_handwriting_enabled 0 +fi # shellcheck disable=SC2035 adb logcat *:E -v color & @@ -42,6 +46,10 @@ while [ $retry -le 3 ]; do # Enable Wi-Fi on the emulator adb shell svc wifi enable adb logcat -c + # Check if the stylus_handwriting_enabled setting exists before disabling + if adb shell settings list secure | grep -q "stylus_handwriting_enabled"; then + adb shell settings put secure stylus_handwriting_enabled 0 + fi # shellcheck disable=SC2035 adb logcat *:E -v color & diff --git a/contrib/instrumentation-release.sh b/contrib/instrumentation-release.sh index ec309b7ff..e44bce4af 100644 --- a/contrib/instrumentation-release.sh +++ b/contrib/instrumentation-release.sh @@ -3,6 +3,10 @@ # Enable Wi-Fi on the emulator adb shell svc wifi enable adb logcat -c +# Check if the stylus_handwriting_enabled setting exists before disabling +if adb shell settings list secure | grep -q "stylus_handwriting_enabled"; then + adb shell settings put secure stylus_handwriting_enabled 0 +fi # shellcheck disable=SC2035 adb logcat *:E -v color & @@ -42,6 +46,10 @@ while [ $retry -le 3 ]; do # Enable Wi-Fi on the emulator adb shell svc wifi enable adb logcat -c + # Check if the stylus_handwriting_enabled setting exists before disabling + if adb shell settings list secure | grep -q "stylus_handwriting_enabled"; then + adb shell settings put secure stylus_handwriting_enabled 0 + fi # shellcheck disable=SC2035 adb logcat *:E -v color & diff --git a/contrib/instrumentation.sh b/contrib/instrumentation.sh index 55628ce13..955b7fe63 100644 --- a/contrib/instrumentation.sh +++ b/contrib/instrumentation.sh @@ -3,6 +3,10 @@ # Enable Wi-Fi on the emulator adb shell svc wifi enable adb logcat -c +# Check if the stylus_handwriting_enabled setting exists before disabling +if adb shell settings list secure | grep -q "stylus_handwriting_enabled"; then + adb shell settings put secure stylus_handwriting_enabled 0 +fi # shellcheck disable=SC2035 adb logcat *:E -v color & @@ -43,6 +47,10 @@ while [ $retry -le 3 ]; do # Enable Wi-Fi on the emulator adb shell svc wifi enable adb logcat -c + # Check if the stylus_handwriting_enabled setting exists before disabling + if adb shell settings list secure | grep -q "stylus_handwriting_enabled"; then + adb shell settings put secure stylus_handwriting_enabled 0 + fi # shellcheck disable=SC2035 adb logcat *:E -v color &