* Upd tests

This commit is contained in:
Matthew Honnibal 2014-12-26 14:26:27 +11:00
parent b8b65903fc
commit 91a5064b7f
3 changed files with 6 additions and 2 deletions

View File

@ -21,5 +21,5 @@ def test_load_exc(EN, morph_exc):
EN.tagger.load_morph_exceptions(morph_exc)
tokens = EN('I like his style.', tag=True)
his = tokens[2]
assert EN.tagger.tag_names[his.pos] == 'PRP$'
assert EN.tagger.tag_names[his.fine_pos] == 'PRP$'
assert his.lemma == '-PRP-'

View File

@ -110,7 +110,6 @@ def test_cnts6(EN):
words = [t.string for t in tokens]
assert len(words) == 6
#def test_cnts7():
# text = 'But then the 6,000-year ice age came...'
# tokens = EN.tokenize(text)

View File

@ -27,3 +27,8 @@ def test_case_neq(EN):
def test_punct_neq(EN):
addr = EN.vocab['Hello']
assert EN.vocab['Hello,']['sic'] != addr['sic']
def test_shape_attr(EN):
example = EN.vocab['example']
assert example['sic'] != example['shape']