unittest of exceptions