예제 #1
0
        public void CopyMatType()
        {
            Int32 anID1 = 1;
            string aName1 = "Familia de material uno";
            string aMemo1 = "Esto es un ejemplo de la familia de material 1.";
            Int32 anID2 = 0;
            string aName2 = null;
            string aMemo2 = null;

            MaterialType aMatType1 = new MaterialType(anID1, aName1, aMemo1);
            MaterialType aMatType2 = new MaterialType();

            Assert.AreEqual(anID1, aMatType1.MatTypeID);
            Assert.AreEqual(aName1, aMatType1.Name);
            Assert.AreEqual(aMemo1, aMatType1.Memo);
            Assert.AreEqual(anID2, aMatType2.MatTypeID);
            Assert.AreEqual(aName2, aMatType2.Name);
            Assert.AreEqual(aMemo2, aMatType2.Memo);

            aMatType2.CopyMatType(aMatType1);

            Assert.AreEqual(anID1, aMatType2.MatTypeID);
            Assert.AreEqual(aName1, aMatType2.Name);
            Assert.AreEqual(aMemo1, aMatType2.Memo);
        }
예제 #2
0
        public void TestMatTypeConstructorWithData()
        {
            Int32 anID = 7;
            string aName = "Una familia de material";
            string aMemo = "Esto es un ejemplo de una familia de material.";

            MaterialType aMatType = new MaterialType(anID,aName,aMemo);

            Assert.AreEqual(anID, aMatType.MatTypeID);
            Assert.AreEqual(aName, aMatType.Name);
            Assert.AreEqual(aMemo, aMatType.Memo);
        }
예제 #3
0
        public void ClearMatType()
        {
            Int32 anID = 7;
            string aName = "Una familia de material";
            string aMemo = "Esto es un ejemplo de una familia de material.";

            MaterialType aMatType = new MaterialType(anID, aName, aMemo);

            Assert.AreEqual(anID, aMatType.MatTypeID);
            Assert.AreEqual(aName, aMatType.Name);
            Assert.AreEqual(aMemo, aMatType.Memo);

            aMatType.ClearMatType();
            MaterialType aMatTypeEmpty = new MaterialType();

            Assert.AreEqual(aMatTypeEmpty.MatTypeID, aMatType.MatTypeID);
            Assert.AreEqual(aMatTypeEmpty.Name, aMatType.Name);
            Assert.AreEqual(aMatTypeEmpty.Memo, aMatType.Memo);
        }
예제 #4
0
 public void CopyMatType(MaterialType aMatType1)
 {
     this.MatTypeID = aMatType1.MatTypeID;
     this.Name      = aMatType1.Name;
     this.Memo      = aMatType1.Memo;
 }
예제 #5
0
        public void TestMatTypeConstructorWithoutData()
        {
            Int32 anID = 0;
            string aName = null;
            string aMemo = null;

            MaterialType aMatType = new MaterialType();

            Assert.AreEqual(anID, aMatType.MatTypeID);
            Assert.AreEqual(aName, aMatType.Name);
            Assert.AreEqual(aMemo, aMatType.Memo);
        }
예제 #6
0
 public void CopyMatType(MaterialType aMatType1)
 {
     this.MatTypeID = aMatType1.MatTypeID;
     this.Name = aMatType1.Name;
     this.Memo = aMatType1.Memo;
 }