def test_orientation_filled(testinp, results): dyncon = OSC.Orientation(h=testinp[0], p=testinp[1], r=testinp[2], reference=testinp[3]) assert dyncon.is_filled() == results
def test_orientation(testinp, results): dyncon = OSC.Orientation(h=testinp[0], p=testinp[1], r=testinp[2], reference=testinp[3]) print(dyncon.get_attributes()) assert len(dyncon.get_attributes()) == results
def test_relativeobjectposition(): pos = OSC.RelativeObjectPosition('Ego', 1, 2, 0) OSC.prettyprint(pos.get_element()) pos = OSC.RelativeObjectPosition('Target', 1, 2, 0, orientation=OSC.Orientation(h=0.2)) OSC.prettyprint(pos.get_element())
def test_orientation_failed(): with pytest.raises(ValueError): OSC.Orientation(reference='hej')