IGLib  1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
NUnit.Framework.StringAssert Class Reference

Basic Asserts on strings. More...

Static Public Member Functions

static new bool Equals (object a, object b)
 The Equals method throws an AssertionException. This is done to make sure there is no mistake by calling this function. More...
 
static new void ReferenceEquals (object a, object b)
 override the default ReferenceEquals to throw an AssertionException. This implementation makes sure there is no mistake in calling this function as part of Assert. More...
 
static void Contains (string expected, string actual, string message, params object[] args)
 Asserts that a string is found within another string. More...
 
static void Contains (string expected, string actual)
 Asserts that a string is found within another string. More...
 
static void DoesNotContain (string expected, string actual, string message, params object[] args)
 Asserts that a string is not found within another string. More...
 
static void DoesNotContain (string expected, string actual)
 Asserts that a string is found within another string. More...
 
static void StartsWith (string expected, string actual, string message, params object[] args)
 Asserts that a string starts with another string. More...
 
static void StartsWith (string expected, string actual)
 Asserts that a string starts with another string. More...
 
static void DoesNotStartWith (string expected, string actual, string message, params object[] args)
 Asserts that a string does not start with another string. More...
 
static void DoesNotStartWith (string expected, string actual)
 Asserts that a string does not start with another string. More...
 
static void EndsWith (string expected, string actual, string message, params object[] args)
 Asserts that a string ends with another string. More...
 
static void EndsWith (string expected, string actual)
 Asserts that a string ends with another string. More...
 
static void DoesNotEndWith (string expected, string actual, string message, params object[] args)
 Asserts that a string does not end with another string. More...
 
static void DoesNotEndWith (string expected, string actual)
 Asserts that a string does not end with another string. More...
 
static void AreEqualIgnoringCase (string expected, string actual, string message, params object[] args)
 Asserts that two strings are equal, without regard to case. More...
 
static void AreEqualIgnoringCase (string expected, string actual)
 Asserts that two strings are equal, without regard to case. More...
 
static void AreNotEqualIgnoringCase (string expected, string actual, string message, params object[] args)
 Asserts that two strings are not equal, without regard to case. More...
 
static void AreNotEqualIgnoringCase (string expected, string actual)
 Asserts that two strings are not equal, without regard to case. More...
 
static void IsMatch (string pattern, string actual, string message, params object[] args)
 Asserts that a string matches an expected regular expression pattern. More...
 
static void IsMatch (string pattern, string actual)
 Asserts that a string matches an expected regular expression pattern. More...
 
static void DoesNotMatch (string pattern, string actual, string message, params object[] args)
 Asserts that a string does not match an expected regular expression pattern. More...
 
static void DoesNotMatch (string pattern, string actual)
 Asserts that a string does not match an expected regular expression pattern. More...
 

Detailed Description

Basic Asserts on strings.

Member Function Documentation

static new bool NUnit.Framework.StringAssert.Equals ( object  a,
object  b 
)
inlinestatic

The Equals method throws an AssertionException. This is done to make sure there is no mistake by calling this function.

Parameters
a
b
static new void NUnit.Framework.StringAssert.ReferenceEquals ( object  a,
object  b 
)
inlinestatic

override the default ReferenceEquals to throw an AssertionException. This implementation makes sure there is no mistake in calling this function as part of Assert.

