mirror of https://github.com/oliverbooth/X10D
27 lines
626 B
C#
27 lines
626 B
C#
|
namespace X10D.Tests
|
||
|
{
|
||
|
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||
|
|
||
|
/// <summary>
|
||
|
/// Tests for <see cref="BooleanExtensions"/>.
|
||
|
/// </summary>
|
||
|
[TestClass]
|
||
|
public class BooleanTests
|
||
|
{
|
||
|
/// <summary>
|
||
|
/// Tests for <see cref="BooleanExtensions.ToInt32"/>.
|
||
|
/// </summary>
|
||
|
[TestMethod]
|
||
|
public void ToInt32()
|
||
|
{
|
||
|
const bool a = true;
|
||
|
const bool b = false;
|
||
|
|
||
|
Assert.IsTrue(a);
|
||
|
Assert.IsFalse(b);
|
||
|
Assert.AreEqual(1, a.ToInt32());
|
||
|
Assert.AreEqual(0, b.ToInt32());
|
||
|
}
|
||
|
}
|
||
|
}
|