From 673413e7633ac15361d28247cff388e6e7d81c35 Mon Sep 17 00:00:00 2001 From: Leon Montag Date: Fri, 30 Dec 2022 22:52:02 +0100 Subject: [PATCH] Added assert to testRun --- src/test/java/game/runGameTest.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/test/java/game/runGameTest.java b/src/test/java/game/runGameTest.java index 05af9ca..0330d04 100644 --- a/src/test/java/game/runGameTest.java +++ b/src/test/java/game/runGameTest.java @@ -77,7 +77,13 @@ class runGameTest { "Antw. 5,Antw. 6,Antw. 7,Antw. 8"}; runGame game = new runGame(); game.run(0); - + //assert + String[] IsRight = {"Frage 1", "Antw. 1","Antw. 2","Antw. 3","Antw. 4",}; + assertEquals(IsRight[0], GameGui.QuestionLabel.getText()); + assertEquals(IsRight[1], GameGui.AnswersBtn1.getText()); + assertEquals(IsRight[2], GameGui.AnswersBtn2.getText()); + assertEquals(IsRight[3], GameGui.AnswersBtn3.getText()); + assertEquals(IsRight[4], GameGui.AnswersBtn4.getText()); }