payroll_hero-api 1.2.7 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 77e5710d27a5a6ac5f19f076937de2ece85b1bfdc2fa34a929251e80c74c435e
4
- data.tar.gz: b28de20d36dfda6895afe6f5845bb54a21b1e2bc92c8de379fa64fdace19ef21
3
+ metadata.gz: ac465cfa37b58e1920c41ea738dd2abc17a0fd9be7e2ab1b0c0c810842751f2a
4
+ data.tar.gz: 025353a74f5b48720fe91af34ee307ecaf1edada0410557ee3a29196041ebfc0
5
5
  SHA512:
6
- metadata.gz: 6e8332d4e084e98d1860fa66733e1222ae7a641c614d43340eca6f0e6ca1c89e2b8b1997c1950322874ae950a71864dc7685753e4bf4e2719c7d7e523f93b845
7
- data.tar.gz: e9a4c5d54984b0fc3dff6a48d24a4e4eb5714ba1708c9c7cb11085a6ed4a8a285270cb8a74dfa3f0a30ac901e4c3c5341b83ca6a0a4665084d92080be8851ca9
6
+ metadata.gz: 2695041a137e5e1caaf6d18d97c3475a1f37629bbb14e260532cfd5e1d1d588967b9011b981c5db575e4f73e2dbf2967133d883d3fa59d346357cd2e968fe143
7
+ data.tar.gz: 2ff97007820ae845b4394a9dd74287cd04f271d3c6ddc53f621baa2804fbe864312090e077f1c72d538bc9ad9771ca66fcbf4b23e475c1cd73dd3d1ef70f2636
@@ -0,0 +1,63 @@
1
+ # This workflow uses actions that are not certified by GitHub.
2
+ # They are provided by a third-party and are governed by
3
+ # separate terms of service, privacy policy, and support
4
+ # documentation.
5
+ # This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
6
+ # For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
7
+
8
+ name: ci
9
+
10
+ on:
11
+ - push
12
+ - pull_request
13
+
14
+ jobs:
15
+ test:
16
+ runs-on: ubuntu-20.04
17
+ strategy:
18
+ fail-fast: false
19
+ matrix:
20
+ gemfile: ["rails_7.0"]
21
+ ruby: [2.7]
22
+ include:
23
+ - gemfile: rails_7.0
24
+ ruby: '3.1'
25
+ # - gemfile: rails_6.1
26
+ # ruby: '3.1'
27
+ - gemfile: rails_7.0
28
+ ruby: '3.0'
29
+ # - gemfile: rails_6.1
30
+ # ruby: '3.0'
31
+ - gemfile: rails_6.1
32
+ ruby: 2.7
33
+ - gemfile: rails_6.1
34
+ ruby: 2.6
35
+ # - gemfile: rails_6.0
36
+ # ruby: 2.7
37
+ # - gemfile: rails_6.0
38
+ # ruby: 2.6
39
+ # - gemfile: rails_5.2
40
+ # ruby: 2.6
41
+ # - gemfile: rails_5.1
42
+ # ruby: 2.6
43
+ # - gemfile: rails_5.0
44
+ # ruby: 2.6
45
+ # - gemfile: rails_4.2
46
+ # ruby: 2.6
47
+ - gemfile: rails_4.2
48
+ ruby: 2.5
49
+
50
+ env:
51
+ #BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.gemfile }}.gemfile
52
+ CI: true
53
+ COVERALLS_REPO_TOKEN: pending
54
+ steps:
55
+ - uses: actions/checkout@v2
56
+ - uses: ruby/setup-ruby@v1
57
+ with:
58
+ ruby-version: ${{ matrix.ruby }}
59
+ bundler-cache: true
60
+ - name: RSpec and Rubocop
61
+ run: |
62
+ bundle exec rubocop -c .rubocop.yml
63
+ bundle exec rspec
@@ -0,0 +1,26 @@
1
+ name: "RuboCop Challenge"
2
+
3
+ on:
4
+ schedule:
5
+ - cron: '30 23 * * 2,3,4' # この設定の場合、火水木のAM8:30に自動でPRが作られます。
6
+
7
+ jobs:
8
+ create-pr:
9
+ name: Create Pull Request
10
+ runs-on: ubuntu-latest
11
+ steps:
12
+ - uses: actions/checkout@v2
13
+ - name: Set up Ruby 2.7
14
+ uses: ruby/setup-ruby@v1
15
+ with:
16
+ ruby-version: 2.7.6
17
+ - name: Install bundler
18
+ run: gem install bundler
19
+ - name: Install gems
20
+ run: bundle install --jobs 4 --retry 3
21
+ - name: Set git configuration
22
+ run: git config remote.origin.url "git@github.com:payrollhero/payroll_hero-api.git" # プロジェクトごとに変わる値です。
23
+ - name: Create RuboCop challenge pull request
24
+ env:
25
+ GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26
+ run: bundle exec rubocop_challenger go --base-branch=master --email=rubocop@payrollhero.com --name="Rubocop Challenger" --mode=random
data/.rubocop.yml ADDED
@@ -0,0 +1 @@
1
+ inherit_from: .rubocop_todo.yml
data/.rubocop_todo.yml ADDED
@@ -0,0 +1,279 @@
1
+ # This configuration was generated by
2
+ # `rubocop --auto-gen-config`
3
+ # on 2022-11-11 07:13:36 UTC using RuboCop version 1.38.0.
4
+ # The point is for the user to remove these configuration records
5
+ # one by one as the offenses are removed from the code base.
6
+ # Note that changes in the inspected code, or installation of new
7
+ # versions of RuboCop, may require this file to be generated again.
8
+
9
+ # Offense count: 1
10
+ # This cop supports safe autocorrection (--autocorrect).
11
+ # Configuration parameters: TreatCommentsAsGroupSeparators, ConsiderPunctuation, Include.
12
+ # Include: **/*.gemspec
13
+ Gemspec/OrderedDependencies:
14
+ Exclude:
15
+ - 'payroll_hero-api.gemspec'
16
+
17
+ # Offense count: 1
18
+ # Configuration parameters: Include.
19
+ # Include: **/*.gemspec
20
+ Gemspec/RequiredRubyVersion:
21
+ Exclude:
22
+ - 'payroll_hero-api.gemspec'
23
+
24
+ # Offense count: 1
25
+ # This cop supports safe autocorrection (--autocorrect).
26
+ Layout/EmptyLineAfterGuardClause:
27
+ Exclude:
28
+ - 'lib/payroll_hero/api/configuration.rb'
29
+
30
+ # Offense count: 1
31
+ # This cop supports safe autocorrection (--autocorrect).
32
+ Layout/EmptyLineAfterMagicComment:
33
+ Exclude:
34
+ - 'payroll_hero-api.gemspec'
35
+
36
+ # Offense count: 2
37
+ # This cop supports safe autocorrection (--autocorrect).
38
+ Layout/EmptyLines:
39
+ Exclude:
40
+ - 'lib/payroll_hero/api/base_group.rb'
41
+ - 'spec/payroll_hero/v4_schedule_events_spec.rb'
42
+
43
+ # Offense count: 2
44
+ # This cop supports safe autocorrection (--autocorrect).
45
+ # Configuration parameters: EnforcedStyle.
46
+ # SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines, beginning_only, ending_only
47
+ Layout/EmptyLinesAroundClassBody:
48
+ Exclude:
49
+ - 'lib/payroll_hero/api/v4/schedule_events.rb'
50
+
51
+ # Offense count: 13
52
+ # This cop supports safe autocorrection (--autocorrect).
53
+ # Configuration parameters: EnforcedStyle.
54
+ # SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines
55
+ Layout/EmptyLinesAroundModuleBody:
56
+ Exclude:
57
+ - 'lib/payroll_hero/api/base_group.rb'
58
+ - 'lib/payroll_hero/api/client.rb'
59
+ - 'lib/payroll_hero/api/errors.rb'
60
+ - 'lib/payroll_hero/api/v2/worksites.rb'
61
+ - 'lib/payroll_hero/api/v3/attendance_days.rb'
62
+ - 'lib/payroll_hero/api/v3/day_schedules.rb'
63
+ - 'lib/payroll_hero/api/v3/employees.rb'
64
+
65
+ # Offense count: 1
66
+ # This cop supports safe autocorrection (--autocorrect).
67
+ # Configuration parameters: AllowDoxygenCommentStyle, AllowGemfileRubyComment.
68
+ Layout/LeadingCommentSpace:
69
+ Exclude:
70
+ - 'lib/payroll_hero/api/v3/attendance_days.rb'
71
+
72
+ # Offense count: 4
73
+ # This cop supports safe autocorrection (--autocorrect).
74
+ Layout/SpaceAfterComma:
75
+ Exclude:
76
+ - 'spec/payroll_hero/v4_schedule_events_spec.rb'
77
+
78
+ # Offense count: 1
79
+ # This cop supports safe autocorrection (--autocorrect).
80
+ # Configuration parameters: AllowForAlignment.
81
+ Layout/SpaceBeforeFirstArg:
82
+ Exclude:
83
+ - 'lib/payroll_hero/api/v4/employees.rb'
84
+
85
+ # Offense count: 3
86
+ # This cop supports safe autocorrection (--autocorrect).
87
+ # Configuration parameters: EnforcedStyle, EnforcedStyleForEmptyBraces.
88
+ # SupportedStyles: space, no_space, compact
89
+ # SupportedStylesForEmptyBraces: space, no_space
90
+ Layout/SpaceInsideHashLiteralBraces:
91
+ Exclude:
92
+ - 'spec/payroll_hero/v4_employees_spec.rb'
93
+
94
+ # Offense count: 2
95
+ # Configuration parameters: AllowComments.
96
+ Lint/EmptyFile:
97
+ Exclude:
98
+ - 'gemfiles/rails_6.1.gemfile'
99
+ - 'gemfiles/rails_7.0.gemfile'
100
+
101
+ # Offense count: 1
102
+ # Configuration parameters: AllowedMethods, AllowedPatterns, IgnoredMethods, CountRepeatedAttributes.
103
+ Metrics/AbcSize:
104
+ Max: 22
105
+
106
+ # Offense count: 3
107
+ # Configuration parameters: CountComments, CountAsOne, ExcludedMethods, AllowedMethods, AllowedPatterns, IgnoredMethods.
108
+ # AllowedMethods: refine
109
+ Metrics/BlockLength:
110
+ Max: 75
111
+
112
+ # Offense count: 6
113
+ # Configuration parameters: CountComments, CountAsOne, ExcludedMethods, AllowedMethods, AllowedPatterns, IgnoredMethods.
114
+ Metrics/MethodLength:
115
+ Max: 20
116
+
117
+ # Offense count: 7
118
+ # Configuration parameters: CountKeywordArgs, MaxOptionalParameters.
119
+ Metrics/ParameterLists:
120
+ Max: 12
121
+
122
+ # Offense count: 2
123
+ # This cop supports safe autocorrection (--autocorrect).
124
+ # Configuration parameters: EnforcedStyle, ProceduralMethods, FunctionalMethods, AllowedMethods, AllowedPatterns, IgnoredMethods, AllowBracesOnProceduralOneLiners, BracesRequiredMethods.
125
+ # SupportedStyles: line_count_based, semantic, braces_for_chaining, always_braces
126
+ # ProceduralMethods: benchmark, bm, bmbm, create, each_with_object, measure, new, realtime, tap, with_object
127
+ # FunctionalMethods: let, let!, subject, watch
128
+ # AllowedMethods: lambda, proc, it
129
+ Style/BlockDelimiters:
130
+ Exclude:
131
+ - 'spec/payroll_hero/api_spec.rb'
132
+ - 'spec/payroll_hero/v4_schedule_events_spec.rb'
133
+
134
+ # Offense count: 2
135
+ Style/ClassVars:
136
+ Exclude:
137
+ - 'lib/payroll_hero/api/configuration.rb'
138
+
139
+ # Offense count: 7
140
+ # This cop supports unsafe autocorrection (--autocorrect-all).
141
+ Style/CommentedKeyword:
142
+ Exclude:
143
+ - 'lib/payroll_hero/api/errors.rb'
144
+
145
+ # Offense count: 7
146
+ # Configuration parameters: AllowedConstants.
147
+ Style/Documentation:
148
+ Exclude:
149
+ - 'spec/**/*'
150
+ - 'test/**/*'
151
+ - 'lib/payroll_hero/api.rb'
152
+ - 'lib/payroll_hero/api/base_group.rb'
153
+ - 'lib/payroll_hero/api/client.rb'
154
+ - 'lib/payroll_hero/api/configuration.rb'
155
+ - 'lib/payroll_hero/api/errors.rb'
156
+ - 'lib/payroll_hero/api/v4/schedule_events.rb'
157
+ - 'lib/payroll_hero/api/v4/shifts.rb'
158
+
159
+ # Offense count: 1
160
+ # This cop supports safe autocorrection (--autocorrect).
161
+ Style/Encoding:
162
+ Exclude:
163
+ - 'payroll_hero-api.gemspec'
164
+
165
+ # Offense count: 2
166
+ # This cop supports safe autocorrection (--autocorrect).
167
+ Style/ExpandPathArguments:
168
+ Exclude:
169
+ - 'payroll_hero-api.gemspec'
170
+ - 'spec/spec_helper.rb'
171
+
172
+ # Offense count: 1
173
+ # This cop supports safe autocorrection (--autocorrect).
174
+ Style/ExplicitBlockArgument:
175
+ Exclude:
176
+ - 'lib/payroll_hero/api/client.rb'
177
+
178
+ # Offense count: 29
179
+ # This cop supports unsafe autocorrection (--autocorrect-all).
180
+ # Configuration parameters: EnforcedStyle.
181
+ # SupportedStyles: always, always_true, never
182
+ Style/FrozenStringLiteralComment:
183
+ Enabled: false
184
+
185
+ # Offense count: 1
186
+ # This cop supports safe autocorrection (--autocorrect).
187
+ # Configuration parameters: MinBodyLength, AllowConsecutiveConditionals.
188
+ Style/GuardClause:
189
+ Exclude:
190
+ - 'lib/payroll_hero/api/client.rb'
191
+
192
+ # Offense count: 1
193
+ # This cop supports safe autocorrection (--autocorrect).
194
+ # Configuration parameters: EnforcedStyle, EnforcedShorthandSyntax, UseHashRocketsWithSymbolValues, PreferHashRocketsForNonAlnumEndingSymbols.
195
+ # SupportedStyles: ruby19, hash_rockets, no_mixed_keys, ruby19_no_mixed_keys
196
+ # SupportedShorthandSyntax: always, never, either, consistent
197
+ Style/HashSyntax:
198
+ Exclude:
199
+ - 'Rakefile'
200
+
201
+ # Offense count: 1
202
+ # This cop supports safe autocorrection (--autocorrect).
203
+ Style/IfUnlessModifier:
204
+ Exclude:
205
+ - 'spec/spec_helper.rb'
206
+
207
+ # Offense count: 1
208
+ # This cop supports unsafe autocorrection (--autocorrect-all).
209
+ # Configuration parameters: EnforcedStyle.
210
+ # SupportedStyles: literals, strict
211
+ Style/MutableConstant:
212
+ Exclude:
213
+ - 'lib/payroll_hero/api/version.rb'
214
+
215
+ # Offense count: 5
216
+ # This cop supports safe autocorrection (--autocorrect).
217
+ # Configuration parameters: PreferredDelimiters.
218
+ Style/PercentLiteralDelimiters:
219
+ Exclude:
220
+ - 'payroll_hero-api.gemspec'
221
+ - 'spec/payroll_hero/v4_employees_spec.rb'
222
+ - 'spec/payroll_hero/v4_leaves_spec.rb'
223
+
224
+ # Offense count: 1
225
+ # This cop supports safe autocorrection (--autocorrect).
226
+ Style/RedundantParentheses:
227
+ Exclude:
228
+ - 'spec/payroll_hero/v4_leaves_spec.rb'
229
+
230
+ # Offense count: 2
231
+ # This cop supports safe autocorrection (--autocorrect).
232
+ Style/RedundantPercentQ:
233
+ Exclude:
234
+ - 'payroll_hero-api.gemspec'
235
+
236
+ # Offense count: 1
237
+ # This cop supports safe autocorrection (--autocorrect).
238
+ # Configuration parameters: AllowMultipleReturnValues.
239
+ Style/RedundantReturn:
240
+ Exclude:
241
+ - 'lib/payroll_hero/api/client.rb'
242
+
243
+ # Offense count: 19
244
+ # This cop supports safe autocorrection (--autocorrect).
245
+ # Configuration parameters: EnforcedStyle, ConsistentQuotesInMultiline.
246
+ # SupportedStyles: single_quotes, double_quotes
247
+ Style/StringLiterals:
248
+ Exclude:
249
+ - 'Rakefile'
250
+ - 'lib/payroll_hero/api/v2/worksites.rb'
251
+ - 'lib/payroll_hero/api/v3/attendance_days.rb'
252
+ - 'lib/payroll_hero/api/v3/day_schedules.rb'
253
+ - 'lib/payroll_hero/api/v4/employees.rb'
254
+ - 'lib/payroll_hero/api/v4/leaves.rb'
255
+ - 'lib/payroll_hero/api/v4/permissions.rb'
256
+ - 'lib/payroll_hero/api/version.rb'
257
+ - 'spec/payroll_hero/api_spec.rb'
258
+ - 'spec/payroll_hero/v4_employees_spec.rb'
259
+ - 'spec/spec_helper.rb'
260
+
261
+ # Offense count: 10
262
+ # This cop supports safe autocorrection (--autocorrect).
263
+ # Configuration parameters: EnforcedStyleForMultiline.
264
+ # SupportedStylesForMultiline: comma, consistent_comma, no_comma
265
+ Style/TrailingCommaInHashLiteral:
266
+ Exclude:
267
+ - 'lib/payroll_hero/api.rb'
268
+ - 'lib/payroll_hero/api/client.rb'
269
+ - 'lib/payroll_hero/api/v2/worksites.rb'
270
+ - 'lib/payroll_hero/api/v3/attendance_days.rb'
271
+ - 'lib/payroll_hero/api/v3/day_schedules.rb'
272
+ - 'lib/payroll_hero/api/v3/employees.rb'
273
+
274
+ # Offense count: 4
275
+ # This cop supports safe autocorrection (--autocorrect).
276
+ # Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, AllowedPatterns, IgnoredPatterns.
277
+ # URISchemes: http, https
278
+ Layout/LineLength:
279
+ Max: 172
data/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # Change Log
2
2
 
