diff --git a/code/modules/unit_tests/_unit_tests.dm b/code/modules/unit_tests/_unit_tests.dm index d4bfa21201be..afb4beecae14 100644 --- a/code/modules/unit_tests/_unit_tests.dm +++ b/code/modules/unit_tests/_unit_tests.dm @@ -76,6 +76,7 @@ #include "keybinding_init.dm" #include "machine_disassembly.dm" #include "open_air.dm" +#include "outfit_names.dm" #include "outfit_sanity.dm" #include "overmap.dm" #include "pills.dm" diff --git a/code/modules/unit_tests/outfit_names.dm b/code/modules/unit_tests/outfit_names.dm new file mode 100644 index 000000000000..7db74ed8a165 --- /dev/null +++ b/code/modules/unit_tests/outfit_names.dm @@ -0,0 +1,12 @@ +/datum/unit_test/outfit_names/Run() + var/list/outfit_names = list() + + for(var/outfit_type in subtypesof(/datum/outfit)) + var/name = initial(outfit_type.name) + + if(name in outfit_names) + TEST_FAIL("Outfit name [name] is not unique: [outfit_type], [outfit_names[name]]") + + outfit_names[name] = outfit_type + +