libcryfs/test/cpp-utils/logging/LoggerTest.cpp
Sebastian Messmer cc7b38b3c1 - run-clang-tidy.sh also runs on test cases.
- fix clang-tidy warnings in test cases
2017-12-01 15:01:49 +00:00

20 lines
404 B
C++

#include "testutils/LoggingTest.h"
/*
* Contains test cases for the Logger class
*/
using namespace cpputils::logging;
using std::string;
class LoggerTest: public LoggingTest {};
TEST_F(LoggerTest, IsSingleton) {
ASSERT_EQ(&logger(), &logger());
}
TEST_F(LoggerTest, SetLogger) {
logger().setLogger(spdlog::stderr_logger_mt("MyTestLog1"));
EXPECT_EQ("MyTestLog1", logger()->name());
}