public void RegexExtractionFunctionTest_NoRegex() { var regex = new Regex(""); var data = "I_Am_Gonna_Go_Through_The_Alphabet_Now_/a/b/c/d/e/f/g/h......."; var result = ExtractionFunctions.RegexFunc(data, regex).Result; Assert.Equal(string.Empty, result); }
public void RegexExtractionFunctionTest() { var regex = new Regex(".*/a/(.*)/c/d/e.*"); var data = "I_Am_Gonna_Go_Through_The_Alphabet_Now_/a/b/c/d/e/f/g/h......."; var result = ExtractionFunctions.RegexFunc(data, regex).Result; Assert.Equal("b", result); }