Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,8 @@ public static void addLibrary(Logger logger, Path libraryPath, IntelliJEnvironme
if (!Files.exists(libraryPath)) {
throw new UncheckedIOException(new NoSuchFileException(libraryPath.toString()));
}
ijEnv.addJarToClassPath(libraryPath);
if (Files.isDirectory(libraryPath)) ijEnv.addFolderToClasspath(libraryPath);
else ijEnv.addJarToClassPath(libraryPath);
logger.debug("Added %s", libraryPath);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
public C1 get()La/b/c/Reference;
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package a.b.c;

public record Reference(int a) {

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import a.b.c.Reference;

public class C1 {
public Reference get() {
return new Reference(1);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import a.b.c.Reference;

public class C1 {
private Reference get() {
return new Reference(1);
}
}
5 changes: 5 additions & 0 deletions tests/src/test/java/net/neoforged/jst/tests/EmbeddedTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,11 @@ void testMethodsInheritance() throws Exception {
void testHiddenPrefixes() throws Exception {
runATTest("hidden_prefix", "--hidden-prefix=other");
}

@Test
void testFolderClasspathEntries() throws Exception {
runATTest("folder_classpath_entry", "--classpath=" + testDataRoot.resolve("accesstransformer/folder_classpath_entry/deps"));
}
}

@Nested
Expand Down
Loading