diff --git a/junit-exception/src/test/java/com/hmkcode/AppTest.java b/junit-exception/src/test/java/com/hmkcode/AppTest.java index fb4fa89e..4d9b1a6b 100644 --- a/junit-exception/src/test/java/com/hmkcode/AppTest.java +++ b/junit-exception/src/test/java/com/hmkcode/AppTest.java @@ -25,10 +25,10 @@ public void testNull() { str.toUpperCase(); } - // ( 2 ) Test by tyr/catch (test exception message) + // ( 2 ) Test by try/catch (test exception message) @Test public void testExceptionMessage(){ - try{ + try { new LinkedList().get(0); //if no exception thrown the test will fail with the below message. @@ -42,7 +42,7 @@ public void testExceptionMessage(){ } - //( 3 ) Test by @Rule & ExpectedException.expect() | ExpectedException.expectMessage() + // ( 3 ) Test by @Rule & ExpectedException.expect() | ExpectedException.expectMessage() @Rule public ExpectedException thrown = ExpectedException.none();