Files
Albert PhamandClaude Sonnet 5.5 498c36ea44 Add schematic I/O tests (Sponge v1/v2/v3, MCEdit) and intern test properties
TestBlockRegistry now shares one Property instance per name, type and value
list, as the real platforms do (CoreMcTransmogrifier's propertyCache). With
that, the TypeApplyingPattern test in PatternParserTest passes, so it is
re-enabled: it was a fixture artifact, not a bug. None of the other
@Disabled findings depend on per-type Property instances.

New tests in extent/clipboard/io:
- SpongeSchematicRoundTripTest: write/read round trips for V2 and V3 over
  negative, degenerate and offset-origin regions, palettes of 1-2000 states,
  block entities, entities, biomes, size limits (V1 and MCEdit have no writer).
- SpongeVarIntTest: sparse palette indices at every varint length edge
  (127/128, 16383/16384, up to Integer.MAX_VALUE) in hand-built V2/V3 files.
- GoldenSchematicTest: tiny stored V1/V2/V3/MCEdit files (generated by a
  standalone script, not by WorldEdit) that must keep loading.
- CorruptSchematicTest: truncation at every byte, garbage, missing/mistyped
  tags, bad palettes and varints, version mismatches.
- SchematicDataFixerTest: when the DataFixer is applied and from which
  version, using a recording stand-in (real DFU needs Minecraft).
- ClipboardFormatsTest: alias/extension registry and format detection.

Real bugs found are recorded as @Disabled tests in CorruptSchematicTest:
NPE on a palette index missing from the palette, block data length not
checked against the dimensions (too short and too long), getDataVersion
throwing for a foreign Version, and two ArrayIndexOutOfBounds cases in
MCEditSchematicReader.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-02 19:29:04 -08:00
..