Skip to content

Commit

Permalink
mhm
Browse files Browse the repository at this point in the history
  • Loading branch information
FalloutFalcon committed Oct 10, 2024
1 parent 05cb2fa commit 199963e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
11 changes: 4 additions & 7 deletions code/__HELPERS/_logging.dm
Original file line number Diff line number Diff line change
Expand Up @@ -10,27 +10,24 @@
#define WRITE_LOG(log, text) rustg_log_write(log, text, "true")
#define WRITE_LOG_NO_FORMAT(log, text) rustg_log_write(log, text, "false")


#define GITHUB_ACTION_FORMATING(MSG, ERROR_TYPE)

#ifdef UNIT_TESTS
#define WARNING(MSG) warning("file=[__FILE__],line=[__LINE__]::[MSG] src: [UNLINT(src)] usr: [usr].")
#define WARNING(MSG) log_world("::warning file=[__FILE__],line=[__LINE__]::[MSG] src: [UNLINT(src)] usr: [usr].")
#else
#define WARNING(MSG) warning("[MSG] in [__FILE__] at line [__LINE__] src: [UNLINT(src)] usr: [usr].")
#endif
/// Print a warning message to world.log
/proc/warning(msg)
msg = "::warning [msg]"
msg = "## WARNING: [msg]"
log_world(msg)

#ifdef UNIT_TESTS
#define NOTICE(MSG) notice("file=[__FILE__],line=[__LINE__]::[MSG] src: [UNLINT(src)] usr: [usr].")
#define NOTICE(MSG) log_world("::notice file=[__FILE__],line=[__LINE__]::[MSG] src: [UNLINT(src)] usr: [usr].")
#else
#define NOTICE(MSG) notice(MSG)
#endif
///not an error or a warning, but worth to mention on the world log, just in case.
/proc/notice(msg)
msg = "::notice [msg]"
msg = "## NOTICE: [msg]"
log_world(msg)

//print a testing-mode debug message to world.log and world
Expand Down
5 changes: 4 additions & 1 deletion code/modules/unit_tests/icons/worn_icons.dm
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,10 @@

if(mob_overlay_icon) //easiest to check since we override everything. this automatically includes downstream support.
if(!(icon_state in icon_states(mob_overlay_icon, 1)))
TEST_FAIL("[item_path] using invalid [mob_overlay_state ? "mob_overlay_state" : "icon_state"], \"[icon_state]\" in mob_overlay_icon override file, '[mob_overlay_icon]'[match_message]")
if(required_test)
TEST_FAIL("[item_path] using invalid [mob_overlay_state ? "mob_overlay_state" : "icon_state"], \"[icon_state]\" in mob_overlay_icon override file, '[mob_overlay_icon]'[match_message]")
else
TEST_NOITCE(src, "[item_path] using invalid [mob_overlay_state ? "mob_overlay_state" : "icon_state"], \"[icon_state]\" in mob_overlay_icon override file, '[mob_overlay_icon]'[match_message]")
continue

var/icon_file //checks against all the default icon locations if one isn't defined.
Expand Down

0 comments on commit 199963e

Please sign in to comment.