Coverage Summary for Class: AppModuleKt (cloud.mindbox.mobile_sdk.di.modules)

Class Method, % Branch, % Line, % Instruction, %
AppModuleKt 100% (1/1) 100% (1/1) 100% (10/10)
AppModuleKt$AppModule$1 50% (1/2) 87.5% (7/8) 62.5% (20/32)
AppModuleKt$AppModule$1$isDebug$1 0% (0/1) 0% (0/1) 0% (0/9)
Total 50% (2/4) 80% (8/10) 58.8% (30/51)


 package cloud.mindbox.mobile_sdk.di.modules
 
 import android.content.pm.ApplicationInfo
 import cloud.mindbox.mobile_sdk.utils.LoggingExceptionHandler
 
 internal fun AppModule(
     applicationContextModule: AppContextModule,
     domainModule: DomainModule,
     monitoringModule: MonitoringModule,
     presentationModule: PresentationModule,
     dataModule: DataModule,
     apiModule: ApiModule,
 ): AppModule = object : AppModule,
     AppContextModule by applicationContextModule,
     DomainModule by domainModule,
     MonitoringModule by monitoringModule,
     PresentationModule by presentationModule,
     DataModule by dataModule,
     ApiModule by apiModule {
 
     override fun isDebug(): Boolean = LoggingExceptionHandler.runCatching(defaultValue = false) {
         (applicationContextModule.appContext.applicationInfo.flags and ApplicationInfo.FLAG_DEBUGGABLE) != 0
     }
 }