Пример #1
0
        public void testEncodeLongTag2()
        {
            IEncoder encoder = newEncoder();

            Assert.NotNull(encoder);
            printEncoded("EncodeTestLongTag2: ", encoder, coderTestUtils.createTestLongTag2());
            checkEncoded(encoder, coderTestUtils.createTestLongTag2(), coderTestUtils.createTestLongTag2Bytes());
        }
Пример #2
0
        public void testDecodeLongTag2()
        {
            IDecoder decoder = newDecoder();

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

            Assert.True(val.isTestaSelected());
            Assert.Equals(val.Testa.Testb, coderTestUtils.createTestLongTag2().Testa.Testb);
        }