|
|
@ -106,4 +106,22 @@ class VisualizerPlainTextUltraTest { |
|
|
|
// assert |
|
|
|
assertThat(result).endsWith(expectedEnd); |
|
|
|
} |
|
|
|
|
|
|
|
@Test |
|
|
|
void VisualizerPlainTextUtlra_score_isVisualized() { |
|
|
|
// arrange |
|
|
|
|
|
|
|
GameManager gameManager = new GameManager(); |
|
|
|
VisualizerPlainTextUltra vptu = new VisualizerPlainTextUltra(gameManager); |
|
|
|
vptu.showScore = true; |
|
|
|
|
|
|
|
gameManager.score = 100; |
|
|
|
|
|
|
|
// act |
|
|
|
vptu.Update(); |
|
|
|
String result = (String)vptu.GetOutput(); |
|
|
|
|
|
|
|
// assert |
|
|
|
assertThat(result).startsWith("\nSCORE: 100"); |
|
|
|
} |
|
|
|
} |