diff --git a/unit_tests/falco/test_configuration.cpp b/unit_tests/falco/test_configuration.cpp index 4c96cba2..47dc8d0f 100644 --- a/unit_tests/falco/test_configuration.cpp +++ b/unit_tests/falco/test_configuration.cpp @@ -18,6 +18,12 @@ limitations under the License. #include #include +#ifdef _WIN32 +#define SET_ENV_VAR(env_var_name, env_var_value) _putenv_s(env_var_name, env_var_value) +#else +#define SET_ENV_VAR(env_var_name, env_var_value) setenv(env_var_name, env_var_value, 1) +#endif + static std::string sample_yaml = "base_value:\n" " id: 1\n"