Class: RuboCop::Cop::RSpec::Rails::HttpStatus::SymbolicStyleChecker
- Inherits:
-
StyleCheckerBase
- Object
- StyleCheckerBase
- RuboCop::Cop::RSpec::Rails::HttpStatus::SymbolicStyleChecker
- Defined in:
- lib/rubocop/cop/rspec/rails/http_status.rb
Overview
:nodoc:
Constant Summary
Constants inherited from StyleCheckerBase
RuboCop::Cop::RSpec::Rails::HttpStatus::StyleCheckerBase::ALLOWED_STATUSES, RuboCop::Cop::RSpec::Rails::HttpStatus::StyleCheckerBase::MSG
Instance Attribute Summary
Attributes inherited from StyleCheckerBase
Instance Method Summary collapse
Methods inherited from StyleCheckerBase
#allowed_symbol?, #custom_http_status_code?, #initialize, #message, #offense_range
Constructor Details
This class inherits a constructor from RuboCop::Cop::RSpec::Rails::HttpStatus::StyleCheckerBase
Instance Method Details
#current ⇒ Object
126 127 128 |
# File 'lib/rubocop/cop/rspec/rails/http_status.rb', line 126 def current number.inspect end |
#offensive? ⇒ Boolean
118 119 120 |
# File 'lib/rubocop/cop/rspec/rails/http_status.rb', line 118 def offensive? !node.sym_type? && !custom_http_status_code? end |
#prefer ⇒ Object
122 123 124 |
# File 'lib/rubocop/cop/rspec/rails/http_status.rb', line 122 def prefer symbol.inspect end |