commit/galaxy-central: Dave Bouvier: Update login methods in twilltestcase to be more robust.
1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/80ab774559f8/ Changeset: 80ab774559f8 User: Dave Bouvier Date: 2013-05-08 22:50:00 Summary: Update login methods in twilltestcase to be more robust. Affected #: 1 file diff -r 2a98acf9e8d4db4a287351e6f2e1a2909ba3b0dd -r 80ab774559f8405a46082286c6cf35db420db002 test/base/twilltestcase.py --- a/test/base/twilltestcase.py +++ b/test/base/twilltestcase.py @@ -1068,10 +1068,8 @@ # HACK: don't use panels because late_javascripts() messes up the twill browser and it # can't find form fields (and hence user can't be logged in). self.visit_url( "%s/user/login?use_panels=False" % self.url ) - tc.fv( '1', 'email', email ) - tc.fv( '1', 'redirect', redirect ) - tc.fv( '1', 'password', password ) - tc.submit( 'login_button' ) + self.submit_form( 1, 'login_button', email=email, redirect=redirect, password=password ) + def logout( self ): self.home() self.visit_page( "user/logout" ) @@ -1368,12 +1366,7 @@ # HACK: don't use panels because late_javascripts() messes up the twill browser and it # can't find form fields (and hence user can't be logged in). self.visit_url( "%s/user/create?cntrller=admin" % self.url ) - tc.fv( '1', 'email', email ) - tc.fv( '1', 'redirect', redirect ) - tc.fv( '1', 'password', password ) - tc.fv( '1', 'confirm', password ) - tc.fv( '1', 'username', username ) - tc.submit( 'create_user_button' ) + self.submit_form( 1, 'create_user_button', email=email, redirect=redirect, password=password, confirm=password, username=username ) previously_created = False username_taken = False invalid_username = False @@ -1396,6 +1389,7 @@ except: pass return previously_created, username_taken, invalid_username + def reset_password_as_admin( self, user_id, password='testreset' ): """Reset a user password""" self.home() Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.
participants (1)
-
commits-noreply@bitbucket.org