示例#1
0
        public void SecondaryObject_Id()
        {
            // This test verifies the Id auto-property works.
            // Note: this test is useless except for code coverage since we are testing that an auto-property works.
            Guid value           = Guid.NewGuid();
            var  secondaryObject = new SecondaryObject(value);

            Assert.AreEqual(value, secondaryObject.Id);
        }
示例#2
0
        public void SecondaryObject_PrimaryObject()
        {
            // This test verifies the PrimaryObject auto-property works.
            // Note: this test is useless except for code coverage since we are testing that an auto-property works.
            PrimaryObject value           = new PrimaryObject();
            var           secondaryObject = new SecondaryObject();

            secondaryObject.PrimaryObject = value;
            Assert.AreEqual(value, secondaryObject.PrimaryObject);
        }
示例#3
0
        public void SecondaryObject_Name()
        {
            // This test verifies the Name auto-property works.
            // Note: this test is useless except for code coverage since we are testing that an auto-property works.
            string value           = "test";
            var    secondaryObject = new SecondaryObject();

            secondaryObject.Name = value;
            Assert.AreEqual(value, secondaryObject.Name);
        }
示例#4
0
        public void SecondaryObject_Description()
        {
            // This test verifies the Description auto-property works.
            // Note: this test is useless except for code coverage since we are testing that an auto-property works.
            string value           = "test";
            var    secondaryObject = new SecondaryObject(Guid.NewGuid());

            secondaryObject.Description = value;
            Assert.AreEqual(value, secondaryObject.Description);
        }
示例#5
0
        public void PrimaryObject_SecondaryObjects()
        {
            // This test verifies the SecondaryObjects auto-property works.
            // Note: this test is useless except for code coverage since we are testing that an auto-property works.
            IEnumerable <SecondaryObject> value = new SecondaryObject[0];
            var primaryObject = new PrimaryObject();

            primaryObject.SecondaryObjects = value;
            Assert.AreEqual(value, primaryObject.SecondaryObjects);
        }
示例#6
0
 public void SecondaryObject_Constructor()
 {
     // This test verifies that the default constructor works.
     // Note: this test is useless except for code coverage since we are testing the default constructor with no custom logic.
     var secondaryObject = new SecondaryObject();
 }
示例#7
0
 public void SecondaryObject_Constructor_Valid()
 {
     // This test verifies that the object can be constructed successfully
     var secondaryObject = new SecondaryObject(Guid.NewGuid());
 }
示例#8
0
 public void SecondaryObject_Constructor_Id_Empty()
 {
     // This test verifies that the object's constructor will not accept null dependencies
     var secondaryObject = new SecondaryObject(Guid.Empty);
 }