ShaderTests ClassDelta Engine Documentation
Inheritance Hierarchy

System Object
  DeltaEngine.Tests.Content ShaderTests

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

public class ShaderTests

The ShaderTests type exposes the following members.

Constructors

  NameDescription
Public methodShaderTests
Initializes a new instance of the ShaderTests class
Top
Methods

  NameDescription
Public methodCompareShaderCreationDatas
Public methodShadersAreEqualWhenTheFlagsAreTheSame
Top
Examples

[Test]
public void ShadersAreEqualWhenTheFlagsAreTheSame()
{
    Shader coloredShader = CreateShaderByFlags(ShaderFlags.Colored);
    Assert.AreEqual(coloredShader, CreateShaderByFlags(ShaderFlags.Colored));
    Assert.AreNotEqual(coloredShader, CreateShaderByFlags(ShaderFlags.Textured));
}
[Test]
public void CompareShaderCreationDatas()
{
    var data1 = new ShaderCreationData(ShaderFlags.Colored);
    var data2 = new ShaderCreationData(ShaderFlags.Textured);
    var data3 = new ShaderCreationData(ShaderFlags.Textured);
    Assert.IsFalse(data1.Equals(data2));
    Assert.IsTrue(data2.Equals(data3));
    Assert.AreNotEqual(data1, data2);
    Assert.AreEqual(data2, data3);
}
See Also