From b70e0a51a74dc33e0f24afae1bd490437625ae97 Mon Sep 17 00:00:00 2001 From: "Sascha Schade (strongly-typed)" Date: Sun, 14 May 2017 18:36:13 +0200 Subject: [PATCH] [tests] Include build info for unittest. --- src/SConstruct | 3 +++ templates/unittest/runner_stm32.cpp.in | 7 +++++++ 2 files changed, 10 insertions(+) diff --git a/src/SConstruct b/src/SConstruct index b12a75cd3..f20fffd52 100644 --- a/src/SConstruct +++ b/src/SConstruct @@ -118,6 +118,9 @@ else: template = template) sources = [runner] + files.sources + + # build xpcc_build_info.hpp file + env.BuildInfoHeader() # build the program program = env.Program(target = 'executable', diff --git a/templates/unittest/runner_stm32.cpp.in b/templates/unittest/runner_stm32.cpp.in index 32396a9bd..6dde3c53a 100644 --- a/templates/unittest/runner_stm32.cpp.in +++ b/templates/unittest/runner_stm32.cpp.in @@ -4,6 +4,8 @@ #include +#include + #include #include @@ -36,6 +38,11 @@ main() loggerDevice.write("Unittests (" __DATE__ ", " __TIME__")\n"); + XPCC_LOG_INFO << "Machine: " << XPCC_BUILD_MACHINE << xpcc::endl; + XPCC_LOG_INFO << "User: " << XPCC_BUILD_USER << xpcc::endl; + XPCC_LOG_INFO << "Os: " << XPCC_BUILD_OS << xpcc::endl; + XPCC_LOG_INFO << "Compiler: " << XPCC_BUILD_COMPILER << xpcc::endl; + unittest::Reporter reporter(loggerDevice); unittest::Controller::instance().setReporter(reporter);