mirror of
https://github.com/gabime/spdlog.git
synced 2025-11-16 09:28:56 +08:00
fix/issue-3101: fix the issue where mdc ignores SPDLOG_NO_TLS (#3184)
Co-authored-by: dyf <yufeng.duan@senscape.com.cn>
This commit is contained in:
@@ -501,6 +501,7 @@ TEST_CASE("override need_localtime", "[pattern_formatter]") {
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef SPDLOG_NO_TLS
|
||||
TEST_CASE("mdc formatter test-1", "[pattern_formatter]") {
|
||||
spdlog::mdc::put("mdc_key_1", "mdc_value_1");
|
||||
spdlog::mdc::put("mdc_key_2", "mdc_value_2");
|
||||
@@ -628,3 +629,4 @@ TEST_CASE("mdc empty", "[pattern_formatter]") {
|
||||
|
||||
SECTION("Tear down") { spdlog::mdc::clear(); }
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user