Example #1
0
        public void PasswordResetMailTemplate_Generates_Correct_Body()
        {
            var template   = new PasswordResetMailTemplate(_appSettings);
            var parameters = new PasswordResetMailTemplateParameters("*****@*****.**", "asdfasdf");

            template.GetMessage(parameters, "*****@*****.**").Body.Should().Be("<p>Please <a href=\"http://localhost/Home/ResetPassword/?email=test%40test.com&token=asdfasdf\">click here to reset your password</a>.</p>");
        }
Example #2
0
        public void PasswordResetMailTemplate_Uses_Correct_Address()
        {
            var template   = new PasswordResetMailTemplate(_appSettings);
            var parameters = new PasswordResetMailTemplateParameters("*****@*****.**", "asdfasdf");

            template.GetMessage(parameters, "*****@*****.**").To.Should().Be("*****@*****.**");
        }
Example #3
0
        public void PasswordResetMailTemplate_Generates_Correct_Subject()
        {
            var template   = new PasswordResetMailTemplate(_appSettings);
            var parameters = new PasswordResetMailTemplateParameters("*****@*****.**", "asdfasdf");

            template.GetMessage(parameters, "*****@*****.**").Subject.Should().Be("Your password reset request");
        }