add exception handler
improve error log
improve exception test output
remove __doctest attribute & use error.name to detect error type.
Merge pull request #2 from azu/ticket/id/2

Exception tests support