Skip to content

Commit 01ac31b

Browse files
make :enigma-cli:test depend on test input obf tasks
make SearchMappingsTest use its own, islolated jar
1 parent 5b68095 commit 01ac31b

File tree

24 files changed

+155
-19
lines changed

24 files changed

+155
-19
lines changed

enigma-cli/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ application {
1515
jar.manifest.attributes 'Main-Class': mainClass
1616
}
1717

18+
test.dependsOn(project(':enigma').tasks.named('obfuscateAllTestInput'))
19+
1820
publishing {
1921
publications {
2022
"$project.name"(MavenPublication) {

enigma-cli/src/test/java/org/quiltmc/enigma/command/SearchMappingsTest.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@
2222
import static org.quiltmc.enigma.TestUtil.getResource;
2323

2424
public class SearchMappingsTest {
25-
private static final Path JAR = TestUtil.obfJar("complete");
25+
// private static final Path JAR = TestUtil.obfJar("complete");
26+
private static final Path JAR = TestUtil.obfJar("search_mappings");
2627
private static final Path MAPPINGS = getResource("/search_mappings");
2728

2829
// classes
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
CLASS Z OtherReturnInterface
1+
CLASS f OtherReturnInterface
22
METHOD a abstractMethod (I)C
33
ARG 1 intParam
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
CLASS aa OuterClass
1+
CLASS g OuterClass
22
CLASS a InnerClass
3-
METHOD a getOther ()LZ;
3+
METHOD a getOther ()Lf;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
CLASS t ParamType
1+
CLASS h ParamType
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
CLASS l SelfReturnEnum
2-
METHOD a staticGetArray ()[Ll;
3-
METHOD a staticGet (Ljava/lang/String;)Ll;
1+
CLASS i SelfReturnEnum
2+
METHOD a staticGetArray ()[Li;
3+
METHOD a staticGet (Ljava/lang/String;)Li;
44
ARG 0 staticStringParam

enigma-cli/src/test/resources/search_mappings/I.mapping renamed to enigma-cli/src/test/resources/search_mappings/a.mapping

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
CLASS I
1+
CLASS a
22
FIELD a privateStringField Ljava/lang/String;

enigma-cli/src/test/resources/search_mappings/ac.mapping renamed to enigma-cli/src/test/resources/search_mappings/b.mapping

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
CLASS ac
1+
CLASS b
22
FIELD a floatField F
33
FIELD a intField I
44
FIELD a stringField Ljava/lang/String;
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
CLASS c
2+
METHOD a staticVoidMethod (Lh;)V
3+
ARG 0 staticTypedParam

enigma-cli/src/test/resources/search_mappings/V.mapping renamed to enigma-cli/src/test/resources/search_mappings/d.mapping

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
CLASS V
1+
CLASS d
22
FIELD a recordInt I
33
FIELD a recordString Ljava/lang/String;
44
FIELD b PRIVATE_STATIC_FINAL_INT_FIELD I

0 commit comments

Comments
 (0)