Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More Rubocop Updates #20

Merged
merged 4 commits into from
Apr 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
test:
strategy:
matrix:
ruby-version: ['2.6', '2.7', '3.0', '3.1', '3.2', '3.3', 'jruby', 'truffleruby']
ruby-version: ['2.7', '3.0', '3.1', '3.2', '3.3', 'jruby', 'truffleruby']
platform: [ubuntu-latest, macos-latest, windows-latest]
exclude:
- ruby-version: truffleruby
Expand Down
6 changes: 5 additions & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ RSpec/InstanceVariable:
Enabled: false
RSpec/BeforeAfterAll:
Enabled: false
RSpec/SpecFilePathFormat:
Enabled: false

AllCops:
NewCops: enable
Expand All @@ -20,6 +22,8 @@ AllCops:
- examples/*.rb
Lint/AssignmentInCondition:
Enabled: false
Style/FetchEnvVar:
Enabled: false
Style/HashSyntax:
Enabled: false
Style/MethodCallWithoutArgsParentheses:
Expand All @@ -43,7 +47,7 @@ Layout/SpaceBeforeBlockBraces:
Metrics/AbcSize:
Enabled: false
Metrics/BlockLength:
IgnoredMethods: ['describe', 'context']
AllowedMethods: ['describe', 'context']
Metrics/ClassLength:
Enabled: false
Metrics/MethodLength:
Expand Down
2 changes: 1 addition & 1 deletion lib/sys/windows/uname.rb
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,7 @@ def self.parse_ms_date(str)
# String rather than a Fixnum/Bignum. This deals with that for now.
#
def self.convert(str)
return nil if str.nil? # Don't turn nil into 0
return nil if str.nil? # Don't turn nil into 0
str.to_i
end

Expand Down
6 changes: 3 additions & 3 deletions spec/sys_platform_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@
end

example 'the ARCH constant is defined' do
expect(Sys::Platform::ARCH).to be_kind_of(Symbol)
expect(Sys::Platform::ARCH).to be_a(Symbol)
end

example 'the OS constant is defined' do
expect(Sys::Platform::OS).to be_kind_of(Symbol)
expect(Sys::Platform::OS).to be_a(Symbol)
end

example 'the IMPL constant is defined' do
expect(Sys::Platform::IMPL).to be_kind_of(Symbol)
expect(Sys::Platform::IMPL).to be_a(Symbol)
end

example 'the IMPL returns an expected value on windows', :windows do
Expand Down
Loading
Loading