Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; MenuItem has a deprecated constructor in /home/charl422/nunitsoftware.com/nunitv2/php/build_menu.php on line 34
NUnit - StringAssert
NUnit 2.5 Legacy Documentation. View NUnit 3 Documentation

StringAssert (NUnit 2.2.3)

The StringAssert class provides a number of methods that are useful when examining string values.

StringAssert.Contains( string expected, string actual );
StringAssert.Contains( string expected, string actual, 
                string message );
StringAssert.Contains( string expected, string actual,
                string message, params object[] args );

StringAssert.StartsWith( string expected, string actual );
StringAssert.StartsWith( string expected, string actual, 
                string message );
StringAssert.StartsWith( string expected, string actual,
                string message, params object[] args );

StringAssert.EndsWith( string expected, string actual );
StringAssert.EndsWith( string expected, string actual, 
                string message );
StringAssert.EndsWith( string expected, string actual,
                string message, params object[] args );

StringAssert.AreEqualIgnoringCase( string expected, string actual );
StringAssert.AreEqualIgnoringCase( string expected, string actual, 
                string message );
StringAssert.AreEqualIgnoringCase( string expected, string actual,
                string message params object[] args );
				
StringAssert.IsMatch( string regexPattern, string actual );
StringAssert.IsMatch( string regexPattern, string actual, 
                string message );
StringAssert.IsMatch( string regexPattern, string actual,
                string message, params object[] args );