Skip to content

Commit

Permalink
Merge pull request #187 from samvera/bixby3.0
Browse files Browse the repository at this point in the history
Support ruby 2.7
  • Loading branch information
jeremyf committed Jun 11, 2020
2 parents 40019dd + 54d8b9d commit a88f033
Show file tree
Hide file tree
Showing 4 changed files with 172 additions and 206 deletions.
13 changes: 4 additions & 9 deletions .circleci/config.yml
Expand Up @@ -30,12 +30,6 @@ jobs:
bundler_version: << parameters.bundler_version >>
cache_version: '2'
project: hydra-editor
- run:
name: "Download the Code Climate reporter"
command: |
curl -L "https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64" > ./cc-test-reporter
chmod +x ./cc-test-reporter
./cc-test-reporter before-build
- samvera/engine_cart_generate:
cache_key: v2-internal-test-app-{{ checksum "hydra-editor.gemspec" }}-{{ checksum "Gemfile" }}-{{ checksum "spec/test_app_templates/lib/generators/test_app_generator.rb" }}-<< parameters.rails_version >>-<< parameters.ruby_version >>
- samvera/install_solr_core:
Expand All @@ -47,14 +41,15 @@ jobs:
project: hydra-editor
- samvera/rubocop
- samvera/parallel_rspec
- run:
name: "Submit the exit code to Code Climate"
command: ./cc-test-reporter after-build --exit-code $?

workflows:
version: 2
ci:
jobs:
- bundle_lint_test:
name: bundle_ruby2-7_rails5-2
ruby_version: 2.7.1
rails_version: 5.2.3
- bundle_lint_test:
name: bundle_ruby2-6_rails5-2
ruby_version: 2.6.3
Expand Down
94 changes: 7 additions & 87 deletions .rubocop.yml
@@ -1,99 +1,19 @@
inherit_gem:
bixby: bixby_default.yml
inherit_from: .rubocop_todo.yml

AllCops:
DisplayCopNames: true
Include:
- '**/Rakefile'
- '**/config.ru'
Exclude:
- 'db/**/*'
- 'script/**/*'
- 'spec/test_app_templates/**/*'
- 'vendor/bundle/**/*'

Bundler/DuplicatedGem:
Exclude:
- 'Gemfile'
TargetRubyVersion: 2.6

Layout/IndentationConsistency:
EnforcedStyle: rails

Metrics/AbcSize:
Max: 50

Metrics/BlockLength:
Exclude:
- 'hydra-editor.gemspec'
- 'spec/views/records/_form.html.erb_spec.rb'
- 'spec/helpers/records_helper_spec.rb'
- 'spec/inputs/multi_value_input_spec.rb'
- 'spec/controllers/records_controller_spec.rb'
- 'spec/routing/records_routing_spec.rb'
- 'spec/presenters/hydra_editor_presenter_spec.rb'
- 'spec/forms/hydra_editor_form_permissions_spec.rb'
- 'spec/forms/hydra_editor_form_spec.rb'
- 'spec/features/record_editing_spec.rb'

Metrics/LineLength:
Max: 400

Metrics/MethodLength:
Max: 30
inherit_from: .rubocop_todo.yml

Naming/FileName:
Exclude:
- 'lib/tasks/hydra-editor_tasks.rake'
- '**/Gemfile'
- '**/*.rake'
- 'hydra-pcdm.gemspec'
- 'lib/hydra-editor.rb'
- 'hydra-editor.gemspec'
- 'Gemfile'
- 'spec/hydra-editor_spec.rb'

Rails:
Enabled: true

RSpec/AnyInstance:
Exclude:
- 'spec/features/record_editing_spec.rb'
- 'spec/features/create_record_spec.rb'

RSpec/DescribeClass:
Exclude:
- 'spec/views/records/edit_fields/_default.html.erb_spec.rb'
- 'spec/views/records/_form.html.erb_spec.rb'
- 'spec/routing/records_routing_spec.rb'
- 'spec/javascripts/jasmine_spec.rb'
- 'spec/features/record_editing_spec.rb'

RSpec/ExampleLength:
Exclude:
- 'spec/helpers/records_helper_spec.rb'
- 'spec/javascripts/jasmine_spec.rb'
- 'spec/features/record_editing_spec.rb'
- 'spec/features/create_record_spec.rb'

RSpec/InstanceVariable:
Exclude:
- 'spec/controllers/records_controller_spec.rb'

RSpec/VerifiedDoubles:
Metrics/BlockLength:
Exclude:
- 'spec/inputs/multi_value_input_spec.rb'
- 'spec/helpers/records_helper_spec.rb'
- 'spec/forms/hydra_editor_form_spec.rb'

Style/CollectionMethods:
PreferredMethods:
collect: 'map'
collect!: 'map!'
inject: 'reduce'
detect: 'find'
find_all: 'select'


Style/RegexpLiteral:
Enabled: false

Style/SingleLineBlockParams:
Enabled: false
- 'spec/**/*.rb'

0 comments on commit a88f033

Please sign in to comment.