Fix Visual Studio warnings

Still unable to build tests on Windows with the DLL export
refactor.