Skip to content

Commit

Permalink
Allow metadata to differ between SDF and PDB
Browse files Browse the repository at this point in the history
  • Loading branch information
Yoshanuikabundi committed Sep 22, 2022
1 parent f11e8d4 commit 91d231a
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions openff/toolkit/tests/test_molecule.py
Original file line number Diff line number Diff line change
Expand Up @@ -2139,9 +2139,14 @@ def test_matches_sdf(self, pdb_path, smiles, sdf_path):
# Not sure that the following are necessary given are_isomorphic,
# but keeping them from previous test implementations

# Check that the atom properties are identical
# Check that the atom properties are identical (except metadata)
for pdb_atom, sdf_atom in zip(pdb_mol.atoms, sdf_mol.atoms):
assert pdb_atom.to_dict() == sdf_atom.to_dict()
pdb_atom_dict = pdb_atom.to_dict()
del pdb_atom_dict["metadata"]

sdf_atom_dict = sdf_atom.to_dict()
del sdf_atom_dict["metadata"]
assert sdf_atom_dict == pdb_atom_dict

# Check that the bonds match, though possibly in a different order
sdf_bonds = {
Expand Down

0 comments on commit 91d231a

Please # to comment.