2 import pinocchio
as pin
5 @unittest.skipUnless(pin.WITH_URDFDOM,
"Needs URDFDOM")
9 self.
current_file = os.path.dirname(str(os.path.abspath(__file__)))
14 model = pin.buildModelFromUrdf(self.
model_path)
15 model_ff = pin.buildModelFromUrdf(self.
model_path, pin.JointModelFreeFlyer())
19 pin.buildModelFromUrdf(self.
model_path, pin.JointModelFreeFlyer(), model)
20 model_ref = pin.buildModelFromUrdf(self.
model_path, pin.JointModelFreeFlyer())
24 file_content = model.read()
26 model_ref = pin.buildModelFromUrdf(self.
model_path, pin.JointModelFreeFlyer())
27 model = pin.buildModelFromXML(file_content,pin.JointModelFreeFlyer())
29 self.assertEqual(model,model_ref)
31 model_self = pin.Model()
32 pin.buildModelFromXML(file_content,pin.JointModelFreeFlyer(),model_self)
33 self.assertEqual(model_self,model_ref)
35 if __name__ ==
'__main__':