mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-16 03:12:43 +00:00
20 lines
535 B
C++
20 lines
535 B
C++
|
#include <string>
|
||
|
#include <vector>
|
||
|
#include <common/logger_useful.h>
|
||
|
#include <gtest/gtest.h>
|
||
|
|
||
|
#include <Poco/Logger.h>
|
||
|
#include <Poco/AutoPtr.h>
|
||
|
#include <Poco/NullChannel.h>
|
||
|
|
||
|
|
||
|
TEST(Logger, Log)
|
||
|
{
|
||
|
Poco::Logger::root().setLevel("none");
|
||
|
Poco::Logger::root().setChannel(Poco::AutoPtr<Poco::NullChannel>(new Poco::NullChannel()));
|
||
|
Logger * log = &Logger::get("Log");
|
||
|
|
||
|
/// This test checks that we don't pass this string to fmtlib, because it is the only argument.
|
||
|
EXPECT_NO_THROW(LOG_INFO(log, "Hello {} World"));
|
||
|
}
|