0
0
Fork 0

Add a test case

This commit is contained in:
ikawaha 2016-02-21 19:59:52 +09:00
parent 4fe7688431
commit fcebff60e9
1 changed files with 26 additions and 0 deletions

View File

@ -41,6 +41,32 @@ func TestKagome(t *testing.T) {
},
},
},
{
[]byte("関西国際空港"),
analysis.TokenStream{
{
Start: 0,
End: 6,
Term: []byte("関西"),
Position: 1,
Type: analysis.Ideographic,
},
{
Start: 6,
End: 12,
Term: []byte("国際"),
Position: 2,
Type: analysis.Ideographic,
},
{
Start: 12,
End: 18,
Term: []byte("空港"),
Position: 3,
Type: analysis.Ideographic,
},
},
},
}
tokenizer := NewKagomeMorphTokenizer()