def test_unknown_joint(self): with open('tests/example_files/test_mocapbank.bvh') as f: mocap = Bvh(f.read()) with self.assertRaises(LookupError): mocap.joint_offset('FooBar')
def test_joint_offset(self): with open('tests/example_files/test_mocapbank.bvh') as f: mocap = Bvh(f.read()) self.assertEqual(mocap.joint_offset('RightElbow'), (-2.6865, -25.0857, 1.2959))