mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-11-27 00:04:42 +00:00
Expect the hotload guard to accept commented pack files
VolmLib's JSONTokener now skips comments, so the guard and the loaders read them the same way.
This commit is contained in:
1 parent
5e211fb1c4
commit
5915a968ff
1 file changed
+8
-4
@@ -38,15 +38,19 @@ public class UnreadablePackFilesTest {
|
||||
}
|
||||
|
||||
@Test
|
||||
public void reportsCommentsBecauseTheLoadersCannotReadThem() throws IOException {
|
||||
public void acceptsCommentsLikeTheLoaders() throws IOException {
|
||||
File biome = write("biome.json", """
|
||||
{
|
||||
// the loaders reject this
|
||||
"name": "Plains"
|
||||
// line comment
|
||||
"name": "Plains", /* block comment */
|
||||
"children": [
|
||||
// "commented-out",
|
||||
"a"
|
||||
]
|
||||
}
|
||||
""");
|
||||
|
||||
assertEquals(1, files.recheck(List.of(biome)).size());
|
||||
assertTrue(files.recheck(List.of(biome)).isEmpty());
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in new issue
Block a user