Skip to content

Commit

Permalink
Improve test coverage for broken IC
Browse files Browse the repository at this point in the history
  • Loading branch information
leeping committed Sep 11, 2023
1 parent 3e5c225 commit 24f9cbf
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,5 @@ exclude_lines =
main()
engine_str == 'gmx'
if False
if self.viz_rotations
if self.ForceRebuild:
17 changes: 17 additions & 0 deletions geometric/tests/test_openmm.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,23 @@ def test_dlc_openmm_water3(localizer):
# Check that the geometry matches the reference to within 0.03 RMS 0.05 max displacement
assert ((rmsd < 0.03 and maxd < 0.05) or (rmsd2 < 0.03 and maxd2 < 0.05))

@addons.using_openmm
def test_dlc_openmm_water12(localizer):
"""
Optimize the geometry of twelve water molecules using DLC.
The coordinate system is expected to break down and the optimizer should skip the optimization step
after rebuilding the coordinate system.
"""
progress = geometric.optimize.run_optimizer(engine='openmm', pdb=os.path.join(datad,'water12.pdb'),
coordsys='dlc', input='tip3p.xml', maxiter=20, converge=['maxiter'])

have_skip_step = False
for line in open('tip3p.log').readlines():
if 'Skipping optimization step' in line:
have_skip_step = True
assert have_skip_step


@addons.using_openmm
def test_tric_openmm_water6(localizer):
"""
Expand Down

0 comments on commit 24f9cbf

Please sign in to comment.