Add separate go file for windows and adapt tests