| ID | Summary | Committer | Date |
|---|
| 0e5a261c | - Make CLAUDE.md a symlink to AGENTS.md
| albert pham | 4 hours ago |
| d67faa39 | - Add AGENTS.md guide for coding agents
Covers setup from a fresh clone, building, testing at each level, manual
play-testing, and the editing architecture and its rules. CLAUDE.md imports it.
| albert pham | 5 hours ago |
| e044d0d3 | - Add Fabric client GameTests
Enables Fabric's client GameTest runner (runClientGameTest) and adds a test
that runs //pos1, //pos2, //set and //undo as the player in a singleplayer
world, checks the blocks, and saves a screenshot.
| albert pham | 5 hours ago |
| d283fb92 | - Update tests for current master
- RegionIntersection was renamed to RegionUnion.
- Bundled registries are gone; TestRegistries now extends AbstractRegistries,
and TestBlockRegistry overrides getMaterial(BlockState).
- The snapshot API moved out of the experimental package.
| albert pham | 5 hours ago |
| 99e8821f | - Add Fabric GameTests for biomes, generation, regen and snapshot restore
- BiomeGameTest: set/get round trips, 4x4x4 cell granularity, native agreement
- GenerationGameTest: trees generated on ground that only exists in a buffered
EditSession (cf. f002c034f), plus a feature test. The feature test
(forest_rock) is a known failure, marked required = false:
CoreMcServerLevelDelegateProxy doesn't intercept
WorldGenLevel#setBlockAndUpdate, so BlockBlobFeature writes straight to the
world instead of the session.
- RegenGameTest: //regen on Fabric restores terrain into the world or a
clipboard, regenerates biomes, and rejects seeds
- SnapshotRestoreGameTest: restores from chunks serialised by this Minecraft
version (cf. d4b3cc49a), only touches the requested region, reports
missing chunks
| albert pham | 11 days ago |
| 1f2cf7bb | - Add Fabric GameTests for block round-trips, NBT, entity paste and side effects
BlockRoundTripGameTest sets every state of stairs, rails, doors, beds, chests,
the crafter and ~20 other directional families through the platform world with
no side effects and the defaults, and checks the real ServerLevel's block via
native property names, plus what the platform world reads back.
BlockEntityNbtGameTest round-trips sign (including the mixed component list
from #2777; it fails with the addAndUnwrap fix reverted), chest and skull NBT,
with and without side effects.
EntityCopyPasteGameTest copies a region of item frames, paintings, armor stands
and a leashed cow with a home position to the clipboard and pastes under
identity, 90/180/270 rotations, X/Z flips and flip+rotate. Expectations come
from the transform alone: hanging entities' bounding boxes and facing, free
entities' feet position and yaw, leash and home_pos, floor item-frame rotation.
SideEffectsGameTest checks NEIGHBORS (redstone lamp), UPDATE (scheduled sand
tick) and that light follows an emitter.
Finding: flipping a painting that is 2 wide or tall leaves it one block off
(ExtentEntityCopy mirrors only block_pos). Pure rotations are fine. The three
flip tests exclude those paintings, and flipX/flipZ/flipXAndRotate90
EvenSizedPaintings reproduce it as required = false tests (GameTest has no
@Disabled; manualOnly would hide them from the run). Production code untouched.
Review notes (findings not acted on):
- powered/enabled are ignored in the updates-on pass because vanilla recomputes
them on neighbour updates; the updates-off pass checks every property.
- The LIGHTING side effect can't be shown to matter: vanilla queues its own
light check on emission change, so on/off give identical light. The test is a
guard that light follows an emitter, not a LIGHTING on/off comparison.
- The item-frame quarter-turn test accepts either turn direction; only the 180
case pins the sense, as the vanilla sense o...
| albert pham | 11 days ago |
| 42d41eef | - Add Fabric GameTest source set with a //set-style walking skeleton
Configures fabricApi.configureTests for worldedit-fabric (server game
tests only), adds the fabric-gametest-api-v1 dependency to the gametest
source set, and one test that sets a 3x3x3 cuboid to stone via an
EditSession on the test ServerLevel. runGameTest is wired into build.
Review notes: a reviewer worried the default template is 1x1x1; it is
Fabric's 8x8x8 empty structure, so the cuboid stays inside the test box.
| albert pham | 11 days ago |
| f80678d0 | - 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.
| albert pham | 11 days ago |
| 30ca9f1c | - Add copy, history and extent tests
Cover ForwardExtentCopy, OperationQueue/Operations, ChangeSetExecutor,
ArrayListHistory/BlockOptimizedHistory undo/redo round-trips on random
edit sequences, BlockArrayClipboard, masking/tracing/null/buffer/delegate
extents, MultiStageReorder, ChunkBatchingExtent and EditSession buffering.
Two real bugs found, recorded as @Disabled tests:
- ChangeSetExtent(Extent, ChangeSet, boolean) ignores its 'enabled' argument
- MultiStageReorder keeps earlier writes to a position in a different stage,
so the last write does not always win
| albert pham | 11 days ago |
| 71208afa | - Add parser tests and mask/pattern algebra tests
Table-driven tests for DefaultBlockParser (including the #3017 bracket
and NBT handling), DefaultItemParser, and the mask and pattern parsers,
plus algebraic-law tests for MaskIntersection/MaskUnion/Masks.negate,
OffsetMask, OffsetsMask, BoundedHeightMask and RandomPattern weights, and
quoted-argument cases for CommandArgParser.
TestBlockRegistry now returns a minimal BlockMaterial (air vs solid) so
existence masks work.
Disabled tests record suspected bugs: empty block state list, malformed
noise masks escaping as NumberFormatException, TypeApplyingPattern state
carry-over, and the empty MaskIntersection result.
| albert pham | 11 days ago |
| 1837a8e3 | - Add real-block-state test fixture and re-enable BlockTransformExtentTest
Add TestBlockRegistry, TestRegistries and TestWorld plus test-blocks.json
(50 blocks with real properties) so core tests no longer run against
property-less blocks. BaseWorldEditTest now uses TestRegistries.
Re-enable BlockTransformExtentTest on top of BaseWorldEditTest, fix its
loop (it transformed the base state each pass), and check rotation and
flip round-trips for every state of every fixture block. Add known-state
transform tables and BlockState.with/getAllStates/FuzzyBlockState tests.
Four real bugs found by the new tests are recorded as @Disabled tests:
rail NPE on X/Z rotation, crafter orientation loss on Z rotation,
down-facing hopper under vertical flip, door hinge not swapped on mirror.
| albert pham | 11 days ago |
| 4e4039de | - Add tests for visitors, collections, interpolation, noise, Direction and TargetBlock
- Visitors are compared against a reference flood fill over random masks
(uniqueness, breadth-first order, directions/diagonals, determinism).
- Int2BaseBlockMap is checked against a HashMap model; DoubleArrayList
against ArrayList.
- Direction, TargetBlock ray cases, interpolation and noise invariants.
Four tests are @Disabled because they expose production bugs, which are
intentionally not fixed here:
- LinearInterpolation throws IndexOutOfBounds at t=1.0 (getPosition,
arcLength) and with a single node.
- KochanekBartelsInterpolation.arcLength skips the last trapezoid sample
and underestimates by about 1/8.
- ReparametrisingInterpolation.get1stDerivative returns NaN for
zero-length curves.
| albert pham | 11 days ago |
| 0857f70a | - Add region contract, cuboid, degenerate-shape and selector tests
- RegionContractTest: one parameterised contract (iterator count vs volume,
contains vs iterator, bounding box, chunks/chunk cubes, shift, expand/contract,
clone, flat-region agreement) over Cuboid, Cylinder, Ellipsoid, ConvexPolyhedral,
Polygonal2D, RegionIntersection (incl. walls/faces) and TransformRegion.
- CuboidRegionTest: dimensions/overflow, world Y clamping, expand/contract
direction, faces/walls, chunks, jqwik properties.
- RegionDegenerateShapesTest: undefined/planar hulls, zero/negative height.
- RegionSelectorStateTest: select/clear/isDefined/IncompleteRegionException
state machine for every RegionSelectorType with a mocked World.
- BaseWorldEditTest now stubs the platform's TranslationManager so
WorldEditException subclasses can be constructed in tests.
Bugs found are reproduced in @Disabled tests (production code untouched):
AbstractRegion.getChunks only scans the lowest Y layer; AbstractRegion.getVolume
overflows int subtraction; CuboidRegion iterator breaks at Integer.MIN/MAX_VALUE;
ConvexPolyhedralRegion leaves a stale lastTriangle after addVertex; fractional
radius bounding boxes in Cylinder/Ellipsoid; Cylinder/Ellipsoid contract()
direction flipped and radius clamp grows small shapes; negative cylinder
height; TransformRegion bounds under rotation; RegionIntersection volume is its
bounding box; empty/triangle convex hulls; selector vertex limit off by one and
getPrimaryPosition not throwing.
| albert pham | 11 days ago |
| dd32f7b2 | - Add unit tests for transforms and vector math
jqwik property tests plus example tests for AffineTransform,
CombinedTransform, ScaleAndTranslateTransform, Transforms, Vector2,
Vector3, BlockVector2 and MathUtils.
AffineTransformTest has one @Disabled test: the deprecated 9-element
AffineTransform constructor (indexCoeffs) puts the zero holes at indices
3, 6, 9 instead of 3, 7, 11. Production code is unchanged.
| albert pham | 11 days ago |