docker files fixes from liaqat
This commit is contained in:
24
src/Managing.Application.Tests/MathHelpersTests.cs
Normal file
24
src/Managing.Application.Tests/MathHelpersTests.cs
Normal file
@@ -0,0 +1,24 @@
|
||||
using Managing.Core;
|
||||
using Xunit;
|
||||
|
||||
namespace Managing.Application.Tests
|
||||
{
|
||||
public class MathHelpersTests
|
||||
{
|
||||
[Theory]
|
||||
[InlineData(0.00010, 4)]
|
||||
public void Should_Return_Correct_Precision(decimal n, int expectedValue)
|
||||
{
|
||||
var precision = MathHelpers.GetDecimalPlaces(n);
|
||||
Assert.Equal(expectedValue, precision);
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData("0.00010", 4)]
|
||||
public void Should_Return_Correct_PrecisionTest(string s, int expectedValue)
|
||||
{
|
||||
var precision = MathHelpers.GetDecimalPlaces(s);
|
||||
Assert.Equal(expectedValue, precision);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user