Esempio n. 1
0
        public virtual void testEncodeSet()
        {
            IEncoder encoder = newEncoder();

            Assert.NotNull(encoder);
            printEncoded("Set test", encoder, coderTestUtils.createSet());
            checkEncoded(encoder, coderTestUtils.createSet(), coderTestUtils.createSetBytes());
        }
Esempio n. 2
0
        public virtual void testDecodeSet()
        {
            IDecoder decoder = newDecoder();

            System.IO.MemoryStream stream =
                new System.IO.MemoryStream(coderTestUtils.createSetBytes());
            SetWithDefault val = decoder.decode <SetWithDefault>(stream);

            Assert.Equals(val.Nodefault, coderTestUtils.createSet().Nodefault);
            Assert.Equals(val.Nodefault2.Value, coderTestUtils.createSet().Nodefault2.Value);
            Assert.Equals(val.Default3, coderTestUtils.createSet().Default3);
        }