Skip to content

Commit 5244b48

Browse files
committed
No, really fix new tests in parallel
We should instead change the behavior of these functions in the out-of-mesh case, but that will wait on a later PR.
1 parent eb8ae09 commit 5244b48

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

tests/mesh/mesh_function.C

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -220,12 +220,12 @@ public:
220220

221221
mesh_function.gradient(p, 0.0, gradients);
222222

223-
CPPUNIT_ASSERT_EQUAL(std::size_t(2), gradients.size());
224-
225223
// Let's only test our evaluation where we know we can evaluate, in parallel
226224
if (!elem || elem->processor_id() != mesh.processor_id())
227225
return;
228226

227+
CPPUNIT_ASSERT_EQUAL(std::size_t(2), gradients.size());
228+
229229
LIBMESH_ASSERT_NUMBERS_EQUAL(8.0, gradients[0](0), TOLERANCE * TOLERANCE);
230230
LIBMESH_ASSERT_NUMBERS_EQUAL(80.0, gradients[0](1), TOLERANCE * TOLERANCE);
231231
if (LIBMESH_DIM > 2)
@@ -286,12 +286,12 @@ public:
286286

287287
mesh_function.hessian(p, 0.0, hessians);
288288

289-
CPPUNIT_ASSERT_EQUAL(std::size_t(2), hessians.size());
290-
291289
// Let's only test our evaluation where we know we can evaluate, in parallel
292290
if (!elem || elem->processor_id() != mesh.processor_id())
293291
return;
294292

293+
CPPUNIT_ASSERT_EQUAL(std::size_t(2), hessians.size());
294+
295295
LIBMESH_ASSERT_NUMBERS_EQUAL(15.0, hessians[0](0,0), tol);
296296
LIBMESH_ASSERT_NUMBERS_EQUAL(0.75, hessians[0](0,1), tol);
297297
LIBMESH_ASSERT_NUMBERS_EQUAL(0.75, hessians[0](1,0), tol);

0 commit comments

Comments
 (0)