Testing with ErrorChecking in Main.cpp