diff --git a/owncloudApp/src/androidTest/java/com/owncloud/android/settings/security/SettingsSecurityFragmentTest.kt b/owncloudApp/src/androidTest/java/com/owncloud/android/settings/security/SettingsSecurityFragmentTest.kt index 4ae651a68e8..23c4f62b504 100644 --- a/owncloudApp/src/androidTest/java/com/owncloud/android/settings/security/SettingsSecurityFragmentTest.kt +++ b/owncloudApp/src/androidTest/java/com/owncloud/android/settings/security/SettingsSecurityFragmentTest.kt @@ -156,14 +156,16 @@ class SettingsSecurityFragmentTest { checkCommonPreferences() assertNotNull(prefBiometric) - prefBiometric?.verifyPreference( - keyPref = BiometricActivity.PREFERENCE_SET_BIOMETRIC, - titlePref = context.getString(R.string.prefs_biometric), - summaryPref = context.getString(R.string.prefs_biometric_summary), - visible = true, - enabled = false - ) - assertFalse(prefBiometric!!.isChecked) + prefBiometric?.run { + verifyPreference( + keyPref = BiometricActivity.PREFERENCE_SET_BIOMETRIC, + titlePref = context.getString(R.string.prefs_biometric), + summaryPref = context.getString(R.string.prefs_biometric_summary), + visible = true, + enabled = false + ) + assertFalse(isChecked) + } } @Test