Parameters
a
b
static void NUnit.Framework.StringAssert.Contains ( string  expected,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that a string is found within another string.

Parameters
expectedThe expected string
actualThe string to be examined
messageThe message to display in case of failure
argsArguments used in formatting the message

References NUnit.Framework.Does.Contain(), and NUnit.Framework.Assert.That().

Referenced by NUnit.Framework.Assertions.StringAssertTests.Contains(), NUnit.Framework.Assertions.StringAssertTests.ContainsFails(), NUnit.Framework.Assertions.LessFixture.FailureMessage(), NUnit.Framework.Assertions.GreaterEqualFixture.FailureMessage(), and NUnit.Framework.Tests.AssertSyntaxTests.SubstringTests().

static void NUnit.Framework.StringAssert.Contains ( string  expected,
string  actual 
)
inlinestatic

Asserts that a string is found within another string.

Parameters
expectedThe expected string
actualThe string to be examined
static void NUnit.Framework.StringAssert.DoesNotContain ( string  expected,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that a string is not found within another string.

Parameters
expectedThe expected string
actualThe string to be examined
messageThe message to display in case of failure
argsArguments used in formatting the message

References NUnit.Framework.Constraints.ConstraintExpression.Contain(), NUnit.Framework.Does.Not, and NUnit.Framework.Assert.That().

Referenced by NUnit.Framework.Assertions.StringAssertTests.DoesNotContain(), and NUnit.Framework.Assertions.StringAssertTests.DoesNotContainFails().

static void NUnit.Framework.StringAssert.DoesNotContain ( string  expected,
string  actual 
)
inlinestatic

Asserts that a string is found within another string.

Parameters
expectedThe expected string
actualThe string to be examined
static void NUnit.Framework.StringAssert.StartsWith ( string  expected,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that a string starts with another string.

Parameters
expectedThe expected string
actualThe string to be examined
messageThe message to display in case of failure
argsArguments used in formatting the message

References NUnit.Framework.Does.StartWith(), and NUnit.Framework.Assert.That().

Referenced by NUnit.Framework.Assertions.StringAssertTests.StartsWith(), NUnit.Framework.Assertions.StringAssertTests.StartsWithFails(), and NUnit.Framework.Tests.AssertSyntaxTests.StartsWithTests().

static void NUnit.Framework.StringAssert.StartsWith ( string  expected,
string  actual 
)
inlinestatic

Asserts that a string starts with another string.

Parameters
expectedThe expected string
actualThe string to be examined
static void NUnit.Framework.StringAssert.DoesNotStartWith ( string  expected,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that a string does not start with another string.

Parameters
expectedThe expected string
actualThe string to be examined
messageThe message to display in case of failure
argsArguments used in formatting the message

References NUnit.Framework.Does.Not, NUnit.Framework.Constraints.ConstraintExpression.StartWith(), and NUnit.Framework.Assert.That().

Referenced by NUnit.Framework.Assertions.StringAssertTests.DoesNotStartWith(), and NUnit.Framework.Assertions.StringAssertTests.DoesNotStartWithFails().

static void NUnit.Framework.StringAssert.DoesNotStartWith ( string  expected,
string  actual 
)
inlinestatic

Asserts that a string does not start with another string.

Parameters
expectedThe expected string
actualThe string to be examined
static void NUnit.Framework.StringAssert.EndsWith ( string  expected,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that a string ends with another string.

Parameters
expectedThe expected string
actualThe string to be examined
messageThe message to display in case of failure
argsArguments used in formatting the message

References NUnit.Framework.Does.EndWith(), and NUnit.Framework.Assert.That().

Referenced by NUnit.Framework.Assertions.StringAssertTests.EndsWith(), NUnit.Framework.Assertions.StringAssertTests.EndsWithFails(), and NUnit.Framework.Tests.AssertSyntaxTests.EndsWithTests().

static void NUnit.Framework.StringAssert.EndsWith ( string  expected,
string  actual 
)
inlinestatic

Asserts that a string ends with another string.

Parameters
expectedThe expected string
actualThe string to be examined
static void NUnit.Framework.StringAssert.DoesNotEndWith ( string  expected,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that a string does not end with another string.

Parameters
expectedThe expected string
actualThe string to be examined
messageThe message to display in case of failure
argsArguments used in formatting the message

References NUnit.Framework.Constraints.ConstraintExpression.EndWith(), NUnit.Framework.Does.Not, and NUnit.Framework.Assert.That().

Referenced by NUnit.Framework.Assertions.StringAssertTests.DoesNotEndWith(), and NUnit.Framework.Assertions.StringAssertTests.DoesNotEndWithFails().

static void NUnit.Framework.StringAssert.DoesNotEndWith ( string  expected,
string  actual 
)
inlinestatic

Asserts that a string does not end with another string.

Parameters
expectedThe expected string
actualThe string to be examined
static void NUnit.Framework.StringAssert.AreEqualIgnoringCase ( string  expected,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that two strings are equal, without regard to case.

Parameters
expectedThe expected string
actualThe actual string
messageThe message to display in case of failure
argsArguments used in formatting the message

Referenced by NUnit.Framework.Assertions.StringAssertTests.CaseInsensitiveCompare(), NUnit.Framework.Assertions.StringAssertTests.CaseInsensitiveCompareFails(), and NUnit.Framework.Tests.AssertSyntaxTests.EqualIgnoringCaseTests().

static void NUnit.Framework.StringAssert.AreEqualIgnoringCase ( string  expected,
string  actual 
)
inlinestatic

Asserts that two strings are equal, without regard to case.

Parameters
expectedThe expected string
actualThe actual string
static void NUnit.Framework.StringAssert.AreNotEqualIgnoringCase ( string  expected,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that two strings are not equal, without regard to case.

Parameters
expectedThe expected string
actualThe actual string
messageThe message to display in case of failure
argsArguments used in formatting the message
static void NUnit.Framework.StringAssert.AreNotEqualIgnoringCase ( string  expected,
string  actual 
)
inlinestatic

Asserts that two strings are not equal, without regard to case.

Parameters
expectedThe expected string
actualThe actual string
static void NUnit.Framework.StringAssert.IsMatch ( string  pattern,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that a string matches an expected regular expression pattern.

Parameters
patternThe regex pattern to be matched
actualThe actual string
messageThe message to display in case of failure
argsArguments used in formatting the message

Referenced by NUnit.Framework.Assertions.StringAssertTests.IsMatch(), NUnit.Framework.Assertions.StringAssertTests.IsMatchFails(), and NUnit.Framework.Tests.AssertSyntaxTests.RegularExpressionTests().

static void NUnit.Framework.StringAssert.IsMatch ( string  pattern,
string  actual 
)
inlinestatic

Asserts that a string matches an expected regular expression pattern.

Parameters
patternThe regex pattern to be matched
actualThe actual string
static void NUnit.Framework.StringAssert.DoesNotMatch ( string  pattern,
string  actual,
string  message,
params object[]  args 
)
inlinestatic

Asserts that a string does not match an expected regular expression pattern.

Parameters
patternThe regex pattern to be used
actualThe actual string
messageThe message to display in case of failure
argsArguments used in formatting the message
static void NUnit.Framework.StringAssert.DoesNotMatch ( string  pattern,
string  actual 
)
inlinestatic

Asserts that a string does not match an expected regular expression pattern.

Parameters
patternThe regex pattern to be used
actualThe actual string

The documentation for this class was generated from the following file: