Commit ee35c510 authored by James C Bowden's avatar James C Bowden
Browse files

re add try catch

parent e96b305d
No related merge requests found
Pipeline #76296 failed with stage
Showing with 5 additions and 1 deletion
+5 -1
......@@ -11,6 +11,7 @@ import java.io.FileNotFoundException;
import java.lang.reflect.Constructor;
import java.lang.reflect.Field;
import java.util.Map;
import java.util.NoSuchElementException;
import java.util.Random;
import java.util.Scanner;
......@@ -37,7 +38,10 @@ public class GameTraceTests {
)
public void testAdventureGame(Map<String, String> arguments, String expectedOutput, CaptureSystemOutput.OutputCapture capture)
throws FileNotFoundException {
runTestGame(arguments.get("stdin"));
try {
runTestGame(arguments.get("stdin"));
} catch (NoSuchElementException e) {
}
assertEquals(expectedOutput.replace("\r\n", "\n").strip(), capture.toString().replace("\r\n", "\n").strip());
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment