Skip to content

Instantly share code, notes, and snippets.

@sakapon

sakapon/BitArrayTest.cs

Last active Sep 2, 2020
Embed
What would you like to do?
OperatorsSample/BitArrayTest.Parse
[TestMethod]
public void Parse()
{
BitArray b1 = 65535; // implicit conversion
Assert.AreEqual("65535", b1.ToString());
var b2 = BitArray.Parse(b1.ToString());
Assert.AreEqual(65535, (int)b2); // explicit conversion
Assert.AreEqual(b1, b2);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment