improved mysql exception sorter

This commit is contained in:
wenshao
2014-12-07 19:17:28 +08:00
parent f17f6c976c
commit e0e851ac92
2 changed files with 7 additions and 1 deletions
@@ -39,4 +39,9 @@ public class MySqlExceptionSorterTest extends TestCase {
MySqlExceptionSorter sorter = new MySqlExceptionSorter();
Assert.assertFalse(sorter.isExceptionFatal(new SQLException("", "", -8000)));
}
public void test_true_3() throws Exception {
MySqlExceptionSorter sorter = new MySqlExceptionSorter();
Assert.assertTrue(sorter.isExceptionFatal(new com.mysql.jdbc.CommunicationsException(null, 0, 0, null)));
}
}