Added basic test for exception handling.