Commit a5524c66936fab9b0ea4e6b7107b5e061f9fed66

Authored by Joenio Costa
1 parent b052d280

Internet Explorer not recognizes JS method $().form.select()

- Changing it to $().select()

(ActionItem2053)
app/views/profile_editor/_organization.rhtml
... ... @@ -17,7 +17,7 @@
17 17 <% if @environment.enabled?('enable_organization_url_change') %>
18 18 <script type="text/javascript">
19 19 function submit_button() {
20   - return $("profile_data_identifier").form.select("input.submit")[0];
  20 + return $("profile-data").select("input.submit")[0];
21 21 }
22 22 function warn_value_change() {
23 23 show_warning('profile-identifier-formitem', "identifier-change-confirmation");
... ...
features/edit_profile.feature
... ... @@ -55,3 +55,41 @@ Feature: edit profile
55 55 And I press "Save"
56 56 Then I should not see "Birth date is invalid"
57 57 And I should not see "Birth date is mandatory"
  58 +
  59 + @selenium
  60 + Scenario: Alert about url change
  61 + Given the following community
  62 + | identifier | name | owner |
  63 + | o-rappa | O Rappa | joao |
  64 + And feature "enable_organization_url_change" is enabled on environment
  65 + When I go to O Rappa's control panel
  66 + And I follow "Community Info and settings" and wait
  67 + Then I should not see "WARNING! You are about to change the address"
  68 + When I fill in "Address" with "banda-o-rappa"
  69 + Then I should see "WARNING! You are about to change the address"
  70 +
  71 + @selenium
  72 + Scenario: Confirm url change
  73 + Given the following community
  74 + | identifier | name | owner |
  75 + | o-rappa | O Rappa | joao |
  76 + And feature "enable_organization_url_change" is enabled on environment
  77 + When I go to O Rappa's control panel
  78 + And I follow "Community Info and settings" and wait
  79 + When I fill in "Address" with "banda-o-rappa"
  80 + Then I should see "WARNING! You are about to change the address"
  81 + When I follow "Yes"
  82 + Then I should not see "WARNING! You are about to change the address"
  83 +
  84 + @selenium
  85 + Scenario: Cancel url change
  86 + Given the following community
  87 + | identifier | name | owner |
  88 + | o-rappa | O Rappa | joao |
  89 + And feature "enable_organization_url_change" is enabled on environment
  90 + When I go to O Rappa's control panel
  91 + And I follow "Community Info and settings" and wait
  92 + When I fill in "Address" with "banda-o-rappa"
  93 + Then I should see "WARNING! You are about to change the address"
  94 + When I follow "No"
  95 + Then I should not see "WARNING! You are about to change the address"
... ...