File tree Expand file tree Collapse file tree 4 files changed +5
-4
lines changed
main/kotlin/org/koin/example/qualifier
test/kotlin/org.koin.example
projects/koin-ksp-compiler/src/jvmMain/kotlin/org/koin/compiler/generator Expand file tree Collapse file tree 4 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -37,5 +37,6 @@ public class QualifierModule {
3737 public fun anotherList (): StuffList = StuffList (listOf (Stuff (" 1" ),Stuff (" 2" )))
3838
3939 @Single
40+ @Named(" another-counter" )
4041 public fun anotherCounter (@Named(" another-counter" ) stuffs : StuffList ): StuffCounter = StuffCounter (stuffs.list," another-counter" )
4142}
Original file line number Diff line number Diff line change @@ -113,7 +113,7 @@ class TestModule {
113113 assertEquals(ints,koin.get<MyInjectFactory >{ parametersOf(ints) }.ints)
114114
115115 assertEquals(2 ,koin.get<StuffList >(named(" another-counter" )).list.size)
116- assertEquals(" another-counter" ,koin.get<StuffCounter >().name)
116+ assertEquals(" another-counter" ,koin.get<StuffCounter >(named( " another-counter " ) ).name)
117117
118118 assertNotNull(koin.getOrNull<MyType .MyChildType >())
119119
Original file line number Diff line number Diff line change @@ -35,12 +35,12 @@ class ApplicationClassWriter(
3535 }
3636
3737 private fun writeConfigurationMap () {
38- val configurationListString = application.configurations?.flatMap { configuration -> configuration.modules }?.distinct()?.let { generateIncludes(it.sortedBy { it.packageName+ " " + it.className }) }
38+ val configurationListString = application.configurations?.flatMap { configuration -> configuration.modules }?.distinct()?.let { generateIncludes(it.sortedBy { it.packageName+ " . " + it.className }) }
3939 writeln(" $visibility val $extensionBase .configurationModules : List<Module> get() = listOf($configurationListString )" )
4040 }
4141
4242 private fun writeKoinConfigurationField () {
43- val moduleIncludes = application.moduleIncludes?.let { " + listOf(${generateIncludes(it.sortedBy { it.packageName+ " " + it.className })} )" } ? : " "
43+ val moduleIncludes = application.moduleIncludes?.let { " + listOf(${generateIncludes(it.sortedBy { it.packageName+ " . " + it.className })} )" } ? : " "
4444 val configString = """
4545 $visibility fun $extensionBase .koinConfiguration(config : KoinAppDeclaration?=null) : KoinAppDeclaration = {
4646 includes(config)
Original file line number Diff line number Diff line change @@ -161,7 +161,7 @@ abstract class ModuleWriter(
161161
162162 open fun writeModuleIncludes () {
163163 if (module.includes?.isNotEmpty() == true ){
164- writeln(" ${TAB } includes(${generateIncludes(module.includes.sortedBy { it.packageName+ " " + it.className })} )" )
164+ writeln(" ${TAB } includes(${generateIncludes(module.includes.sortedBy { it.packageName+ " . " + it.className })} )" )
165165 }
166166 }
167167
You can’t perform that action at this time.
0 commit comments