diff --git a/app/views/devise/registrations/edit.html.haml b/app/views/devise/registrations/edit.html.haml index 7a6f1943c..05450c0b1 100644 --- a/app/views/devise/registrations/edit.html.haml +++ b/app/views/devise/registrations/edit.html.haml @@ -11,6 +11,11 @@ = f.email_field :email %span.help-inline If you change your email address you will have to reconfirm + .control-group + .controls + = f.check_box :show_email + Show email publicly on your profile page + %h2 Change password .control-group diff --git a/app/views/devise/registrations/new.html.haml b/app/views/devise/registrations/new.html.haml index 84b63af5b..071d1956c 100644 --- a/app/views/devise/registrations/new.html.haml +++ b/app/views/devise/registrations/new.html.haml @@ -22,7 +22,7 @@ .control-group .controls = f.check_box :tos_agreement - I agree to the + I agree to the = link_to('Terms of Service', url_for(:action => 'tos', :controller => '/policy')) .form-actions diff --git a/spec/views/devise/registrations/edit_spec.rb b/spec/views/devise/registrations/edit_spec.rb index 25bb6d4c5..8eedcc41a 100644 --- a/spec/views/devise/registrations/edit_spec.rb +++ b/spec/views/devise/registrations/edit_spec.rb @@ -18,9 +18,14 @@ describe 'devise/registrations/edit.html.haml', :type => "view" do rendered.should contain 'Email' end - it 'should have an email section' do - assert_select "h2", "Email address" - end + context 'email section' + it 'has a heading' do + assert_select "h2", "Email address" + end + + it 'shows show_email checkbox' do + assert_select "input[id=member_show_email][type=checkbox]" + end it 'should have a password section' do assert_select "h2", "Change password"