From 3bd863bfa2d7e7cc18d3ef66e15943faf95d0b38 Mon Sep 17 00:00:00 2001 From: Han Wang Date: Mon, 15 Mar 2021 09:31:30 +0800 Subject: [PATCH] fix bug in lib UT --- source/lib/tests/test_ewald.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/lib/tests/test_ewald.cc b/source/lib/tests/test_ewald.cc index 441e44f782..44cb758273 100644 --- a/source/lib/tests/test_ewald.cc +++ b/source/lib/tests/test_ewald.cc @@ -38,9 +38,9 @@ TEST_F(TestEwald, cpu) { double ener; std::vector force, virial; - SimulationRegion region; - region.reinitBox(&boxt[0]); - EwaldReciprocal(ener, force, virial, coord, charge, region, eparam); + Region region; + init_region_cpu(region, &boxt[0]); + ewald_recp(ener, force, virial, coord, charge, region, eparam); EXPECT_LT(fabs(ener - expected_e), 1e-10); for(int ii = 0; ii < force.size(); ++ii){ EXPECT_LT(fabs(force[ii] - expected_f[ii]), 1e-10);