IndexTests ConvertingShortResultsInSameValueAsUShort Method Delta Engine Documentation

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

public void ConvertingShortResultsInSameValueAsUShort()
Examples

[Test]
public void ConvertingShortResultsInSameValueAsUShort()
{
    var indices = new List<int> { 4593, 41593, 3954593 };
    var shorts = indices.Select(index => (short)(index+1)).ToList();
    for (int num = 0; num < indices.Count; num++)
        Assert.AreEqual((ushort)indices[num]+1, (ushort)shorts[num]);
}
See Also