Example #1
0
 public void SampleTest()
 {
     Assert.AreEqual(null, RemoveFirstAndLastCharacterPartTwo.Array(""));
     Assert.AreEqual(null, RemoveFirstAndLastCharacterPartTwo.Array("1"));
     Assert.AreEqual(null, RemoveFirstAndLastCharacterPartTwo.Array("1, 3"));
     Assert.AreEqual("2", RemoveFirstAndLastCharacterPartTwo.Array("1,2,3"));
     Assert.AreEqual("2 3", RemoveFirstAndLastCharacterPartTwo.Array("1,2,3,4"));
 }
Example #2
0
 public void RandomTest()
 {
     for (var i = 0; i < 300; i++)
     {
         var str      = RandomString();
         var expected = Solution(str);
         var message  = FailureMessage(str, expected);
         var actual   = RemoveFirstAndLastCharacterPartTwo.Array(str);
         // Console.WriteLine(message);
         Assert.AreEqual(expected, actual, message);
     }
 }