Fix exit signal race condition in logger tests

Test process must wait for exit signal before untrapping exits,
otherwise exit signal may cause it to exit.
Merge pull request #2743 from fishcakez/loggertest_exit_signal_rc

Fix exit signal race condition in logger tests