Merge lp:~diegosarmentero/ubuntu-sso-client/reset-page-not-working into lp:ubuntu-sso-client

Proposed by Diego Sarmentero
Status: Merged
Approved by: Natalia Bidart
Approved revision: 898
Merged at revision: 898
Proposed branch: lp:~diegosarmentero/ubuntu-sso-client/reset-page-not-working
Merge into: lp:ubuntu-sso-client
Diff against target: 29 lines (+11/-1)
2 files modified
ubuntu_sso/qt/tests/test_ubuntu_sso_wizard.py (+10/-0)
ubuntu_sso/qt/ubuntu_sso_wizard.py (+1/-1)
To merge this branch: bzr merge lp:~diegosarmentero/ubuntu-sso-client/reset-page-not-working
Reviewer Review Type Date Requested Status
Natalia Bidart (community) Approve
Roberto Alsina (community) Approve
Review via email: mp+95905@code.launchpad.net

Commit message

- Changed the name of the function assigned to the lambda that is called on passwordChanged signal from reset_password_page (LP: #945080).

Description of the change

Start with --login_only, select the option to reset the password, enter a valid token in the Reset Password Page and press the "reset" button, that should take you to the current user sign in page again.

To post a comment you must log in.
Revision history for this message
Roberto Alsina (ralsina) wrote :

+1 but please change sing_in to sign_in

review: Approve
898. By Diego Sarmentero

fixing typo

Revision history for this message
Natalia Bidart (nataliabidart) wrote :

Loosk good, and works as expected.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'ubuntu_sso/qt/tests/test_ubuntu_sso_wizard.py'
--- ubuntu_sso/qt/tests/test_ubuntu_sso_wizard.py 2012-03-01 18:03:54 +0000
+++ ubuntu_sso/qt/tests/test_ubuntu_sso_wizard.py 2012-03-05 14:40:21 +0000
@@ -136,3 +136,13 @@
136 # We do +1 because a hide action is executed on the wizard init.136 # We do +1 because a hide action is executed on the wizard init.
137 self.assertEqual(self.ui.overlay.hide_counter,137 self.assertEqual(self.ui.overlay.hide_counter,
138 len(self.ui._pages) + 1)138 len(self.ui._pages) + 1)
139
140 def test_go_back_to_current_user_sign_in(self):
141 """Move the wizard back to the current user sign in page."""
142 self.patch(self.ui, '_go_back_to_page', self._set_called)
143 self.ui._next_id = self.ui.current_user_page_id
144 self.ui.next()
145 self.ui._move_to_reset_password_page()
146 self.ui.reset_password.passwordChanged.emit('')
147 expected = ((self.ui.current_user,), {})
148 self.assertEqual(expected, self._called)
139149
=== modified file 'ubuntu_sso/qt/ubuntu_sso_wizard.py'
--- ubuntu_sso/qt/ubuntu_sso_wizard.py 2012-03-01 18:03:54 +0000
+++ ubuntu_sso/qt/ubuntu_sso_wizard.py 2012-03-05 14:40:21 +0000
@@ -107,7 +107,7 @@
107 self.addPage(self.forgotten)107 self.addPage(self.forgotten)
108108
109 self.reset_password = ResetPasswordPage(**kwargs)109 self.reset_password = ResetPasswordPage(**kwargs)
110 back = lambda *a: self._go_back_to_current_page(self.current_user)110 back = lambda *a: self._go_back_to_page(self.current_user)
111 self.reset_password.passwordChanged.connect(back)111 self.reset_password.passwordChanged.connect(back)
112 self.addPage(self.reset_password)112 self.addPage(self.reset_password)
113113

Subscribers

People subscribed via source and target branches