public void ToString_ShouldReturnTheExpectedString_WhenInvoked() { // Arrange // Act string actual = new TokenizationStrategy().ToString(); // Assert Assert.IsTrue( string.Equals( ObjectMother.TokenizationStrategy_ToString, actual, StringComparison.InvariantCulture)); }
public void EqualsAndEqualityOperators_ShouldReturnTheExpectedBoolean_WhenInvoked (TokenizationStrategy a, TokenizationStrategy b, bool expected) { // Arrange // Act bool actual1 = a.Equals(b); bool actual2 = a == b; bool actual3 = a != b; // Assert Assert.AreEqual(expected, actual1); Assert.AreEqual(expected, actual2); Assert.AreNotEqual(expected, actual3); }
public void TokenizationStrategy_ShouldCreateAnInstanceOfThisType_WhenProperArgument() { // Arrange // Act TokenizationStrategy actual1 = new TokenizationStrategy( TokenizationStrategy.DefaultPattern, TokenizationStrategy.DefaultDelimiter, TokenizationStrategy.DefaultToLowercase ); TokenizationStrategy actual2 = new TokenizationStrategy(); // Assert Assert.IsInstanceOf <TokenizationStrategy>(actual1); Assert.IsInstanceOf <TokenizationStrategy>(actual2); }