Made error msg explicit and cleaned up some tsts.