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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
node_modules/
.vscode
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
{
"$schema": "https://raw.githubusercontent.com/FlintTestMC/flint-core/refs/heads/main/flint-content/test_spec_schema.json",
"flintVersion": null,
"name": "fence_connection",
"description": "Tests fence connection behavior across different wood types (oak, birch, jungle, spruce, dark_oak, mangrove, cherry, acacia, pale_oak, warped, crimson, bamboo) and validates connections/disconnections with non-fence blocks.",
"tags": ["connectible", "fence", "wood-types", "block-state", "neighbor-update"],
"dependencies": [],
"minecraftIds": ["minecraft:oak_fence"],
"setup": {
"cleanup": {
"region": [ [-3, -1, -2], [1, 1, 2] ]
Expand Down
122 changes: 122 additions & 0 deletions tests/connectible/fences/fence_row_connections.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
{
"$schema": "https://raw.githubusercontent.com/FlintTestMC/flint-core/refs/heads/main/flint-content/test_spec_schema.json",
"name": "fence_row_connections",
"description": "Places fences in a row, one per tick, and verifies they connect to each other",
"tags": ["connectible", "fence", "wood-types", "block-state", "neighbor-update"],
"minecraftIds": ["minecraft:oak_fence"],
"setup": {
"cleanup": {
"region": [ [0, 63, 0], [10, 66, 2] ]
}
},
"timeline": [
{
"at": 0,
"do": "fill",
"region": [ [0, 63, 0], [10, 63, 2] ],
"with": {"id": "minecraft:stone"}
},
{ "at": 1, "do": "place", "pos": [0, 64, 0], "block": {"id": "minecraft:oak_fence"} },
{
"at": 1,
"do": "assert",
"checks": [
{ "pos": [0, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "false", "west": "false"} }
]
},
{ "at": 2, "do": "place", "pos": [1, 64, 0], "block": {"id": "minecraft:oak_fence"} },
{
"at": 2,
"do": "assert",
"checks": [
{ "pos": [0, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "true" } },
{ "pos": [1, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "false", "west": "true"} }
]
},
{ "at": 3, "do": "place", "pos": [2, 64, 0], "block": {"id": "minecraft:oak_fence"} },
{
"at": 3,
"do": "assert",
"checks": [
{ "pos": [0, 64, 0], "is": {"id": "minecraft:oak_fence" } },
{ "pos": [1, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "true" , "west": "true"} },
{ "pos": [2, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "false", "west": "true"} }
]
},
{ "at": 4, "do": "place", "pos": [3, 64, 0], "block": {"id": "minecraft:oak_fence"} },
{
"at": 4,
"do": "assert",
"checks": [
{ "pos": [2, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "true" , "west": "true"} },
{ "pos": [3, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "false", "west": "true"} }
]
},
{ "at": 5, "do": "place", "pos": [4, 64, 0], "block": {"id": "minecraft:oak_fence"} },
{
"at": 5,
"do": "assert",
"checks": [
{ "pos": [3, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "true" , "west": "true"} },
{ "pos": [4, 64, 0], "is": {"id": "minecraft:oak_fence", "east": "false", "west": "true"} }
]
},
{
"at": 6,
"do": "assert",
"checks": [
{
"pos": [0, 64, 0],
"is": {
"id" : "minecraft:oak_fence",
"east" : "true" ,
"west" : "false" ,
"north": "false" ,
"south": "false"
}
},
{
"pos": [1, 64, 0],
"is": {
"id" : "minecraft:oak_fence",
"east" : "true" ,
"west" : "true" ,
"north": "false" ,
"south": "false"
}
},
{
"pos": [2, 64, 0],
"is": {
"id" : "minecraft:oak_fence",
"east" : "true" ,
"west" : "true" ,
"north": "false" ,
"south": "false"
}
},
{
"pos": [3, 64, 0],
"is": {
"id" : "minecraft:oak_fence",
"east" : "true" ,
"west" : "true" ,
"north": "false" ,
"south": "false"
}
},
{
"pos": [4, 64, 0],
"is": {
"id" : "minecraft:oak_fence",
"east" : "false" ,
"west" : "true" ,
"north": "false" ,
"south": "false"
}
}
]
}
]
}

36 changes: 36 additions & 0 deletions tests/connectible/fences/place_fence.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"$schema": "https://raw.githubusercontent.com/FlintTestMC/flint-core/refs/heads/main/flint-content/test_spec_schema.json",
"flintVersion": "1.1",
"name": "place_fence",
"description": "Tests fence connection behavior across different wood types (oak, birch, jungle, spruce, dark_oak, mangrove, cherry, acacia, pale_oak, warped, crimson, bamboo) and validates connections/disconnections with non-fence blocks.",
"tags": ["connectible", "fence", "wood-types", "block-state", "neighbor-update"],
"minecraftIds": ["minecraft:oak_fence"],
"dependencies": [],
"setup": {
"cleanup": {
"region": [ [0, 0, 0], [0, 1, 0] ]
}
},
"timeline": [
{ "at": 0, "do": "place", "pos": [0, 0, 0], "block": {"id": "minecraft:stone"} },
{
"at": 1,
"do": "assert",
"checks": [
{ "pos": [0, 0, 0], "is": {"id": "minecraft:stone"} }
]
},
{ "at": 1, "do": "use_item_on", "pos": [0, 0, 0], "face": "top", "item": "oak_fence" },
{
"at": 2,
"do": "assert",
"checks": [
{ "pos": [0, 0, 0], "is": {"id": "minecraft:stone"} },
{ "pos": [0, 1, 0], "is": {"id": "minecraft:oak_fence"} },
{ "is": "empty" , "slot": "hotbar1" }
]
}
],
"breakpoints": []
}

1 change: 1 addition & 0 deletions tests/connectible/iron.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"$schema": "https://raw.githubusercontent.com/FlintTestMC/flint-core/refs/heads/main/flint-content/test_spec_schema.json",
"flintVersion": null,
"name": "connectible_iron",
"description": "Tests iron bars connection behavior with adjacent blocks (solid blocks, barriers, walls, pane-type blocks) and validates correct directional connection states.",
Expand Down
Loading
Loading