Fix to logging following pull request review. Temporary fix to MainTest (change times(1) to atLeastOnce()).