Enable log levels by using the -D
flag within the C++ compiler
Lower log levels will include all high level logs.
DEBUG
, Create log lines usingDEBUG_LOG(x)
INFO
, Create log lines usingINFO_LOG(x)
WARN
, Create log lines usingWARN_LOG(x)
ERROR
, Create log lines usingERROR_LOG(x)
Assertions will perform an action conditional on the provided assertion predicate failing.
To enable use the -DASSERTIONS
flag on the C++ compiler
ASSERT(bool expectation, std::string throwString)
, Throws a logic error with the given throwString message if the expectation predicate failsUNEXPECTED_ERROR_LOG(bool expectation, std::string logString)
, Logs an error if the expectation predicate fails. This will also be enabled if theERROR
log level is enabled.