PingPong extends PingPongTOP { public PingPong() { typedThis = this; } PingPong();   }
@Test public void testPingPong(){ PingPong pingpong = new PingPong(); assertTrue(String.format(message,"NoGame"),pingpong.currentState instanceof NoGameState); pingpong.startGame(); assertTrue(String.format(message,"Ping"), pingpong.currentState instanceof PingState); pingpong.returnBall(); assertTrue(String.format(message,"Pong"), pingpong.currentState instanceof PongState); pingpong.returnBall(); assertTrue(String.format(message,"Ping"), pingpong.currentState instanceof PingState); pingpong.startGame(); assertTrue(String.format(message,"Ping"), pingpong.currentState instanceof PingState); pingpong.stopGame(); assertTrue(String.format(message,"NoGame"), pingpong.currentState instanceof NoGameState); }