ktlint: Format source directories other than main
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
This commit is contained in:
@@ -5,13 +5,11 @@ import android.content.Context
|
||||
import androidx.test.runner.AndroidJUnitRunner
|
||||
import dagger.hilt.android.testing.HiltTestApplication
|
||||
|
||||
class HiltInstrumentationTestRunner: AndroidJUnitRunner() {
|
||||
class HiltInstrumentationTestRunner : AndroidJUnitRunner() {
|
||||
|
||||
override fun newApplication(
|
||||
cl: ClassLoader?,
|
||||
className: String?,
|
||||
context: Context?
|
||||
): Application {
|
||||
return super.newApplication(cl, HiltTestApplication::class.java.name, context)
|
||||
}
|
||||
): Application = super.newApplication(cl, HiltTestApplication::class.java.name, context)
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@ import com.aurora.store.IsolatedTest
|
||||
import com.aurora.store.R
|
||||
import org.junit.Test
|
||||
|
||||
class InfoTest: IsolatedTest() {
|
||||
class InfoTest : IsolatedTest() {
|
||||
|
||||
@Test
|
||||
fun testInfoWithoutClickHandling() {
|
||||
|
||||
@@ -24,7 +24,7 @@ class PermissionListItemTest : IsolatedTest() {
|
||||
get() = Permission(
|
||||
PermissionType.STORAGE_MANAGER,
|
||||
stringResource(R.string.onboarding_permission_esm),
|
||||
stringResource(R.string.onboarding_permission_esa_desc),
|
||||
stringResource(R.string.onboarding_permission_esa_desc)
|
||||
)
|
||||
|
||||
@Test
|
||||
|
||||
@@ -13,7 +13,7 @@ import androidx.compose.ui.test.onNodeWithTag
|
||||
import com.aurora.store.IsolatedTest
|
||||
import org.junit.Test
|
||||
|
||||
class AnimatedAppIconTest: IsolatedTest() {
|
||||
class AnimatedAppIconTest : IsolatedTest() {
|
||||
|
||||
@Test
|
||||
fun testAnimatedAppIconNoProgress() {
|
||||
|
||||
@@ -144,19 +144,17 @@ class InstallerStatusReceiver : BaseInstallerStatusReceiver() {
|
||||
}
|
||||
}
|
||||
|
||||
private fun isHuaweiSilentInstallSupported(context: Context): Boolean {
|
||||
return try {
|
||||
val applicationInfo: ApplicationInfo = context.packageManager.getApplicationInfo(
|
||||
PACKAGE_NAME_APP_GALLERY,
|
||||
PackageManager.GET_META_DATA
|
||||
)
|
||||
private fun isHuaweiSilentInstallSupported(context: Context): Boolean = try {
|
||||
val applicationInfo: ApplicationInfo = context.packageManager.getApplicationInfo(
|
||||
PACKAGE_NAME_APP_GALLERY,
|
||||
PackageManager.GET_META_DATA
|
||||
)
|
||||
|
||||
val supportFunction = applicationInfo.metaData.getInt("appgallery_support_function")
|
||||
Log.i(TAG, "Huawei silent install support function: $supportFunction")
|
||||
val supportFunction = applicationInfo.metaData.getInt("appgallery_support_function")
|
||||
Log.i(TAG, "Huawei silent install support function: $supportFunction")
|
||||
|
||||
(supportFunction and (1 shl 5)) != 0
|
||||
} catch (e: Exception) {
|
||||
false
|
||||
}
|
||||
(supportFunction and (1 shl 5)) != 0
|
||||
} catch (e: Exception) {
|
||||
false
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,9 +7,7 @@ object FlavouredUtil : IFlavouredUtil {
|
||||
|
||||
override val defaultDispensers: Set<String> = emptySet()
|
||||
|
||||
override fun promptMicroGInstall(context: Context): Boolean {
|
||||
return isHuawei &&
|
||||
PackageUtil.hasSupportedAppGallery(context) &&
|
||||
!PackageUtil.isMicroGBundleInstalled(context)
|
||||
}
|
||||
override fun promptMicroGInstall(context: Context): Boolean = isHuawei &&
|
||||
PackageUtil.hasSupportedAppGallery(context) &&
|
||||
!PackageUtil.isMicroGBundleInstalled(context)
|
||||
}
|
||||
|
||||
@@ -6,7 +6,5 @@ object FlavouredUtil : IFlavouredUtil {
|
||||
|
||||
override val defaultDispensers = setOf(Constants.URL_DISPENSER)
|
||||
|
||||
override fun promptMicroGInstall(context: Context): Boolean {
|
||||
return false
|
||||
}
|
||||
override fun promptMicroGInstall(context: Context): Boolean = false
|
||||
}
|
||||
|
||||
@@ -7,7 +7,5 @@ object FlavouredUtil : IFlavouredUtil {
|
||||
|
||||
override val defaultDispensers = setOf(Constants.URL_DISPENSER)
|
||||
|
||||
override fun promptMicroGInstall(context: Context): Boolean {
|
||||
return false
|
||||
}
|
||||
override fun promptMicroGInstall(context: Context): Boolean = false
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user