Example #1
0
 public void TestApplySplitList()
 {
     CollectionAssert.AreEqual(new string[] { "The blue bookshelf" },
                               WordUtil.ApplySplitList("The blue bookshelf"));
     CollectionAssert.AreEqual(new string[] { "The blue bookshelf", "the red one",
                                              "The blue bookshelf and the red one" },
                               WordUtil.ApplySplitList("The blue bookshelf and the red one"));
     CollectionAssert.AreEqual(new string[] { "This one", "that one" },
                               WordUtil.ApplySplitList("This one, that one"));
     CollectionAssert.AreEqual(new string[] { "The blue bookshelf", "the red one",
                                              "The blue bookshelf or the red one" },
                               WordUtil.ApplySplitList("The blue bookshelf or the red one"));
     CollectionAssert.AreEqual(new string[] { "The blue bookshelf", "the red one or the green one",
                                              "The blue bookshelf and the red one", "the green one",
                                              "The blue bookshelf and the red one or the green one" },
                               WordUtil.ApplySplitList("The blue bookshelf and the red one or the green one"));
 }