UX updates to registration form.

- hide optional fields by default.
- instructions only shown when focused in.
- removed header
- Terms of service link and checkbox on same line.
This commit is contained in:
Diana Huang
2017-11-09 12:04:18 -05:00
parent 96f3545136
commit 8693f2fd38
9 changed files with 229 additions and 49 deletions

View File

@@ -208,7 +208,7 @@ class CombinedLoginAndRegisterPage(PageObject):
"""
# Fill in the form
self.wait_for_element_visibility('#register-email', 'Email field is shown')
self.wait_for_element_visibility('#register-honor_code', 'Honor code field is shown')
if email:
self.q(css="#register-email").fill(email)
if full_name:
@@ -223,6 +223,8 @@ class CombinedLoginAndRegisterPage(PageObject):
self.q(css="#register-favorite_movie").fill(favorite_movie)
if terms_of_service:
self.q(css="label[for='register-honor_code']").click()
self.q(css="#register-honor_code").click()
EmptyPromise(lambda: self.q(css='#register-honor_code:checked'), 'Honor code field is checked').fulfill()
# Submit it
self.q(css=".register-button").click()