Skip to content

Commit

Permalink
tweaks to unit tests again
Browse files Browse the repository at this point in the history
  • Loading branch information
FalloutFalcon committed Sep 19, 2024
1 parent 85117b8 commit 8970218
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions code/modules/unit_tests/icons/inhands.dm
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
match_message += (match_message ? " & '[file_place]'" : " - Matching sprite found in: '[file_place]'")

if(!(skip_left || skip_right) && !lefthand_file && !righthand_file)
log_test("Missing both icon files for [item_path].\n\titem_state = \"[item_state]\"[match_message]")
WARNING("Missing both icon files for [item_path].\n\titem_state = \"[item_state]\"[match_message]")
continue

var/missing_left
Expand All @@ -80,7 +80,7 @@
if(!match_message && right_fallback && left_fallback)
fallback_log_message += "\n\t[item_path] has invalid value, using fallback icon.\n\titem_state = \"[item_state]\""
continue
log_test("Missing inhand sprites for [item_path] in both '[lefthand_file]' & '[righthand_file]'.\n\titem_state = \"[item_state]\"[match_message]")
WARNING("Missing inhand sprites for [item_path] in both '[lefthand_file]' & '[righthand_file]'.\n\titem_state = \"[item_state]\"[match_message]")
else if(missing_left)
TEST_FAIL("Missing left inhand sprite for [item_path] in '[lefthand_file]'[left_fallback ? ", using fallback icon" : null].\n\titem_state = \"[item_state]\"[match_message]")
else if(missing_right)
Expand All @@ -90,5 +90,5 @@
TEST_FAIL("Invalid item_state values should be set to null if there isn't a valid icon.[fallback_log_message]")

if(unset_inhand_var_message)
log_test("\tNotice - Possible inhand icon matches found. It is best to be explicit with inhand sprite values.[unset_inhand_var_message]")
WARNING("\tNotice - Possible inhand icon matches found. It is best to be explicit with inhand sprite values.[unset_inhand_var_message]")

2 changes: 1 addition & 1 deletion code/modules/unit_tests/icons/worn_icons.dm
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

var/list/already_warned_icons = list()

for(var/obj/item/item_path as anything in (subtypesof(/obj/item/clothing)))
for(var/obj/item/item_path as anything in (subtypesof(/obj/item)))
var/cached_slot_flags = initial(item_path.slot_flags)
if(!cached_slot_flags || (cached_slot_flags & ITEM_SLOT_LPOCKET) || (cached_slot_flags & ITEM_SLOT_RPOCKET) || initial(item_path.item_flags) & ABSTRACT)
continue
Expand Down
2 changes: 1 addition & 1 deletion code/modules/unit_tests/outfit_sanity.dm
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
if (outfit.random != TRUE)
TEST_FAIL("[outfit.name]'s backpack_contents are invalid! Couldn't add [path] to backpack.")
else
log_test("[outfit.name]'s backpack_contents are invalid! Couldn't add [path] to backpack.")
WARNING("[outfit.name]'s backpack_contents are invalid! Couldn't add [path] to backpack.")


#undef CHECK_OUTFIT_SLOT

0 comments on commit 8970218

Please sign in to comment.