Files
Paradise/code/tests/_map_per_tile_test.dm
warriorstar-orion 8e4dc6165b Separate station/unit tests and disable lavaland procgen and ruin spawning in tests (for now). (#28106)
* Separate station/unit tests and disable lavaland.

* add CI/local test conflict check back
2025-02-08 17:09:00 +00:00

21 lines
621 B
Plaintext

/**
* Map per-tile test.
*
* Per-tile map tests iterate over each tile of a map to perform a check, and
* fails the test if a tile does not pass the check. A new test can be
* written by extending /datum/map_per_tile_test, and implementing the check
* in CheckTile.
*/
/datum/map_per_tile_test
var/succeeded = TRUE
var/list/fail_reasons
var/failure_count = 0
/datum/map_per_tile_test/proc/CheckTile(turf/T)
Fail("CheckTile() called parent or not implemented")
/datum/map_per_tile_test/proc/Fail(turf/T, reason)
succeeded = FALSE
LAZYADD(fail_reasons, "[T.x],[T.y],[T.z]: [reason]")
failure_count++