fix tests

release/4.3a0
Varun Agrawal 2024-10-15 23:56:52 -04:00
parent 5c0171b69c
commit 9931e29108
2 changed files with 2 additions and 2 deletions

View File

@ -70,7 +70,7 @@ TEST( PCGsolver, verySimpleLinearSystem) {
pcg->preconditioner = pcg->preconditioner =
std::make_shared<gtsam::BlockJacobiPreconditionerParameters>(); std::make_shared<gtsam::BlockJacobiPreconditionerParameters>();
// It takes more than 1000 iterations for this test // It takes more than 1000 iterations for this test
pcg->setMaxIterations(1500); pcg->maxIterations = 1500;
VectorValues deltaPCGJacobi = PCGSolver(*pcg).optimize(simpleGFG); VectorValues deltaPCGJacobi = PCGSolver(*pcg).optimize(simpleGFG);
EXPECT(assert_equal(exactSolution, deltaPCGJacobi, 1e-5)); EXPECT(assert_equal(exactSolution, deltaPCGJacobi, 1e-5));

View File

@ -48,7 +48,7 @@ static double error(const GaussianFactorGraph& fg, const VectorValues& x) {
TEST( SubgraphSolver, Parameters ) TEST( SubgraphSolver, Parameters )
{ {
LONGS_EQUAL(SubgraphSolverParameters::SILENT, kParameters.verbosity()); LONGS_EQUAL(SubgraphSolverParameters::SILENT, kParameters.verbosity());
LONGS_EQUAL(500, kParameters.maxIterations()); LONGS_EQUAL(500, kParameters.maxIterations);
} }
/* ************************************************************************* */ /* ************************************************************************* */