Skip to content

Commit 239253d

Browse files
committed
Fix test classes being included in prod jar
1 parent c786785 commit 239253d

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

versions/build.gradle.kts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
@file:Suppress("UnstableApiUsage")
22
// Shared build logic for all versions of OneConfig.
33

4-
import org.gradle.api.internal.artifacts.dependencies.DefaultExternalModuleDependency
54
import org.polyfrost.gradle.provideIncludedDependencies
65
import org.polyfrost.gradle.util.noServerRunConfigs
76
import java.text.SimpleDateFormat
@@ -133,7 +132,8 @@ tasks {
133132
exclude("mcmod.info")
134133
}
135134
}
136-
// Removes the TestMod entrypoint from the generated JARs.
135+
136+
// Removes the test-related stuff from everything
137137
doLast {
138138
val mainResources = layout.buildDirectory.get().asFile.resolve("resources")
139139
.resolve("main")
@@ -144,6 +144,8 @@ tasks {
144144
fabricModJson.writeText(lines.joinToString("\n"))
145145
}
146146
}
147+
exclude("**/**_Test.**")
148+
exclude("**/**_Test$**.**")
147149
}
148150
remapJar {
149151
from(shadow.files.map { zipTree(it) })

0 commit comments

Comments
 (0)