public void GetAtBash(string word, string expectedWord) { // Given var ats = new AlephTavService(); // When var actual = ats.GetAtBash(word); // Then Assert.Equal(expectedWord, actual); }
public void FindAtbashComplementsInTanakh() { // Given var ats = new AlephTavService(); var bookService = BookService.GetInstance(); var books = bookService.GetAllBooks(); var wordList = new WordService().GetUniqueWordCountList(books).Select(i => i.Key); // When var actual = ats.FindAtbashWordFromWordlist(wordList.ToList()); // Then Assert.NotEmpty(actual.Distinct()); }
public void FindAtbashComplementsFromWordList() { // Given var ats = new AlephTavService(); var wordList = new List <string> { "aab", "baa", "als", "sla", "pla" }; var expected = new List <string> { "aab", "baa", "als", "sla" }; // when var actual = ats.FindAtbashWordFromWordlist(wordList); // Then actual.ShouldDeepEqual(expected); }