File tree Expand file tree Collapse file tree 1 file changed +2
-8
lines changed
src/test/java/com/thealgorithms/stacks Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -33,18 +33,12 @@ void testExtraOperands() {
3333 @ Test
3434 @ DisplayName ("Should throw ArithmeticException for division by zero" )
3535 void testDivisionByZero () {
36- assertThrows (ArithmeticException .class , () -> PostfixEvaluator .evaluatePostfix ("5 0 /" ));
36+ assertThrows (ArithmeticException .class , () -> PostfixEvaluator .evaluatePostfix ("1 0 /" ));
3737 }
3838
3939 @ Test
4040 @ DisplayName ("Should throw IllegalArgumentException for invalid characters" )
4141 void testInvalidToken () {
42- assertThrows (IllegalArgumentException .class , () -> PostfixEvaluator .evaluatePostfix ("5 a +" ));
43- }
44-
45- @ Test
46- @ DisplayName ("Should throw EmptyStackException for empty input" )
47- void testEmptyInput () {
48- assertThrows (EmptyStackException .class , () -> PostfixEvaluator .evaluatePostfix ("" ));
42+ assertThrows (IllegalArgumentException .class , () -> PostfixEvaluator .evaluatePostfix ("1 a +" ));
4943 }
5044}
You can’t perform that action at this time.
0 commit comments