Skip to content

Commit

Permalink
Merge pull request #614 from biolink/kltm-patch-1
Browse files Browse the repository at this point in the history
Update qc.py
  • Loading branch information
kltm committed Feb 19, 2022
2 parents 3492474 + ffc8e49 commit bdd2e82
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ontobio/io/qc.py
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ def test(self, annotation: association.GoAssociation, config: assocparser.AssocP
class GoRule16(GoRule):

def __init__(self):
super().__init__("GORULE:0000016", "All IC annotations should include a GO ID in the \"With/From\" column", FailMode.HARD)
super().__init__("GORULE:0000016", "All IC annotations should include a GO ID in the \"With/From\" column", FailMode.SOFT)

def test(self, annotation: association.GoAssociation, config: assocparser.AssocParserConfig, group=None) -> TestResult:
evidence = str(annotation.evidence.type)
Expand Down
4 changes: 2 additions & 2 deletions tests/test_qc.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ def test_go_rule_16():
assoc = make_annotation(evidence="IC", withfrom="BLAH:12345").associations[0]

test_result = qc.GoRule16().test(assoc, all_rules_config())
assert test_result.result_type == qc.ResultType.ERROR
assert test_result.result_type == qc.ResultType.WARNING

# withfrom has GO term
assoc.evidence.with_support_from = association.ConjunctiveSet.str_to_conjunctions("GO:0023456")
Expand All @@ -240,7 +240,7 @@ def test_go_rule_16():
assoc.evidence.with_support_from = []

test_result = qc.GoRule16().test(assoc, all_rules_config())
assert test_result.result_type == qc.ResultType.ERROR
assert test_result.result_type == qc.ResultType.WARNING

# Not IC
assoc.evidence.type = Curie.from_str(iea_eco)
Expand Down

0 comments on commit bdd2e82

Please sign in to comment.