Skip to content

Commit

Permalink
fixed float comparison errors in test_kiwipiepy.py
Browse files Browse the repository at this point in the history
  • Loading branch information
bab2min committed Oct 31, 2023
1 parent ea797cc commit 32d23df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/test_kiwipiepy.py
Original file line number Diff line number Diff line change
Expand Up @@ -466,7 +466,7 @@ def test_add_rule():
kiwi = Kiwi(load_typo_dict=False)
assert len(kiwi.add_re_rule("EF", r"요$", "용", score=-1)) > 0
res, score = kiwi.analyze("했어용! 하잖아용! 할까용? 좋아용!")[0]
assert score == oscore - 4
assert abs(score - (oscore - 4)) < 1e-3

def test_add_pre_analyzed_word():
kiwi = Kiwi()
Expand Down

0 comments on commit 32d23df

Please sign in to comment.