Add test for constructor exception.