mirror of
				https://github.com/explosion/spaCy.git
				synced 2025-11-01 00:17:44 +03:00 
			
		
		
		
	
						commit
						eb3040ce46
					
				|  | @ -144,7 +144,7 @@ def is_lower(string): return string.islower() | ||||||
| def is_space(string): return string.isspace() | def is_space(string): return string.isspace() | ||||||
| def is_title(string): return string.istitle() | def is_title(string): return string.istitle() | ||||||
| def is_upper(string): return string.isupper() | def is_upper(string): return string.isupper() | ||||||
| def is_stop(string, stops=set()): return string in stops | def is_stop(string, stops=set()): return string.lower() in stops | ||||||
| def is_oov(string): return True | def is_oov(string): return True | ||||||
| def get_prob(string): return -20. | def get_prob(string): return -20. | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
							
								
								
									
										11
									
								
								spacy/tests/regression/test_issue1889.py
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								spacy/tests/regression/test_issue1889.py
									
									
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,11 @@ | ||||||
|  | # coding: utf-8 | ||||||
|  | from __future__ import unicode_literals | ||||||
|  | from ...lang.lex_attrs import is_stop | ||||||
|  | from ...lang.en.stop_words import STOP_WORDS | ||||||
|  | 
 | ||||||
|  | import pytest | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | @pytest.mark.parametrize('word', ['the']) | ||||||
|  | def test_lex_attrs_stop_words_case_sensitivity(word): | ||||||
|  |     assert is_stop(word, STOP_WORDS) == is_stop(word.upper(), STOP_WORDS) | ||||||
		Loading…
	
		Reference in New Issue
	
	Block a user