Пример #1
0
        public void UniqueIDDifferent_EmptyAssigns_IsEqual()
        {
            //---------------Set up test pack-------------------
            var uniqueId  = Guid.NewGuid().ToString();
            var activity  = new DsfCalculateActivity();
            var activity1 = new DsfCalculateActivity();

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

            //---------------Test Result -----------------------
            Assert.IsFalse(@equals);
        }
Пример #2
0
        public void Equals_Given_Different_Object_Is_Not_Equal()
        {
            //---------------Set up test pack-------------------
            var uniqueId = Guid.NewGuid().ToString();
            var activity = new DsfCalculateActivity()
            {
                UniqueID = uniqueId, DisplayName = "A"
            };
            var activity1 = new DsfCalculateActivity()
            {
                UniqueID = uniqueId, DisplayName = "ass"
            };

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

            //---------------Test Result -----------------------
            Assert.IsFalse(@equals);
        }
Пример #3
0
        public void Result_Different_Object_Is_Not_Equal_CaseSensitive()
        {
            //---------------Set up test pack-------------------
            var uniqueId = Guid.NewGuid().ToString();
            var activity = new DsfCalculateActivity()
            {
                UniqueID = uniqueId, Result = "AAA"
            };
            var activity1 = new DsfCalculateActivity()
            {
                UniqueID = uniqueId, Result = "aaa"
            };

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

            //---------------Test Result -----------------------
            Assert.IsFalse(@equals);
        }
Пример #4
0
        public void Result_Same_Object_IsEqual()
        {
            //---------------Set up test pack-------------------
            var uniqueId = Guid.NewGuid().ToString();
            var activity = new DsfCalculateActivity()
            {
                UniqueID = uniqueId, Result = "a"
            };
            var activity1 = new DsfCalculateActivity()
            {
                UniqueID = uniqueId, Result = "a"
            };

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

            //---------------Test Result -----------------------
            Assert.IsTrue(@equals);
        }