lib/rubocop/cop/rspec/example_wording.rb in rubocop-rspec-2.5.0 vs lib/rubocop/cop/rspec/example_wording.rb in rubocop-rspec-2.6.0
- old
+ new
@@ -58,10 +58,13 @@
private
def add_wording_offense(node, message)
docstring = docstring(node)
+
add_offense(docstring, message: message) do |corrector|
+ next if node.heredoc?
+
corrector.replace(docstring, replacement_text(node))
end
end
def docstring(node)