C# Class UnitTests.RegexTestsBase

This is the base class for every regex test. It contains helper functions that simplify checks.
Exibir arquivo Open project: reedy/AutoWikiBrowser

Protected Methods

Method Description
TestMatch ( Match m ) : void
TestMatch ( Regex r, string text ) : void

Checks if a regex matches a string

TestMatch ( Regex r, string text, bool isMatch ) : void

Checks if a regex matches a string

TestMatches ( Regex r, string text, int expectedMatches ) : void

Method Details

TestMatch() protected static method

protected static TestMatch ( Match m ) : void
m System.Text.RegularExpressions.Match
return void

TestMatch() protected static method

Checks if a regex matches a string
protected static TestMatch ( Regex r, string text ) : void
r System.Text.RegularExpressions.Regex Regex to test
text string Text to match
return void

TestMatch() protected static method

Checks if a regex matches a string
protected static TestMatch ( Regex r, string text, bool isMatch ) : void
r System.Text.RegularExpressions.Regex Regex to test
text string Text to match
isMatch bool If the regex should match the text
return void

TestMatches() protected static method

protected static TestMatches ( Regex r, string text, int expectedMatches ) : void
r System.Text.RegularExpressions.Regex
text string
expectedMatches int
return void