Skip to content

Commit

Permalink
Minor test updates
Browse files Browse the repository at this point in the history
  • Loading branch information
JoelWilcox committed Aug 31, 2023
1 parent 93026e9 commit 3b0ae66
Showing 1 changed file with 7 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -368,12 +368,9 @@ class ContributesMultibindingGeneratorTest(
package com.squareup.test
import com.squareup.anvil.annotations.ContributesMultibinding
import dagger.MapKey
import javax.inject.Singleton
@ContributesMultibinding(Any::class)
@BindingKey("abc")
@Singleton
@ContributesMultibinding(scope = Any::class)
@BindingKey(value = "abc")
interface ContributingInterface : ParentInterface
""".trimIndent()

Expand All @@ -388,7 +385,7 @@ class ContributesMultibindingGeneratorTest(
}
is AnvilCompilationMode.Ksp -> {
val processor = simpleSymbolProcessor { resolver ->
resolver.getSymbolsWithAnnotation(MergeComponent::class.qualifiedName!!)
resolver.getSymbolsWithAnnotation(MergeComponent::class.qualifiedName!!, inDepth = true)
.map { stubContentToGenerate }
.toList()
}
Expand All @@ -408,7 +405,7 @@ class ContributesMultibindingGeneratorTest(
interface ParentInterface
@MergeComponent(Any::class)
@MergeComponent(scope = Any::class)
interface ComponentInterface
""",
mode = localMode
Expand All @@ -426,16 +423,14 @@ class ContributesMultibindingGeneratorTest(
import com.squareup.anvil.annotations.ContributesMultibinding
import dagger.MapKey
import javax.inject.Singleton
interface ParentInterface
@MapKey
annotation class BindingKey1(val value: String)
@ContributesMultibinding(Any::class)
@BindingKey1("abc")
@Singleton
@ContributesMultibinding(scope = Any::class)
@BindingKey1(value = "abc")
interface ContributingInterface : ParentInterface
""".trimIndent()

Expand All @@ -452,7 +447,7 @@ class ContributesMultibindingGeneratorTest(
}
is AnvilCompilationMode.Ksp -> {
val processor = simpleSymbolProcessor { resolver ->
resolver.getSymbolsWithAnnotation(MergeComponent::class.qualifiedName!!)
resolver.getSymbolsWithAnnotation(MergeComponent::class.qualifiedName!!, inDepth = true)
.map { stubContentToGenerate }
.toList()
}
Expand Down

0 comments on commit 3b0ae66

Please sign in to comment.