Skip to content

Commit 253b662

Browse files
committed
Fix bug with sibling check
Previously only checked siblings in one directions, now the test checks in both directions
1 parent a48a1f4 commit 253b662

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

testing/databaseTest.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,8 @@ def kinetics__checkSiblingsForParents(self, family_name):
295295
if child1 is child2: continue
296296
nose.tools.assert_false(family.matchNodeToChild(child1, child2),
297297
"In {0} group, node {1} is written as a sibling of {2}, when it is actually a parent.".format(group_name, child1, child2))
298-
298+
nose.tools.assert_false(family.matchNodeToChild(child2, child1),
299+
"In {0} group, node {1} is written as a sibling of {2}, when it is actually a parent.".format(group_name, child2, child1))
299300

300301
def kinetics_checkAdjlistsNonidentical(self, database):
301302
"""
@@ -406,6 +407,7 @@ def general_checkSiblingsForParents(self, group_name, group):
406407
if child1 is child2: continue
407408
nose.tools.assert_false(group.matchNodeToChild(child1, child2),
408409
"In {0} group, node {1} is written as a sibling of {2}, when it is actually a parent.".format(group_name, child1, child2))
409-
410+
nose.tools.assert_false(group.matchNodeToChild(child2, child1),
411+
"In {0} group, node {1} is written as a sibling of {2}, when it is actually a parent.".format(group_name, child2, child1))
410412
if __name__ == '__main__':
411413
nose.run(argv=[__file__, '-v', '--nologcapture'], defaultTest=__name__)

0 commit comments

Comments
 (0)