fixed #821 - test.assertRaises always PASS