Skip to content

Commit

Permalink
Fix culture dependency in ParseDecimalWithFallbackOnOverflow_Overflow…
Browse files Browse the repository at this point in the history
…s_ReturnsFallback test
  • Loading branch information
dldl-cmd committed Dec 4, 2023
1 parent d1cf89f commit 8a40801
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license.

using System.Globalization;
using Microsoft.OpenApi.Readers.ParseNodes;
using Xunit;

Expand All @@ -18,7 +19,7 @@ public void ParseDecimalWithFallbackOnOverflow_ReturnsParsedValue()
[Fact]
public void ParseDecimalWithFallbackOnOverflow_Overflows_ReturnsFallback()
{
Assert.Equal(10, ParserHelper.ParseDecimalWithFallbackOnOverflow(double.MaxValue.ToString(), 10));
Assert.Equal(10, ParserHelper.ParseDecimalWithFallbackOnOverflow(double.MaxValue.ToString(CultureInfo.InvariantCulture), 10));
}
}
}

0 comments on commit 8a40801

Please sign in to comment.