Ejemplo n.º 1
0
 def test_should_return_nopunct(self):
     assert get_punctuation_type_feature('abc') == 'NOPUNCT'
Ejemplo n.º 2
0
 def test_should_return_quote(self):
     assert get_punctuation_type_feature('"') == 'QUOTE'
     assert get_punctuation_type_feature('\'') == 'QUOTE'
     assert get_punctuation_type_feature('`') == 'QUOTE'
     assert get_punctuation_type_feature('’') == 'QUOTE'
Ejemplo n.º 3
0
 def test_should_return_punct(self):
     assert get_punctuation_type_feature(',,') == 'PUNCT'
     assert get_punctuation_type_feature('::') == 'PUNCT'
     assert get_punctuation_type_feature(';;') == 'PUNCT'
     assert get_punctuation_type_feature('??') == 'PUNCT'
     assert get_punctuation_type_feature('..') == 'PUNCT'
Ejemplo n.º 4
0
 def test_should_return_hyphen(self):
     assert get_punctuation_type_feature('-') == 'HYPHEN'
     assert get_punctuation_type_feature('–') == 'HYPHEN'
Ejemplo n.º 5
0
 def test_should_return_comma(self):
     assert get_punctuation_type_feature(',') == 'COMMA'
Ejemplo n.º 6
0
 def test_should_return_dot(self):
     assert get_punctuation_type_feature('.') == 'DOT'
Ejemplo n.º 7
0
 def test_should_return_endbracket(self):
     assert get_punctuation_type_feature(')') == 'ENDBRACKET'
     assert get_punctuation_type_feature(']') == 'ENDBRACKET'
Ejemplo n.º 8
0
 def test_should_return_openbracket(self):
     assert get_punctuation_type_feature('(') == 'OPENBRACKET'
     assert get_punctuation_type_feature('[') == 'OPENBRACKET'