private void TestChangePasswordQuestionAndAnswerWithWrongPasswordWithPasswordFormat(string passwordFormat) { var config = new NameValueCollection(_config); config["passwordFormat"] = passwordFormat; var provider = new MongoMembershipProvider(); provider.Initialize(DefaultName, config); MembershipCreateStatus status; provider.CreateUser("test", "123456", "*****@*****.**", "OldQuestion", "OldAnswer", true, null, out status); var changed = provider.ChangePasswordQuestionAndAnswer("test", "XXXXXX", "Question", "Answer"); Assert.IsFalse(changed); var user = provider.GetUser("test", false); Assert.IsNotNull(user); Assert.AreEqual("OldQuestion", user.PasswordQuestion); // TODO Check answer when GetPassword implemented. }