コード例 #1
0
        public void DsfDropBoxDeleteActivity_Equals_IsEqual_ExpectTrue()
        {
            //-----------------------Arrange----------------------------
            var dsfDropBoxDeleteAcivtity = new DsfDropBoxDeleteActivity();

            //-----------------------Act--------------------------------
            //-----------------------Assert-----------------------------
            Assert.IsTrue(dsfDropBoxDeleteAcivtity.Equals(dsfDropBoxDeleteAcivtity));
        }
コード例 #2
0
        public void DropBoxSource_Same_Object_Is_Equal()
        {
            //---------------Set up test pack-------------------
            var uniqueId = Guid.NewGuid().ToString();
            var dropBoxDeleteActivity = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId, Result = "A"
            };
            var dropBoxDeleteActivity1 = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId, Result = "A"
            };

            //---------------Assert Precondition----------------
            Assert.IsTrue(dropBoxDeleteActivity.Equals(dropBoxDeleteActivity1));
            //---------------Execute Test ----------------------
            dropBoxDeleteActivity.SelectedSource  = new DropBoxSource();
            dropBoxDeleteActivity1.SelectedSource = new DropBoxSource();
            var @equals = dropBoxDeleteActivity.Equals(dropBoxDeleteActivity1);

            //---------------Test Result -----------------------
            Assert.IsTrue(equals);
        }
コード例 #3
0
        public void DsfDropBoxDeleteActivity_Equals_Given_Same_Object_IsEqual()
        {
            //---------------Set up test pack-------------------
            var uniqueId    = Guid.NewGuid().ToString();
            var multiAssign = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId, DisplayName = "a"
            };
            var multiAssign1 = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId, DisplayName = "a"
            };

            //---------------Assert Precondition----------------
            Assert.IsNotNull(multiAssign);
            //---------------Execute Test ----------------------
            var @equals = multiAssign.Equals(multiAssign1);

            //---------------Test Result -----------------------
            Assert.IsTrue(equals);
        }
コード例 #4
0
        public void DsfDropBoxDeleteActivity_UniqueID_Different_Object_Is_Not_Equal()
        {
            //---------------Set up test pack-------------------
            var uniqueId    = Guid.NewGuid().ToString();
            var multiAssign = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId
            };
            var multiAssign1 = new DsfDropBoxDeleteActivity {
                UniqueID = Guid.NewGuid().ToString()
            };

            //---------------Assert Precondition----------------
            Assert.IsNotNull(multiAssign);
            //---------------Execute Test ----------------------
            var @equals = multiAssign.Equals(multiAssign1);

            //---------------Test Result -----------------------
            Assert.IsFalse(equals);
        }
コード例 #5
0
        public void DsfDropBoxDeleteActivity_UniqueIDEquals_EmptyDropBoxDeleteActivities_IsEqual()
        {
            //---------------Set up test pack-------------------
            var uniqueId    = Guid.NewGuid().ToString();
            var multiAssign = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId
            };
            var multiAssign1 = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId
            };

            //---------------Assert Precondition----------------
            Assert.IsNotNull(multiAssign);
            //---------------Execute Test ----------------------
            var @equals = multiAssign.Equals(multiAssign1);

            //---------------Test Result -----------------------
            Assert.IsTrue(equals);
        }
コード例 #6
0
        public void DsfDropBoxDeleteActivity_DeletePath_Different_Object_Is_Not_Equal_CaseSensitive()
        {
            //---------------Set up test pack-------------------
            var uniqueId    = Guid.NewGuid().ToString();
            var multiAssign = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId, DeletePath = "AAA"
            };
            var multiAssign1 = new DsfDropBoxDeleteActivity {
                UniqueID = uniqueId, DeletePath = "aaa"
            };

            //---------------Assert DsfDropBoxDeleteActivity----------------
            Assert.IsNotNull(multiAssign);
            //---------------Execute Test ----------------------
            var @equals = multiAssign.Equals(multiAssign1);

            //---------------Test Result -----------------------
            Assert.IsFalse(equals);
        }