Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
FORMUS3IC_LAS3
/
embb
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
eec3dd7d
authored
9 years ago
by
Marcus Winter
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
base_cpp: fixed error in log test
parent
a6c4506a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
base_cpp/test/log_test.cc
+12
-0
No files found.
base_cpp/test/log_test.cc
View file @
eec3dd7d
...
...
@@ -55,10 +55,18 @@ void LogTest::Test() {
Log
::
SetLogLevel
(
EMBB_LOG_LEVEL_TRACE
);
logged_message
=
null
;
Log
::
Trace
(
"chn"
,
test_msg
);
#ifdef EMBB_DEBUG
PT_EXPECT
(
0
==
strcmp
(
logged_message
,
"[chn] - [TRACE] hello"
));
#else
PT_EXPECT_EQ
(
null
,
logged_message
);
#endif
logged_message
=
null
;
Log
::
Info
(
"chn"
,
test_msg
);
#ifdef EMBB_DEBUG
PT_EXPECT
(
0
==
strcmp
(
logged_message
,
"[chn] - [INFO ] hello"
));
#else
PT_EXPECT_EQ
(
null
,
logged_message
);
#endif
logged_message
=
null
;
Log
::
Warning
(
"chn"
,
test_msg
);
PT_EXPECT
(
0
==
strcmp
(
logged_message
,
"[chn] - [WARN ] hello"
));
...
...
@@ -72,7 +80,11 @@ void LogTest::Test() {
PT_EXPECT_EQ
(
null
,
logged_message
);
logged_message
=
null
;
Log
::
Info
(
"chn"
,
test_msg
);
#ifdef EMBB_DEBUG
PT_EXPECT
(
0
==
strcmp
(
logged_message
,
"[chn] - [INFO ] hello"
));
#else
PT_EXPECT_EQ
(
null
,
logged_message
);
#endif
logged_message
=
null
;
Log
::
Warning
(
"chn"
,
test_msg
);
PT_EXPECT
(
0
==
strcmp
(
logged_message
,
"[chn] - [WARN ] hello"
));
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment