Skip to content

Commit a62055e

Browse files
authored
More Rubocop fixes (#149)
* Fix rubocop warnings * Remove JRuby
1 parent f83beec commit a62055e

File tree

3 files changed

+25
-26
lines changed

3 files changed

+25
-26
lines changed

README.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# ErrbitPlugin
22

33
[![RSpec](https://github.com/errbit/errbit_plugin/actions/workflows/rspec.yml/badge.svg)](https://github.com/errbit/errbit_plugin/actions/workflows/rspec.yml)
4-
[![RSpec on JRuby](https://github.com/errbit/errbit_plugin/actions/workflows/jruby.yml/badge.svg)](https://github.com/errbit/errbit_plugin/actions/workflows/jruby.yml)
54
[![Ruby Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://github.com/standardrb/standard)
65

76
ErrbitPlugin provides a set of base classes that you can extend to create
@@ -19,7 +18,7 @@ plugin you can create, and that is the issue tracker.
1918
### Issue Trackers
2019

2120
An issue tracker plugin is a Ruby class that enables you to link errors within
22-
errbit to an issue in an external issue tracker like Github. An app within
21+
errbit to an issue in an external issue tracker like GitHub. An app within
2322
errbit can be associated an issue tracker or not. When there is an association,
2423
errbit users can choose 'create issue' from an error page which will both
2524
create an issue on the external issue tracker out of the given error and link
@@ -133,4 +132,4 @@ end
133132
## Contributing
134133

135134
Discuss any changes you'd like to make with the authors on the mailing list, or
136-
by opening a github issue.
135+
by opening a GitHub issue.

lib/errbit_plugin/none_issue_tracker.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,11 @@ def url
4444
""
4545
end
4646

47-
def create_issue(*)
47+
def create_issue(*) # rubocop:disable Naming/PredicateMethod
4848
false
4949
end
5050

51-
def close_issue(*)
51+
def close_issue(*) # rubocop:disable Naming/PredicateMethod
5252
false
5353
end
5454
end

spec/errbit_plugin/issue_tracker_validator_spec.rb

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
RSpec.describe ErrbitPlugin::IssueTrackerValidator do
66
describe "#valid?" do
77
context "with a complete class" do
8-
klass = Class.new(ErrbitPlugin::IssueTracker) do
8+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
99
def self.label
1010
"foo"
1111
end
@@ -26,7 +26,7 @@ def configured?
2626
true
2727
end
2828

29-
def errors
29+
def errors # rubocop:disable Naming/PredicateMethod
3030
true
3131
end
3232

@@ -49,7 +49,7 @@ def url
4949
end
5050

5151
context "with class not inherit from ErrbitPlugin::IssueTracker" do
52-
klass = Class.new do
52+
klass = Class.new do # rubocop:disable RSpec/LeakyLocalVariable
5353
def self.label
5454
"foo"
5555
end
@@ -73,7 +73,7 @@ def configured?
7373
true
7474
end
7575

76-
def errors
76+
def errors # rubocop:disable Naming/PredicateMethod
7777
true
7878
end
7979

@@ -102,7 +102,7 @@ def url
102102
end
103103

104104
context "with no label method" do
105-
klass = Class.new(ErrbitPlugin::IssueTracker) do
105+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
106106
def self.note
107107
"foo"
108108
end
@@ -119,7 +119,7 @@ def configured?
119119
true
120120
end
121121

122-
def errors
122+
def errors # rubocop:disable Naming/PredicateMethod
123123
true
124124
end
125125

@@ -148,7 +148,7 @@ def url
148148
end
149149

150150
context "with no icons method" do
151-
klass = Class.new(ErrbitPlugin::IssueTracker) do
151+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
152152
def self.note
153153
"foo"
154154
end
@@ -165,7 +165,7 @@ def configured?
165165
true
166166
end
167167

168-
def errors
168+
def errors # rubocop:disable Naming/PredicateMethod
169169
true
170170
end
171171

@@ -194,7 +194,7 @@ def url
194194
end
195195

196196
context "without fields method" do
197-
klass = Class.new(ErrbitPlugin::IssueTracker) do
197+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
198198
def self.label
199199
"foo"
200200
end
@@ -211,7 +211,7 @@ def configured?
211211
true
212212
end
213213

214-
def errors
214+
def errors # rubocop:disable Naming/PredicateMethod
215215
true
216216
end
217217

@@ -240,7 +240,7 @@ def url
240240
end
241241

242242
context "without configured? method" do
243-
klass = Class.new(ErrbitPlugin::IssueTracker) do
243+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
244244
def self.label
245245
"foo"
246246
end
@@ -257,7 +257,7 @@ def self.icons
257257
{}
258258
end
259259

260-
def errors
260+
def errors # rubocop:disable Naming/PredicateMethod
261261
true
262262
end
263263

@@ -286,7 +286,7 @@ def url
286286
end
287287

288288
context "without errors method" do
289-
klass = Class.new(ErrbitPlugin::IssueTracker) do
289+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
290290
def self.label
291291
"foo"
292292
end
@@ -332,7 +332,7 @@ def url
332332
end
333333

334334
context "without create_issue method" do
335-
klass = Class.new(ErrbitPlugin::IssueTracker) do
335+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
336336
def self.label
337337
"foo"
338338
end
@@ -353,7 +353,7 @@ def configured?
353353
true
354354
end
355355

356-
def errors
356+
def errors # rubocop:disable Naming/PredicateMethod
357357
true
358358
end
359359

@@ -379,7 +379,7 @@ def url
379379

380380
context "without close_issue method" do
381381
# this is an optional method
382-
klass = Class.new(ErrbitPlugin::IssueTracker) do
382+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
383383
def self.label
384384
"foo"
385385
end
@@ -400,7 +400,7 @@ def configured?
400400
true
401401
end
402402

403-
def errors
403+
def errors # rubocop:disable Naming/PredicateMethod
404404
true
405405
end
406406

@@ -425,7 +425,7 @@ def url
425425
end
426426

427427
context "without url method" do
428-
klass = Class.new(ErrbitPlugin::IssueTracker) do
428+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
429429
def self.label
430430
"foo"
431431
end
@@ -446,7 +446,7 @@ def configured?
446446
true
447447
end
448448

449-
def errors
449+
def errors # rubocop:disable Naming/PredicateMethod
450450
true
451451
end
452452

@@ -471,7 +471,7 @@ def close_issue
471471
end
472472

473473
context "without note method" do
474-
klass = Class.new(ErrbitPlugin::IssueTracker) do
474+
klass = Class.new(ErrbitPlugin::IssueTracker) do # rubocop:disable RSpec/LeakyLocalVariable
475475
def self.label
476476
"foo"
477477
end
@@ -488,7 +488,7 @@ def configured?
488488
true
489489
end
490490

491-
def errors
491+
def errors # rubocop:disable Naming/PredicateMethod
492492
true
493493
end
494494

0 commit comments

Comments
 (0)