Skip to content

Commit

Permalink
lintr
Browse files Browse the repository at this point in the history
  • Loading branch information
compwron committed Mar 12, 2024
1 parent ad2af95 commit ccde9c3
Showing 1 changed file with 22 additions and 22 deletions.
44 changes: 22 additions & 22 deletions lib/tasks/lint_factory_bot.rake
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,29 @@ namespace :factory_bot do
puts "linting factory_bot factories for being rails valid objects"
conn = ActiveRecord::Base.connection
invalid_factories = [
# * casa_admin+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_single_case - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
:casa_admin,
# * casa_admin+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_single_case - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * casa_admin+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
:casa_admin,

# * supervisor+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_single_case - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
:supervisor,
# * supervisor+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_single_case - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * supervisor+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
:supervisor,

# * user+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * user+with_single_case - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * user+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * user+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
:user
# * user+with_casa_cases - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * user+with_single_case - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * user+with_case_contact - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
# * user+with_case_contact_wants_driving_reimbursement - Validation failed: Volunteer Case assignee must be an active volunteer (ActiveRecord::RecordInvalid)
:user
]
raise "a suspiciously low number of FactoryBot factories" if FactoryBot.factories.count < 50
factories_to_lint = FactoryBot.factories.reject do |factory|
Expand All @@ -42,4 +42,4 @@ namespace :factory_bot do
raise if $?.exitstatus.nonzero?
end
end
end
end

0 comments on commit ccde9c3

Please sign in to comment.