Fix several tests on Windows.