mirror of
https://github.com/gabime/spdlog.git
synced 2025-09-28 17:19:34 +08:00
1. Fixed file_helper::exists() bug under windows which returned false in some circumstances
2. Improved file_helper::exists() performance under linux to use stat sys call 3. Added unit tests
This commit is contained in:
@@ -10,3 +10,14 @@
|
||||
#include "catch.hpp"
|
||||
#include "../include/spdlog/spdlog.h"
|
||||
#include "../include/spdlog/sinks/null_sink.h"
|
||||
|
||||
|
||||
static void prepare_logdir()
|
||||
{
|
||||
spdlog::drop_all();
|
||||
#ifdef _WIN32
|
||||
auto rv = system("del /F /Q logs\\*");
|
||||
#else
|
||||
auto rv = system("rm -f logs/*");
|
||||
#endif
|
||||
}
|
Reference in New Issue
Block a user