public void TestString() { var arbitrary = new StringElement(16); arbitrary.SetString(builder => builder.Append("Test")); var stream = new MemoryStream(); arbitrary.Serialize(stream); var deserialized = new StringElement(16); stream.Position = 0; deserialized.Deserialize(stream); Assert.AreEqual("Test", arbitrary.GetString().ToString()); Assert.AreEqual("Test", deserialized.GetString().ToString()); }