File tree 2 files changed +4
-4
lines changed
2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -77,10 +77,10 @@ def __bool__(self):
77
77
class Negate (AsiExpr ):
78
78
"""Unary negation of boolean child"""
79
79
def __call__ (self , mutations ):
80
- child = self .children [0 ](mutations )
81
- if child is None :
80
+ child_score = self .children [0 ](mutations )
81
+ if child_score is None :
82
82
return Score (True , []) # TODO: propagate negative residues
83
- return Score (not child .score , child .residues )
83
+ return Score (not child_score .score , child_score .residues )
84
84
85
85
86
86
class AndExpr (AsiExpr ):
Original file line number Diff line number Diff line change @@ -51,7 +51,7 @@ def test_score_from(self):
51
51
rule = ASI2 ("SCORE FROM ( 100G => 10, 101D => 20 )" )
52
52
self .assertEqual (rule (VariantCalls ("100G 102G" )), 10 )
53
53
54
- def test_score_from (self ):
54
+ def test_score_negate (self ):
55
55
rule = ASI2 ("SCORE FROM ( NOT 100G => 10, NOT 101SD => 20 )" )
56
56
self .assertEqual (rule (VariantCalls ("100G 102G" )), 20 )
57
57
self .assertEqual (rule (VariantCalls ("100S 101S" )), 10 )
You can’t perform that action at this time.
0 commit comments