public void Given_the_letter_a_is_passed_a_is_returned() { // Given I have the string 'a' // And I have a position of 26 var value = 'a'; var letterPosition = 26; // When I pass the string value into the alphabet encryptor. IAlphabetEncryptor alphabetEncryptor = new AlphabetEncryptor(new AlphabetInitialiser()); string actual = alphabetEncryptor.EncryptMessage(value, letterPosition); // Then I expect the value returned is 'a' Assert.AreEqual("a", actual); }
public void Given_the_letter_a_is_passed_d_is_returned() { // Given I have the string 'a' // And I have the position of 3 var value = 'a'; var letterPosition = 3; // When // I pass the string value into the alphabet encryptor. IAlphabetEncryptor alphabetEncryptor = new AlphabetEncryptor(new AlphabetInitialiser()); string result = alphabetEncryptor.EncryptMessage(value, letterPosition); // Then I expect the value returned is 'd' Assert.AreEqual("d", result); }