Generalize HSIT log termination

Share log file termination code between HSIT master and slave
Activate compiler warnings for unit test builds

Warnings for Unity are suppressed