Skip to content

Commit

Permalink
Comparison value culture test
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremySkinner committed Sep 21, 2015
1 parent f0bd17b commit e03b0f3
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -122,12 +122,11 @@ public void Validates_with_nullable_when_property_not_null() {
[Fact]
public void Should_localize_value() {
using (new CultureScope("fr-fr")) {
Console.WriteLine(1.2M.ToString(CultureInfo.CurrentCulture));
var orderValidator = new InlineValidator<Order>();
orderValidator.RuleFor(x => x.Amount).GreaterThanOrEqualTo(1.2M).WithMessage("{ComparisonValue}");
var result = orderValidator.Validate(new Order());
var msg = result.Errors[0].ErrorMessage;
Console.WriteLine(msg);
msg.ShouldEqual("1,2");
}
}

Expand Down

0 comments on commit e03b0f3

Please sign in to comment.