Fix for #424. Fixed logger.t to prevent warning on windows. Fixed regex used in test

These fixes were on the advice of @veryrusty
 
Windows doesn't allow open files to be unlinked. Not explicitly closing the file would throw a permission denied warning while running tests. This is now fixed.

One of the tests uses a regex that checks for date and time in the log incorrectly. The regex wasn't accounting for when a log would be generated in a time zone that was X hours and 30 or 45 mins ahead of GMT. This is also been fixed.