lib/rubocop/cop/rspec/expect_output.rb in rubocop-rspec-2.10.0 vs lib/rubocop/cop/rspec/expect_output.rb in rubocop-rspec-2.11.0
- old
+ new
@@ -22,10 +22,10 @@
return unless inside_example_scope?(node)
# rubocop:disable InternalAffairs/NodeDestructuring
variable_name, _rhs = *node
# rubocop:enable InternalAffairs/NodeDestructuring
- name = variable_name[1..-1]
+ name = variable_name[1..]
return unless name.eql?('stdout') || name.eql?('stderr')
add_offense(node.loc.name, message: format(MSG, name: name))
end