예제 #1
0
        public void Tests(string anagram, string hash, string expectedPhrase)
        {
            var ecrypter = new Md5Encrypter();
            var words    = File.ReadLines("fractionOfWords.txt").ToList();
            var sut      = new Decrypter(words, ecrypter);

            var actualPhrase = sut.GetDecryptedPhrase(hash, anagram);

            Assert.Equal(expectedPhrase, actualPhrase);
        }
예제 #2
0
        public void Decrypt_ReturnsCorrectPhrases_ForRabbitHunt(string hash, string expectedPhrase)
        {
            var actualPhrase = _sut.GetDecryptedPhrase(hash, Anagram);

            Assert.Equal(expectedPhrase, actualPhrase);
        }
예제 #3
0
        public void Decrypt_ReturnsCorrectPhrases_SingleWord(string anagram, string hash, string expectedPhrase)
        {
            var actualPhrase = _sut.GetDecryptedPhrase(hash, anagram);

            Assert.Equal(expectedPhrase, actualPhrase);
        }