diff options
author | Andreas Stöckel <astoecke@techfak.uni-bielefeld.de> | 2014-12-05 13:52:40 +0100 |
---|---|---|
committer | Andreas Stöckel <andreas@somweyr.de> | 2014-12-05 13:52:40 +0100 |
commit | ddbea4164e126739f39658627c04e7e23b71e090 (patch) | |
tree | bdac63cf2a1c73fd3f67fa03fc821ef4eaf93b83 /test/core/LoggerTest.cpp | |
parent | 3d6058315f7f0da9994e35c144d0acb76a252472 (diff) | |
parent | 9cb01624a4efe2063d5870f41e033476d9368b6d (diff) |
fixed conflict
Diffstat (limited to 'test/core/LoggerTest.cpp')
-rw-r--r-- | test/core/LoggerTest.cpp | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/test/core/LoggerTest.cpp b/test/core/LoggerTest.cpp index b4549ed..0c333ce 100644 --- a/test/core/LoggerTest.cpp +++ b/test/core/LoggerTest.cpp @@ -26,7 +26,7 @@ namespace ousia { struct Pos { int line, column; - Pos(int line, int column) : line(line), column(column) {}; + Pos(int line, int column) : line(line), column(column){}; int getLine() const { return line; } int getColumn() const { return column; } }; @@ -52,13 +52,23 @@ TEST(TerminalLogger, log) logger.fatalError("This is a test fatal error!", 10, 20); try { - throw LoggableException{"A fatal exception"}; + throw LoggableException{"A fatal exception", true}; } catch (const LoggableException &ex) { logger.log(ex); } - logger.logAt(Severity::ERROR, "This is a positioned error", Pos(10, 20)); + try { + throw LoggableException{"A fatal exception at position", true, Pos(10, 20)}; + } + catch (const LoggableException &ex) { + logger.log(ex); + } + + logger.logAt(Severity::ERROR, "This is a positioned log message", + Pos(10, 20)); + logger.debugAt("This is a positioned debug message", Pos(10, 20)); + logger.noteAt("This is a positioned log error", Pos(10, 20)); } } |