DropdownListTests IfValuesAreChangedAndNoLongerContainSelectedValueItRevertsToFirstValue 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 IfValuesAreChangedAndNoLongerContainSelectedValueItRevertsToFirstValue()
Examples

[Test, CloseAfterFirstFrame]
public void IfValuesAreChangedAndNoLongerContainSelectedValueItRevertsToFirstValue()
{
    var newValues = new List<object> { 1, 2 };
    dropdownList.Values = newValues;
    Assert.AreEqual(1, dropdownList.SelectedValue);
    Assert.AreEqual(2, dropdownList.SelectBox.texts.Count);
}
See Also