diff --git a/JavaGamelauncher/src/main/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/MouseGame.java b/JavaGamelauncher/src/main/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/MouseGame.java index 177b942..83ad7f3 100644 --- a/JavaGamelauncher/src/main/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/MouseGame.java +++ b/JavaGamelauncher/src/main/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/MouseGame.java @@ -121,10 +121,15 @@ public class MouseGame extends JFrame { - }//end standardkonstruktor + public int getResetX() { + return resetX; + } + + + private void reset(JPanel panel) { panel.addMouseListener(new MouseAdapter() { @Override diff --git a/JavaGamelauncher/src/test/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/MouseGameTest.java b/JavaGamelauncher/src/test/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/MouseGameTest.java index 759c21d..5e0c3d9 100644 --- a/JavaGamelauncher/src/test/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/MouseGameTest.java +++ b/JavaGamelauncher/src/test/java/de/hs_fulda/gruppenprojekt/JavaGamelauncher/MouseGameTest.java @@ -38,4 +38,13 @@ public class MouseGameTest { assertTrue(mg.getTitle()=="Mouse Game"); } + @Test + public void resetXPruefen() throws AWTException { + //Given + MouseGame mg = new MouseGame(); + + //Then + assertTrue(mg.getResetX()==200); + } + }