From b1ace1c6ba8e7c01f3c225db0575da9c372447cd Mon Sep 17 00:00:00 2001 From: Trent Palmer Date: Wed, 21 Apr 2021 13:08:21 -0700 Subject: [PATCH] update accounts/tests/test_password_change_view.py add function test_password_change_view_get --- accounts/tests/test_password_change_view.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/accounts/tests/test_password_change_view.py b/accounts/tests/test_password_change_view.py index b8ed744..961d196 100644 --- a/accounts/tests/test_password_change_view.py +++ b/accounts/tests/test_password_change_view.py @@ -12,6 +12,13 @@ class PasswordChangeViewTestCase(TestCase): user_a.save() Account.objects.create(user=user_a, twitter_handle='@user_a') + def test_password_change_view_get(self): + self.client.login(username='user_a', password='password123456') + response = self.client.get(reverse('accounts:password_change')) + self.assertEquals(response.status_code, 200) + self.assertTemplateUsed(response, 'base_form.html') + self.assertEquals(response.request['PATH_INFO'], '/accounts/password-change/') + def test_password_change_view_no_login(self): response = self.client.post(reverse('accounts:password_change'), { 'old_password': 'password123456',