mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
* Updates our unit testing to be much better than it is now Updates our unit testing to somewhat more functional ones ported from TG I also added 2 new unit tests to serve as examples, mapping and job landmarks. * Revert some minor things * Fixes the log file * Update unit_tests.dm * adds a missing icon * additional changes
12 lines
497 B
Plaintext
12 lines
497 B
Plaintext
/datum/unit_test/component_duping/Run()
|
|
var/list/bad_dms = list()
|
|
var/list/bad_dts = list()
|
|
for(var/datum/component/comp as anything in typesof(/datum/component))
|
|
if(!isnum(initial(comp.dupe_mode)))
|
|
bad_dms += comp
|
|
var/dupe_type = initial(comp.dupe_type)
|
|
if(dupe_type && !ispath(dupe_type))
|
|
bad_dts += comp
|
|
if(length(bad_dms) || length(bad_dts))
|
|
TEST_FAIL("Components with invalid dupe modes: ([bad_dms.Join(",")]) ||| Components with invalid dupe types: ([bad_dts.Join(",")])")
|