Skip to content

Commit

Permalink
Merge pull request #4195 from vespa-engine/bratseth/token-symmetry
Browse files Browse the repository at this point in the history
Test tokens with accents are processed symmetrically
  • Loading branch information
bratseth authored Sep 11, 2024
2 parents 0e7b3c1 + 8498307 commit 024d379
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion tests/search/linguistics/open-nlp/documents.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[
{"id":"id:test:test::doc1","fields":{"text":"是一个展示雅,目前在测试阶段。"}},
{"id":"id:test:test::doc2","fields":{"text":"Will still be stemmed: Cars."}}
{"id":"id:test:test::doc2","fields":{"text":"Will still be stemmed: Cars."}},
{"id":"id:test:test::doc3","fields":{"text":"congés"}}
]
3 changes: 2 additions & 1 deletion tests/search/linguistics/open-nlp/opennlp_linguistics.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ class OpenNlpLinguistics < SearchTest

def setup
set_owner("bratseth")
set_description("Tests Chinese segmentation with the OpenNlp linguistics module")
set_description("Tests the OpenNlp linguistics module")
end

def make_app
Expand All @@ -31,6 +31,7 @@ def test_opennlp_linguistics

assert_hitcount("query=text:展示", 1) # A Chinese token from the resulting segmentation done
assert_hitcount("query=text:car", 1) # English is still stemmed
assert_hitcount("query=text:congés", 1)
end

def teardown
Expand Down

0 comments on commit 024d379

Please sign in to comment.