Пример #1
0
 public void Fields()
 {
     string[] result = StringSplitter.From(";").Split("1;2");
     Assert.AreEqual(2, result.Length);
     Assert.AreEqual("1", result [0]);
     Assert.AreEqual("2", result [1]);
 }
Пример #2
0
 public void EmptyNot()
 {
     string[] result = StringSplitter.From(";").Split(";");
     Assert.AreEqual(2, result.Length);              //two empty fields, works differently than in Java
 }
Пример #3
0
 public void NoSeparator()
 {
     string[] result = StringSplitter.From(";").Split("");
     Assert.AreEqual(1, result.Length);
     Assert.AreEqual("", result [0]);
 }