3
+ ## [v1.3.0](https://github.com/payrollhero/payroll_hero-api/tree/v1.3.0) (2022-11-21)
4
+ [Full Changelog](https://github.com/payrollhero/payroll_hero-api/compare/v1.2.7...v1.3.0)
5
+
6
+ - Official support for Ruby 3.0 and 3.1
7
+ - Setup running rspec testing on Github Actions
8
+ - Setup running rubocop and rubocop challenger automatically as well
9
+
3
10
  ## [v1.2.7](https://github.com/payrollhero/payroll_hero-api/tree/v1.2.7) (2021-12-16)
4
11
  [Full Changelog](https://github.com/payrollhero/payroll_hero-api/compare/v1.2.6...v1.2.7)
5
12
 
@@ -1,5 +1,5 @@
1
1
  module PayrollHero
2
2
  module Api
3
- VERSION = "1.2.7"
3
+ VERSION = "1.3.0"
4
4
  end
5
5
  end
@@ -27,6 +27,7 @@ Gem::Specification.new do |spec|
27
27
  spec.add_development_dependency 'bundler'
28
28
  spec.add_development_dependency 'rake', '~> 10.0'
29
29
  spec.add_development_dependency 'rspec'
30
+ spec.add_development_dependency 'rubocop'
30
31
  spec.add_development_dependency 'vcr'
31
32
  spec.add_development_dependency 'webmock'
32
33
  spec.add_development_dependency 'rack', '< 2.0.0' # requires ruby >= 2.2.2 for 2.0
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: payroll_hero-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.7
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Piotr Banasik
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-12-16 00:00:00.000000000 Z
11
+ date: 2022-11-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -108,6 +108,20 @@ dependencies:
108
108
  - - ">="
109
109
  - !ruby/object:Gem::Version
110
110
  version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: rubocop
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
111
125
  - !ruby/object:Gem::Dependency
112
126
  name: vcr
113
127
  requirement: !ruby/object:Gem::Requirement
@@ -172,8 +186,12 @@ executables: []
172
186
  extensions: []
173
187
  extra_rdoc_files: []
174
188
  files:
189
+ - ".github/workflows/ci.yml"
190
+ - ".github/workflows/rubocop-challenger.yml"
175
191
  - ".gitignore"
176
192
  - ".rspec"
193
+ - ".rubocop.yml"
194
+ - ".rubocop_todo.yml"
177
195
  - CHANGELOG.md
178
196
  - DEPLOYING.md
179
197
  - Gemfile
@@ -200,7 +218,7 @@ homepage: http://github.com/payrollhero/
200
218
  licenses:
201
219
  - MIT
202
220
  metadata: {}
203
- post_install_message:
221
+ post_install_message:
204
222
  rdoc_options: []
205
223
  require_paths:
206
224
  - lib
@@ -215,8 +233,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
215
233
  - !ruby/object:Gem::Version
216
234
  version: '0'
217
235
  requirements: []
218
- rubygems_version: 3.0.9
219
- signing_key:
236
+ rubygems_version: 3.4.0.dev
237
+ signing_key:
220
238
  specification_version: 4
221
239
  summary: Ruby API Client for PayrollHero Apis
222
240
  test_files: []