Skip to content

Commit

Permalink
Add test cases for joining Z_SIOT
Browse files Browse the repository at this point in the history
  • Loading branch information
bab2min committed Oct 27, 2024
1 parent 803c97a commit d97c094
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions test/test_cpp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1552,6 +1552,21 @@ TEST(KiwiCpp, JoinRestore)
}
}

TEST(KiwiCpp, JoinZSiot)
{
Kiwi& kiwi = reuseKiwiInstance();
for (auto c : { u8"하굣길", u8"만둣국", u8"나뭇잎", u8"세숫물", u8"고춧가루", u8"시곗바늘", u8"사글셋방" })
{
auto tokens = kiwi.analyze(c, Match::allWithNormalizing | Match::splitSaisiot).first;
auto joiner = kiwi.newJoiner();
for (auto& t : tokens)
{
joiner.add(t.str, t.tag, false);
}
EXPECT_EQ(joiner.getU8(), c);
}
}

TEST(KiwiCpp, NestedSentenceSplit)
{
Kiwi& kiwi = reuseKiwiInstance();
Expand Down

0 comments on commit d97c094

Please sign in to comment.