예제 #1
0
        public void TestingColor(Color init)
        {
            ResetBois();

            PrimitiveWriter.WriteValue(Writer, init);
            ResetStream();

            var final = PrimitiveReader.ReadColor(Reader);

            Assert.True(init.ToArgb() == final.ToArgb(), $"Color value are not same, expected: {init.ToArgb()}, actual: {final.ToArgb()}");

            // saving name and compare against it is pointless
            //final.Should().BeEquivalentTo(init, because: "The colors name are not same");
        }