示例#1
0
        public void EqualsAgainstNull()
        {
            // Arrange
            var key   = ParamValue.Param.bodyhash;
            var value = "test-hash";
            var param = new ParamValue(key, value);

            // Act
            var actual = param.Equals(null);

            // Assert
            Assert.IsFalse(actual);
        }
示例#2
0
        public void EqualsAgainstDifferentKey()
        {
            // Arrange
            var key    = ParamValue.Param.bodyhash;
            var value  = "test-hash";
            var param1 = new ParamValue(ParamValue.Param.token, value);
            var param2 = new ParamValue(key, value);

            // Act
            var actual = param2.Equals(param1);

            // Assert
            Assert.IsFalse(actual);
        }
示例#3
0
        public void EqualsEqualParamValue()
        {
            // Arrange
            var key    = ParamValue.Param.bodyhash;
            var value  = "test-hash";
            var param1 = new ParamValue(key, value);
            var param2 = new ParamValue(key, value);

            // Act
            var actual = param2.Equals(param1);

            // Assert
            Assert.IsTrue(actual);
        }
示例#4
0
        public void EqualsAgainstDifferentValue()
        {
            // Arrange
            var key    = ParamValue.Param.bodyhash;
            var value1 = "test-hash1";
            var value2 = "test-hash2";
            var param1 = new ParamValue(key, value1);
            var param2 = new ParamValue(key, value2);

            // Act
            var actual = param2.Equals(param1);

            // Assert
            Assert.IsFalse(actual);
        }