Tim Malseed
10/24/2024, 11:35 AMPoisonedYouth
10/24/2024, 12:37 PMigor.wojda
10/24/2024, 3:08 PMKonsist
.scopeFromProduction()
.classes()
.withParentClassOf(ViewModel::class)
.assertTrue {
it.containingFile.hasImport { import -> import.name == "com.NetworkException" }
//or
it.containingFile.hasImport { import -> import.representsTypeOf<NetworkException>() }
}
Assuming no unused imports are present in the file this should work (AS/IDEA autoImport
feature should help)PoisonedYouth
10/24/2024, 3:41 PM