Fix warnings on mcs solution

Fix all warnings in the mcs solution and treat warnings as errors on all projects except for the test project.