Add asserts for set_cell_gid write API

Covers happy-path round-trip, bounds rejection (positive and negative),
unknown-layer rejection, and on-demand layer allocation.
This commit is contained in:
Axel Meyer
2026-05-24 00:25:12 +02:00
parent 1ee19b4b7f
commit 8453b1fc8f
2 changed files with 52 additions and 0 deletions

16
maps/write_test.map.json Normal file
View File

@@ -0,0 +1,16 @@
{
"schema_version": 2,
"id": "write_test",
"size": { "w": 4, "h": 4 },
"atlases": ["demo_tilemap"],
"layers": {
"surface": {
"tiles": [
0, 0, 0, 0,
0, 0, 0, 0,
0, 0, 0, 0,
0, 0, 0, 0
]
}
}
}