获取异常信息的方法 e.toString() e.getMessage() e.printStackTrace()
https://blog.csdn.net/yamadeee/article/details/82688506 public class TestException(){ @Test public void test(){ try{ throw new IllegalArgumentException("xxxxxx"); }catch(Exception e){ System.out.prin…