Ejemplo n.º 1
0
        public void TestConversion()
        {
            var native = new NATIVE_ENUMCOLUMNVALUE
            {
                cbData = 1,
                err = (int) JET_wrn.ColumnTruncated,
                itagSequence = 2,
                pvData = new IntPtr(3),
            };

            var managed = new JET_ENUMCOLUMNVALUE();
            managed.SetFromNativeEnumColumnValue(native);

            Assert.AreEqual(1, managed.cbData);
            Assert.AreEqual(JET_wrn.ColumnTruncated, managed.err);
            Assert.AreEqual(2, managed.itagSequence);
            Assert.AreEqual(new IntPtr(3), managed.pvData);
        }
Ejemplo n.º 2
0
 public void JetEnumcolumnvalueToString()
 {
     var value = new JET_ENUMCOLUMNVALUE { itagSequence = 11, cbData = 12 };
     Assert.AreEqual("JET_ENUMCOLUMNVALUE(itagSequence = 11, cbData = 12)", value.ToString());
 }