aboutsummaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorJonas Herzig <jonas@spark-squared.com>2021-11-13 09:49:17 +0100
committerJonas Herzig <jonas@spark-squared.com>2021-11-13 10:28:09 +0100
commit26107cde7a9c47e444878736a9c34b64744c5f00 (patch)
treebc11fa2540daf0a82e713b2f749daededce38dba /src/test
parentb00673f859058ff180dc16c22e12ac5698ffbab2 (diff)
downloadRemap-26107cde7a9c47e444878736a9c34b64744c5f00.tar.gz
Remap-26107cde7a9c47e444878736a9c34b64744c5f00.tar.bz2
Remap-26107cde7a9c47e444878736a9c34b64744c5f00.zip
Support multi-target mixin injectors
Diffstat (limited to 'src/test')
-rw-r--r--src/test/kotlin/com/replaymod/gradle/remap/mapper/mixin/TestMixinInjections.kt17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/test/kotlin/com/replaymod/gradle/remap/mapper/mixin/TestMixinInjections.kt b/src/test/kotlin/com/replaymod/gradle/remap/mapper/mixin/TestMixinInjections.kt
index 0cba1ae..da68496 100644
--- a/src/test/kotlin/com/replaymod/gradle/remap/mapper/mixin/TestMixinInjections.kt
+++ b/src/test/kotlin/com/replaymod/gradle/remap/mapper/mixin/TestMixinInjections.kt
@@ -162,6 +162,23 @@ class TestMixinInjections {
}
@Test
+ fun `remaps multiple methods`() {
+ TestData.remap("""
+ @org.spongepowered.asm.mixin.Mixin(a.pkg.A.class)
+ class MixinA {
+ @org.spongepowered.asm.mixin.injection.Inject(method = { "aMethod", "aInterfaceMethod" })
+ private void test() {}
+ }
+ """.trimIndent()) shouldBe """
+ @org.spongepowered.asm.mixin.Mixin(b.pkg.B.class)
+ class MixinA {
+ @org.spongepowered.asm.mixin.injection.Inject(method = { "bMethod", "bInterfaceMethod" })
+ private void test() {}
+ }
+ """.trimIndent()
+ }
+
+ @Test
fun `remaps @At target`() {
TestData.remap("""
import org.spongepowered.asm.mixin.injection.At;