Skip to content

Commit cf60dd2

Browse files
authored
Merge pull request #173 from rails-on-services/development
**Implemented enhancements:** - #112 - Allow a list of schemas when switching using schemas - #154 - Create schema between different versions of DB - #155 **Fixed bugs:** - #170 - Cache Key breaks on rails 6.0.4 - #171 **Closed issues:** - Add ruby 3 to the build matrix - #162 - update rubocop and fixed broken rules - #157 - added junit formatter and saving test output in circle - #172
2 parents ac0fbb2 + 1929f5f commit cf60dd2

33 files changed

+478
-372
lines changed

.circleci/config.yml

+8-10
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
version: 2.1
22

3-
orbs:
4-
rubocop: hanachin/rubocop@0.0.6
5-
63
jobs:
74
build:
85
docker:
@@ -61,18 +58,19 @@ jobs:
6158
6259
- run:
6360
name: Run tests
64-
command: bundle exec rspec
61+
command: bundle exec rspec --format progress --format RspecJunitFormatter -o ~/test-results/rspec/rspec.xml
62+
63+
- store_test_results:
64+
path: ~/test-results/rspec/
6565

6666
workflows:
6767
tests:
6868
jobs:
6969
- build:
7070
matrix:
7171
parameters:
72-
ruby_version: ["ruby:2.6-buster", "ruby:2.7-buster"]
72+
ruby_version: ["ruby:2.6-buster", "ruby:2.7-buster", "ruby:3.0-buster"]
7373
gemfile: ["gemfiles/rails_5_2.gemfile", "gemfiles/rails_6_0.gemfile", "gemfiles/rails_6_1.gemfile"]
74-
75-
rubocop:
76-
jobs:
77-
- rubocop/rubocop:
78-
version: 0.88.0
74+
exclude:
75+
- ruby_version: "ruby:3.0-buster"
76+
gemfile: "gemfiles/rails_5_2.gemfile"

.github/workflows/reviewdog.yml

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: reviewdog
2+
on: [push, pull_request]
3+
jobs:
4+
rubocop:
5+
name: runner / rubocop
6+
runs-on: ubuntu-latest
7+
steps:
8+
- name: Check out code
9+
uses: actions/checkout@v2
10+
- name: Read ruby version
11+
run: echo ::set-output name=RUBY_VERSION::$(cat .ruby-version | cut -f 1,2 -d .)
12+
id: rv
13+
- uses: ruby/setup-ruby@v1
14+
with:
15+
ruby-version: "${{ steps.rv.outputs.RUBY_VERSION }}"
16+
- uses: reviewdog/action-rubocop@v1
17+
with:
18+
filter_mode: nofilter
19+
reporter: github-check
20+
rubocop_version: 0.93.1
21+
github_token: ${{ secrets.github_token }}
22+
rubocop_extensions: rubocop-performance:1.10.2 rubocop-rails:2.9.1 rubocop-rspec:1.44.1

.rubocop.yml

+17-81
Original file line numberDiff line numberDiff line change
@@ -1,96 +1,32 @@
11
inherit_from: .rubocop_todo.yml
22

3-
AllCops:
4-
Exclude:
5-
- 'gemfiles/**/*.gemfile'
6-
- 'gemfiles/vendor/**/*'
7-
- 'spec/dummy_engine/dummy_engine.gemspec'
8-
9-
Gemspec/RequiredRubyVersion:
10-
Exclude:
11-
- 'ros-apartment.gemspec'
3+
require:
4+
- rubocop-rails
5+
- rubocop-performance
6+
- rubocop-rspec
127

13-
Style/WordArray:
8+
AllCops:
149
Exclude:
10+
- gemfiles/**/*.gemfile
11+
- gemfiles/vendor/**/*
12+
- spec/dummy_engine/dummy_engine.gemspec
1513
- spec/schemas/**/*.rb
1614

17-
Style/NumericLiterals:
18-
Exclude:
19-
- spec/schemas/**/*.rb
15+
NewCops: enable
2016

21-
Layout/EmptyLineAfterMagicComment:
17+
Gemspec/RequiredRubyVersion:
2218
Exclude:
23-
- spec/schemas/**/*.rb
19+
- 'ros-apartment.gemspec'
2420

2521
Metrics/BlockLength:
2622
Exclude:
2723
- spec/**/*.rb
2824

29-
Layout/EmptyLinesAroundAttributeAccessor:
30-
Enabled: true
31-
32-
Layout/SpaceAroundMethodCallOperator:
33-
Enabled: true
34-
35-
Lint/DeprecatedOpenSSLConstant:
36-
Enabled: true
37-
38-
Lint/DuplicateElsifCondition:
39-
Enabled: true
40-
41-
Lint/MixedRegexpCaptureTypes:
42-
Enabled: true
43-
44-
Lint/RaiseException:
45-
Enabled: true
46-
47-
Lint/StructNewOverride:
48-
Enabled: true
49-
50-
Style/AccessorGrouping:
51-
Enabled: true
52-
53-
Style/ArrayCoercion:
54-
Enabled: true
55-
56-
Style/BisectedAttrAccessor:
57-
Enabled: true
58-
59-
Style/CaseLikeIf:
60-
Enabled: true
61-
62-
Style/ExponentialNotation:
63-
Enabled: true
64-
65-
Style/HashAsLastArrayItem:
66-
Enabled: true
67-
68-
Style/HashEachMethods:
69-
Enabled: true
70-
71-
Style/HashLikeCase:
72-
Enabled: true
73-
74-
Style/HashTransformKeys:
75-
Enabled: true
76-
77-
Style/HashTransformValues:
78-
Enabled: true
79-
80-
Style/RedundantAssignment:
81-
Enabled: true
82-
83-
Style/RedundantFetchBlock:
84-
Enabled: true
85-
86-
Style/RedundantFileExtensionInRequire:
87-
Enabled: true
88-
89-
Style/RedundantRegexpCharacterClass:
90-
Enabled: true
25+
Rails/RakeEnvironment:
26+
Enabled: false
9127

92-
Style/RedundantRegexpEscape:
93-
Enabled: true
28+
Rails/ApplicationRecord:
29+
Enabled: false
9430

95-
Style/SlicingWithRange:
96-
Enabled: true
31+
Rails/Output:
32+
Enabled: false

0 commit comments

Comments
 (0)