Skip to content

Commit 9c1d0c9

Browse files
committed
[Sofa.Core.tests] Add a test for the BaseData.linkpath property
1 parent 292ccec commit 9c1d0c9

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

bindings/Sofa/tests/Core/BaseData.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -292,6 +292,11 @@ def t(c):
292292
self.assertEqual(wa[2, 2], 8.0)
293293
numpy.testing.assert_array_equal(wa, v*4.0)
294294

295+
def test_linkpath(self):
296+
n = create_scene("rootNode")
297+
m = n. addObject("MechanicalObject", name="dofs")
298+
self.assertEqual(m.position.linkpath, "@/dofs.position")
299+
295300
def test_set_value_from_string(self):
296301
n = create_scene("rootNode")
297302
n.gravity.value = [1.0,2.0,3.0]

0 commit comments

Comments
 (0)