diff --git a/code/modules/unit_tests/_unit_tests.dm b/code/modules/unit_tests/_unit_tests.dm index 42799ddb49af..ba42b9bc9f46 100644 --- a/code/modules/unit_tests/_unit_tests.dm +++ b/code/modules/unit_tests/_unit_tests.dm @@ -86,7 +86,6 @@ #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 deleted file mode 100644 index b381bfeb7bf5..000000000000 --- a/code/modules/unit_tests/outfit_names.dm +++ /dev/null @@ -1,12 +0,0 @@ -/datum/unit_test/outfit_names/Run() - var/list/outfit_names = list() - - for(var/datum/outfit/outfit_type as anything 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 - - diff --git a/code/modules/unit_tests/outfit_sanity.dm b/code/modules/unit_tests/outfit_sanity.dm index 5a9e6bbc2bd0..a09395d42103 100644 --- a/code/modules/unit_tests/outfit_sanity.dm +++ b/code/modules/unit_tests/outfit_sanity.dm @@ -26,6 +26,7 @@ var/prototype_name = initial(prototype_outfit.name) var/mob/living/carbon/human/H = allocate(/mob/living/carbon/human) + var/list/outfit_names = list() for (var/outfit_type in subtypesof(/datum/outfit)) // Only make one human and keep undressing it because it's much faster for (var/obj/item/I in H.get_equipped_items(include_pockets = TRUE)) @@ -33,8 +34,12 @@ var/datum/outfit/outfit = new outfit_type - if(outfit.name == prototype_name) + var/outfit_name = outfit.name + if(outfit_name == prototype_name) TEST_FAIL("[outfit.type]'s name is invalid! Uses default outfit name!") + if(outfit_name in outfit_names) + TEST_FAIL("Outfit name [outfit_name] is not unique: [outfit_type], [outfit_names[outfit_name]]") + outfit_names[outfit_name] = outfit_type outfit.pre_equip(H, TRUE) CHECK_OUTFIT_SLOT(uniform, ITEM_SLOT_ICLOTHING)