Beispiel #1
0
 public void MatchFirst_ShouldRegexMatchFirstWithCaptureGroup()
 {
     Assert.That(FilterExtensions.MatchFirst("Foo: Shakalaka\nFoo: ShakalakaBar", "(?m)^Foo: (.+)$"), Is.EqualTo("Shakalaka"));
 }
Beispiel #2
0
 public void MatchFirst_ShouldReturnEmptyStringIfNoMatch()
 {
     Assert.That(FilterExtensions.MatchFirst("Foo: Shakalaka\nFoo: ShakalakaBar", "(?m)^Foos: .+$"), Is.EqualTo(""));
 }