コード例 #1
0
 public void Match_FailsWhenValueLengthIsLessThanMinLength()
 {
     MinLengthHttpRouteConstraint constraint = new MinLengthHttpRouteConstraint(3);
     bool match = TestValue(constraint, "12");
     Assert.False(match);
 }
コード例 #2
0
 public void Match_SucceedsWhenValueLengthIsGreaterThanMinLength()
 {
     MinLengthHttpRouteConstraint constraint = new MinLengthHttpRouteConstraint(3);
     bool match = TestValue(constraint, "1234");
     Assert.True(match);
 }