Fix broken unit tests on Windows