mirror of
https://github.com/debauchee/barrier.git
synced 2026-02-08 04:45:03 +08:00
Add split empty string unit test #4933
This commit is contained in:
@@ -134,6 +134,15 @@ TEST(StringTests, splitString_noSeparator_returnOriginalString)
|
||||
EXPECT_EQ("stub1", results[0]);
|
||||
}
|
||||
|
||||
TEST(StringTests, splitString_emptyString_returnEmptyVector)
|
||||
{
|
||||
String string;
|
||||
|
||||
std::vector<String> results = string::splitString(string, ':');
|
||||
|
||||
EXPECT_EQ(0, results.size());
|
||||
}
|
||||
|
||||
TEST(StringTests, splitString_tailSeparator_returnTwoParts)
|
||||
{
|
||||
String string = "stub1:stub2:";
|
||||
|
||||
Reference in New Issue
Block a user