enh: test coverage of tlog
This commit is contained in:
parent
487b79c5f9
commit
db56c38b5f
|
@ -23,7 +23,7 @@ extern "C" {
|
||||||
#include "tlog.h"
|
#include "tlog.h"
|
||||||
|
|
||||||
void taosOpenNewSlowLogFile();
|
void taosOpenNewSlowLogFile();
|
||||||
void taosLogObjSetTimeStamp(int64_t ts);
|
void taosLogObjSetToday(int64_t ts);
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
@ -541,7 +541,7 @@ void taosResetLog() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void taosLogObjSetTimeStamp(int64_t ts) { tsLogObj.timestampToday = ts; }
|
void taosLogObjSetToday(int64_t ts) { tsLogObj.timestampToday = ts; }
|
||||||
|
|
||||||
static bool taosCheckFileIsOpen(char *logFileName) {
|
static bool taosCheckFileIsOpen(char *logFileName) {
|
||||||
TdFilePtr pFile = taosOpenFile(logFileName, TD_FILE_WRITE);
|
TdFilePtr pFile = taosOpenFile(logFileName, TD_FILE_WRITE);
|
||||||
|
|
|
@ -57,7 +57,7 @@ TEST(log, misc) {
|
||||||
EXPECT_EQ(taosInitLog("taoslog", 1, true), 0);
|
EXPECT_EQ(taosInitLog("taoslog", 1, true), 0);
|
||||||
|
|
||||||
taosOpenNewSlowLogFile();
|
taosOpenNewSlowLogFile();
|
||||||
taosLogObjSetTimeStamp(INT64_MIN);
|
taosLogObjSetToday(INT64_MIN);
|
||||||
taosPrintSlowLog("slow log test");
|
taosPrintSlowLog("slow log test");
|
||||||
|
|
||||||
// test taosInitLogOutput
|
// test taosInitLogOutput
|
||||||
|
|
Loading…
Reference in New Issue