Skip to content

Instantly share code, notes, and snippets.

@JamesBender
Created September 19, 2013 21:34
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save JamesBender/6630171 to your computer and use it in GitHub Desktop.
[Test]
[ExpectedException(typeof(ArgumentException))]
public void ShouldGetAnArgumentExceptionWhenCharacterToScanForIsLargerThanOneCharacter()
{
var sentenceToScan = "This test should throw an exception";
var characterToScanFor = "xx";
var stringUtils = new StringUtils();
stringUtils.FindNumberOfOccurences(sentenceToScan, characterToScanFor);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment