示例#1
0
        public void CtorWithPolicyCopiesProperties()
        {
            // Arrange
            var policy = new UserSecurityPolicy("A", "B", "C");

            // Act
            var copy = new UserSecurityPolicy(policy);

            // Assert
            Assert.Equal(policy.Name, copy.Name);
            Assert.Equal(policy.Subscription, copy.Subscription);
            Assert.Equal(policy.Value, copy.Value);
        }
示例#2
0
 public void EqualsReturnsFalseForPolicyNonMatches(UserSecurityPolicy first, UserSecurityPolicy second)
 {
     // Act & Assert
     Assert.False(first.Equals(second));
 }
示例#3
0
 public void EqualsReturnsTrueForPolicyMatches(UserSecurityPolicy first, UserSecurityPolicy second)
 {
     // Act & Assert
     Assert.True(first.Equals(second));
 }