Skip to content

Commit

Permalink
STYLE: Do not Fill empty fixedParameters in Transform test
Browse files Browse the repository at this point in the history
This local `fixedParameters` is of type `OptimizerParameters<double>`. When it
is just default-constructed, it is empty. An attempt to `Fill` an empty
`OptimizerParameters` has no effect at all.
  • Loading branch information
N-Dekker committed Oct 24, 2024
1 parent 1e45e5a commit 30bbab2
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,7 @@ itkRigid3DPerspectiveTransformTest(int, char *[])
ITK_TEST_SET_GET_VALUE(centerOfRotation, transform->GetCenterOfRotation());

// This transform has no fixed parameters; empty method body; called for coverage purposes
typename TransformType::FixedParametersType::ValueType fixedParametersValues = 0;
typename TransformType::FixedParametersType fixedParameters;
fixedParameters.Fill(fixedParametersValues);
const typename TransformType::FixedParametersType fixedParameters{};
transform->SetFixedParameters(fixedParameters);
}

Expand Down

0 comments on commit 30bbab2

Please sign in to comment.