diff --git a/modules/io/tests/test_io_omf.py b/modules/io/tests/test_io_omf.py index c691fd2ecce51ad22850e2b4dad931bc8f8c3583..0c618b015683e8407ab443d75e5a335f6fa5749a 100644 --- a/modules/io/tests/test_io_omf.py +++ b/modules/io/tests/test_io_omf.py @@ -193,6 +193,15 @@ class TestOMF(unittest.TestCase): self.assertTrue(len(omf_infer_pep_bonds_bytes) < len(omf_bytes)) self.assertTrue(compare_ent(self.ent, loaded_ent)) + def test_lower_precition(self): + omf = io.OMF.FromEntity(self.ent, max_error=0.5) + omf_bytes = omf.ToBytes() + loaded_omf = io.OMF.FromBytes(omf_bytes) + loaded_ent = loaded_omf.GetAU() + self.assertFalse(compare_ent(self.ent, loaded_ent)) + self.assertTrue(compare_ent(self.ent, loaded_ent, at_dist_thresh=0.5)) + + if __name__== '__main__': from ost import testutils if testutils.DefaultCompoundLibIsSet():