diff --git a/src/preferences/preferences.hpp b/src/preferences/preferences.hpp index 14dcd3900e6fc..d39728f589fb5 100644 --- a/src/preferences/preferences.hpp +++ b/src/preferences/preferences.hpp @@ -204,8 +204,9 @@ class prefs { // for wesnoth: checks that the userdata folders have been initialized/found since if it hasn't been then it's too soon to be getting any values from it // for boost: the userdata folders don't get initialized and the preferences aren't used for anything, so skip the check here - // TODO: figure out how to make this not fail for all the other tests too - static bool called_before_init = !(filesystem::base_name(filesystem::get_exe_path()).find("boost") == std::string::npos && !filesystem::is_userdata_initialized()); + // macos - called "unit_tests" + // others - called "boost_unit_tests" + static bool called_before_init = !(filesystem::base_name(filesystem::get_exe_path()).find("unit_tests") == std::string::npos && !filesystem::is_userdata_initialized()); assert(called_before_init && "Attempt to use preferences before userdata initialization"); static prefs prefs_manager;