GameTests KillingAllBricksShouldAdvanceToNextLevel Method Delta Engine Documentation

Namespace: Breakout.Tests
Assembly: Breakout.Tests (in Breakout.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public void KillingAllBricksShouldAdvanceToNextLevel()
Examples

[Test, CloseAfterFirstFrame]
public void KillingAllBricksShouldAdvanceToNextLevel()
{
    bool isGameOver = false;
    var level = Resolve<Level>();
    var score = Resolve<Score>();
    Score remScore = score;
    remScore.GameOver += () => isGameOver = true;
    Assert.AreEqual(1, score.Level);
    DisposeAllBricks(level);
    Assert.AreEqual(0, level.BricksLeft);
    Assert.AreEqual(1, remScore.Level);
    Assert.IsFalse(isGameOver);
}
See Also