From b7fac3d6bf59a0350a939682b8512927296b5e12 Mon Sep 17 00:00:00 2001 From: briri Date: Wed, 2 Dec 2020 11:54:20 -0800 Subject: [PATCH] addressed test issues --- app/controllers/orgs_controller.rb | 3 +- .../branded/layouts/application.html.erb | 2 +- .../layouts/mobile/_fixed_menu.html.erb | 4 +-- .../branded/shared/_get_started.html.erb | 2 +- spec/controllers/orgs_controller_spec.rb | 2 +- spec/features/locales_spec.rb | 1 + spec/features/super_admins/orgs_spec.rb | 6 ++-- .../dmptool/orgs_controller_spec.rb | 2 +- .../omniauth_callbacks_controller_spec.rb | 12 +++---- spec/mixins/models/dmptool/org_spec.rb | 2 +- .../presenters/dmptool/org_presenter_spec.rb | 4 +-- .../contacts/_new_right.html.erb_spec.rb | 12 +++---- .../layouts/_analytics.html.erb_spec.rb | 31 ++++++++++--------- .../branded/layouts/_logo.html.erb_spec.rb | 3 -- .../layouts/application.html.erb_spec.rb | 8 ++--- .../mobile/_fixed_menu.html.erb_spec.rb | 8 ++--- .../paginable/orgs/_public.html.erb_spec.rb | 2 +- .../_publicly_visible.html.erb_spec.rb | 2 +- .../shared/org_branding.html.erb_spec.rb | 2 +- .../admin_privileges.html.erb_spec.rb | 29 ----------------- .../api_plan_creation.html.erb_spec.rb | 19 ------------ 21 files changed, 54 insertions(+), 102 deletions(-) delete mode 100644 spec/views/branded/user_mailer/admin_privileges.html.erb_spec.rb delete mode 100644 spec/views/branded/user_mailer/api_plan_creation.html.erb_spec.rb diff --git a/app/controllers/orgs_controller.rb b/app/controllers/orgs_controller.rb index 90d50f3228..9f59e18e95 100644 --- a/app/controllers/orgs_controller.rb +++ b/app/controllers/orgs_controller.rb @@ -42,7 +42,8 @@ def admin_update @org.logo = attrs[:logo] if attrs[:logo] tab = (attrs[:feedback_enabled].present? ? "feedback" : "profile") @org.links = ActiveSupport::JSON.decode(params[:org_links]) if params[:org_links].present? - + attrs.delete(:org_links) + # Only allow super admins to change the org types and shib info if current_user.can_super_admin? identifiers = [] diff --git a/app/views/branded/layouts/application.html.erb b/app/views/branded/layouts/application.html.erb index 3b67531179..f855c9df6f 100644 --- a/app/views/branded/layouts/application.html.erb +++ b/app/views/branded/layouts/application.html.erb @@ -91,7 +91,7 @@ active_page?(user_orcid_omniauth_callback_path) %> <% unless user_signed_in? %> - <% if Rails.configuration.x.shibboleth_use_filtered_discovery_service %> + <% if Rails.configuration.x.shibboleth.use_filtered_discovery_service %> diff --git a/app/views/branded/layouts/mobile/_fixed_menu.html.erb b/app/views/branded/layouts/mobile/_fixed_menu.html.erb index eb25fed57d..2e6f7a770d 100644 --- a/app/views/branded/layouts/mobile/_fixed_menu.html.erb +++ b/app/views/branded/layouts/mobile/_fixed_menu.html.erb @@ -63,12 +63,12 @@