Force crack calculator was fixed
This commit is contained in:
@@ -7,15 +7,14 @@ namespace StructureHelperTests.UnitTests.Calcuators
|
||||
{
|
||||
[TestCase(0d, 1d, 0.5d, 0.5d)]
|
||||
[TestCase(0d, 10d, 5d, 5d)]
|
||||
public void Run_ShouldPass_Valid(double startValue, double EndValue, double predicateValue, double expectedValue)
|
||||
public void Run_ShouldPass_Valid(double startValue, double endValue, double predicateValue, double expectedValue)
|
||||
{
|
||||
//Arrange
|
||||
var calculator = new FindParameterCalculator()
|
||||
{
|
||||
StartValue = startValue,
|
||||
EndValue = EndValue,
|
||||
Predicate = x => x > predicateValue
|
||||
};
|
||||
var calculator = new FindParameterCalculator();
|
||||
calculator.InputData.StartValue = startValue;
|
||||
calculator.InputData.EndValue = endValue; ;
|
||||
calculator.InputData.Predicate = x => x > predicateValue;
|
||||
|
||||
//Act
|
||||
calculator.Run();
|
||||
var result = calculator.Result as FindParameterResult;
|
||||
@@ -26,15 +25,13 @@ namespace StructureHelperTests.UnitTests.Calcuators
|
||||
}
|
||||
[TestCase(0d, 1d, 5d, 5d, false)]
|
||||
[TestCase(0d, 10d, 15d, 15d, false)]
|
||||
public void Run_ShouldPass_NotValid(double startValue, double EndValue, double predicateValue, double expectedValue, bool isValid)
|
||||
public void Run_ShouldPass_NotValid(double startValue, double endValue, double predicateValue, double expectedValue, bool isValid)
|
||||
{
|
||||
//Arrange
|
||||
var calculator = new FindParameterCalculator()
|
||||
{
|
||||
StartValue = startValue,
|
||||
EndValue = EndValue,
|
||||
Predicate = x => x > predicateValue
|
||||
};
|
||||
var calculator = new FindParameterCalculator();
|
||||
calculator.InputData.StartValue = startValue;
|
||||
calculator.InputData.EndValue = endValue; ;
|
||||
calculator.InputData.Predicate = x => x > predicateValue;
|
||||
//Act
|
||||
calculator.Run();
|
||||
var result = calculator.Result as FindParameterResult;
|
||||
|
||||
Reference in New Issue
Block a user