예제 #1
0
        public void Equals_Second_Null_Returns_False()
        {
            var options1 = new SessionAffinityOptions
            {
                Enabled       = true,
                FailurePolicy = "policy1",
                Mode          = "mode1"
            };

            var equals = options1.Equals(null);

            Assert.False(equals);
        }
예제 #2
0
        public void Equals_Different_Value_Returns_False()
        {
            var options1 = new SessionAffinityOptions
            {
                Enabled       = true,
                FailurePolicy = "policy1",
                Mode          = "mode1"
            };

            var options2 = new SessionAffinityOptions
            {
                Enabled       = false,
                FailurePolicy = "policy2",
                Mode          = "mode2"
            };

            var equals = options1.Equals(options2);

            Assert.False(equals);
        }
예제 #3
0
        public void Equals_Same_Value_Returns_True()
        {
            var options1 = new SessionAffinityOptions
            {
                Enabled       = true,
                FailurePolicy = "policy1",
                Mode          = "mode1"
            };

            var options2 = new SessionAffinityOptions
            {
                Enabled       = true,
                FailurePolicy = "policy1",
                Mode          = "mode1"
            };

            var equals = options1.Equals(options2);

            Assert.True(equals);
        }