ButtonTests DefaultNames Method Delta Engine Documentation

Namespace: DeltaEngine.Scenes.Tests.Controls
Assembly: DeltaEngine.Scenes.Tests (in DeltaEngine.Scenes.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public void DefaultNames()
Examples

[Test, CloseAfterFirstFrame]
public void DefaultNames()
{
    var button2 = new Button(Center, "Click Me");
    Assert.IsTrue(button.Name.StartsWith("Button"));
    Assert.IsTrue(button2.Name.StartsWith("Button"));
    Assert.Greater(int.Parse(button2.Name.Replace("Button", "")),
        int.Parse(button.Name.Replace("Button", "")));
}
See Also