Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modified force field constraint tests to be more robust #503

Merged
merged 1 commit into from
May 6, 2015
Merged

Modified force field constraint tests to be more robust #503

merged 1 commit into from
May 6, 2015

Conversation

ptosco
Copy link
Contributor

@ptosco ptosco commented May 5, 2015

No description provided.

@@ -1439,7 +1440,7 @@ void testMMFFAllConstraints(){
dc = new ForceFields::MMFF::DistanceConstraintContrib(field, 1, 3, 2.0, 2.0, 1.0e5);
field->contribs().push_back(ForceFields::ContribPtr(dc));
field->minimize();
TEST_ASSERT(MolTransforms::getBondLength(mol->getConformer(), 1, 3) > 1.99);
TEST_ASSERT(RDKit::round(MolTransforms::getBondLength(mol->getConformer(), 1, 3)) == 2);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to go ahead and accept the PR, because this isn't a major thing, but the usual style for this kind of test is to use the feq() function instead of round()

greglandrum added a commit that referenced this pull request May 6, 2015
Modified force field constraint tests to be more robust
@greglandrum greglandrum merged commit 71d555f into rdkit:master May 6, 2015
@greglandrum greglandrum modified the milestone: 2015_09_1 Oct 21, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants