| 444 | |
| 445 | |
| 446 | int main() |
| 447 | { |
| 448 | NanoLog::setLogFile("testLog"); |
| 449 | evilTestCase(NULL); |
| 450 | testAllTheTypes(); |
| 451 | |
| 452 | int count = 10; |
| 453 | uint64_t start = PerfUtils::Cycles::rdtsc(); |
| 454 | for (int i = 0; i < count; ++i) { |
| 455 | NANO_LOG(NOTICE, "Loop test!"); |
| 456 | } |
| 457 | |
| 458 | uint64_t stop = PerfUtils::Cycles::rdtsc(); |
| 459 | |
| 460 | double time = PerfUtils::Cycles::toSeconds(stop - start); |
| 461 | printf("Total time 'benchmark recording' %d events took %0.2lf seconds " |
| 462 | "(%0.2lf ns/event avg)\r\n", |
| 463 | count, time, (time/count)*1e9); |
| 464 | |
| 465 | SimpleTest st(10); |
| 466 | st.logSomething(); |
| 467 | st.wholeBunchOfLogStatements(); |
| 468 | st.logStatementsInHeader(); |
| 469 | st.logSomething(); |
| 470 | st.logSomething(); |
| 471 | |
| 472 | logLevelTest(); |
| 473 | |
| 474 | NanoLog::sync(); |
| 475 | |
| 476 | printf("\r\nNote: This app is used in the integration tests, but " |
| 477 | "is not the test runner. \r\nTo run the actual test, invoke " |
| 478 | "\"make run-test\"\r\n\r\n"); |
| 479 | } |
nothing calls this directly
no test coverage detected