Fix all Layout/SpaceInsideParens rubocop issues and remove files from rubocop_todo list
This commit is contained in:
@@ -557,15 +557,6 @@ Style/RescueModifier:
|
|||||||
- 'app/controllers/concerns/commentable_actions.rb'
|
- 'app/controllers/concerns/commentable_actions.rb'
|
||||||
- 'app/controllers/verification/sms_controller.rb'
|
- 'app/controllers/verification/sms_controller.rb'
|
||||||
|
|
||||||
# Offense count: 8
|
|
||||||
# Cop supports --auto-correct.
|
|
||||||
Layout/SpaceInsideParens:
|
|
||||||
Exclude:
|
|
||||||
- 'app/models/user.rb'
|
|
||||||
- 'lib/manager_authenticator.rb'
|
|
||||||
- 'spec/features/proposals_spec.rb'
|
|
||||||
- 'spec/models/abilities/moderator_spec.rb'
|
|
||||||
|
|
||||||
# Offense count: 9
|
# Offense count: 9
|
||||||
# Cop supports --auto-correct.
|
# Cop supports --auto-correct.
|
||||||
# Configuration parameters: IgnoredMethods.
|
# Configuration parameters: IgnoredMethods.
|
||||||
|
|||||||
@@ -156,7 +156,7 @@ class User < ActiveRecord::Base
|
|||||||
|
|
||||||
def has_official_email?
|
def has_official_email?
|
||||||
domain = Setting['email_domain_for_officials']
|
domain = Setting['email_domain_for_officials']
|
||||||
email.present? && ( (email.end_with? "@#{domain}") || (email.end_with? ".#{domain}") )
|
email.present? && ((email.end_with? "@#{domain}") || (email.end_with? ".#{domain}"))
|
||||||
end
|
end
|
||||||
|
|
||||||
def display_official_position_badge?
|
def display_official_position_badge?
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ class ManagerAuthenticator
|
|||||||
parsed_response = parser.parse((response[:get_applications_user_list_response][:get_applications_user_list_return]))
|
parsed_response = parser.parse((response[:get_applications_user_list_response][:get_applications_user_list_return]))
|
||||||
aplication_value = parsed_response["APLICACIONES"]["APLICACION"]
|
aplication_value = parsed_response["APLICACIONES"]["APLICACION"]
|
||||||
# aplication_value from UWEB can be an array of hashes or a hash
|
# aplication_value from UWEB can be an array of hashes or a hash
|
||||||
aplication_value.include?( {"CLAVE_APLICACION" => application_key}) || aplication_value["CLAVE_APLICACION"] == application_key
|
aplication_value.include?({"CLAVE_APLICACION" => application_key}) || aplication_value["CLAVE_APLICACION"] == application_key
|
||||||
rescue
|
rescue
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -99,7 +99,7 @@ feature 'Proposals' do
|
|||||||
end
|
end
|
||||||
|
|
||||||
scenario "Show Vimeo video" do
|
scenario "Show Vimeo video" do
|
||||||
proposal = create(:proposal, video_url: "https://vimeo.com/7232823" )
|
proposal = create(:proposal, video_url: "https://vimeo.com/7232823")
|
||||||
visit proposal_path(proposal)
|
visit proposal_path(proposal)
|
||||||
expect(page).to have_selector("div[id='js-embedded-video']")
|
expect(page).to have_selector("div[id='js-embedded-video']")
|
||||||
expect(page.html).to include 'https://player.vimeo.com/video/7232823'
|
expect(page.html).to include 'https://player.vimeo.com/video/7232823'
|
||||||
|
|||||||
@@ -35,14 +35,14 @@ describe "Abilities::Moderator" do
|
|||||||
let(:rejected_organization) { create(:organization, :rejected) }
|
let(:rejected_organization) { create(:organization, :rejected) }
|
||||||
let(:verified_organization) { create(:organization, :verified) }
|
let(:verified_organization) { create(:organization, :verified) }
|
||||||
|
|
||||||
it { should be_able_to( :verify, pending_organization) }
|
it { should be_able_to(:verify, pending_organization) }
|
||||||
it { should be_able_to( :reject, pending_organization) }
|
it { should be_able_to(:reject, pending_organization) }
|
||||||
|
|
||||||
it { should_not be_able_to(:verify, verified_organization) }
|
it { should_not be_able_to(:verify, verified_organization) }
|
||||||
it { should be_able_to( :reject, verified_organization) }
|
it { should be_able_to(:reject, verified_organization) }
|
||||||
|
|
||||||
it { should_not be_able_to(:reject, rejected_organization) }
|
it { should_not be_able_to(:reject, rejected_organization) }
|
||||||
it { should be_able_to( :verify, rejected_organization) }
|
it { should be_able_to(:verify, rejected_organization) }
|
||||||
end
|
end
|
||||||
|
|
||||||
describe "hiding, reviewing and restoring" do
|
describe "hiding, reviewing and restoring" do
|
||||||
|
|||||||
Reference in New Issue
Block a user