Swapnil Musale
09/07/2023, 7:54 AMclass RepositoryKonsistTest {
@Test
fun `classes ends with 'Repository' suffix should reside in 'domain-repository' package`() {
Konsist
.scopeFromModule("domain")
.classes()
.withNameEndingWith("Repository")
.assert {
it.resideInPackage("..domain.repository..")
}
}
@Test
fun `classes ends with 'RepositoryImpl' suffix should reside in 'data-repository' package`() {
Konsist
.scopeFromModule("data")
.classes()
.withNameEndingWith("RepositoryImpl")
.assert {
it.resideInPackage("..data.repository..")
}
}
}
Error : Declaration list is empty. Please make sure that list of declarations contain items before calling the 'assert' method.
com.lemonappdev.konsist.core.exception.KoPreconditionFailedException at RepositoryKonsistTest.kt:16
What I'm missing here any idea ?Swapnil Musale
09/07/2023, 7:55 AMNatalia Peterwas
09/07/2023, 8:26 AM.interfaces()
instead of .classes()
Swapnil Musale
09/07/2023, 8:27 AM