Example #1
0
        public SetWithDefault createSetWithDefaultValue()
        {
            SetWithDefault result = new SetWithDefault();

            result.Nodefault  = 0xAA;
            result.Nodefault2 = new TestPRN("aaaa");
            result.Default3   = "DDDdd"; // equals to the default value
            return(result);
        }
        public SetWithDefault createSet()
        {
            SetWithDefault result = new SetWithDefault();

            result.Nodefault  = (0xAA);
            result.Nodefault2 = (new TestPRN("aaaa"));
            result.Default3   = ("bbbb");
            return(result);
        }
Example #3
0
        public SetWithDefault createSet()
        {
            SetWithDefault result = new SetWithDefault();

            result.Nodefault  = 0xAA;
            result.Nodefault2 = new TestPRN("aaaa");
            result.Default3   = "bbbb"; // does not equal to the default value
            return(result);
        }
Example #4
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.AreEqual(val.Nodefault, coderTestUtils.createSet().Nodefault);
            Assert.AreEqual(val.Nodefault2.Value, coderTestUtils.createSet().Nodefault2.Value);
            Assert.AreEqual(val.Default3, coderTestUtils.createSet().Default3);
        }