Skip to content

Commit

Permalink
Merge pull request #1084 from rspec/remove_string_eval
Browse files Browse the repository at this point in the history
Remove a stray string eval @xaviershay reported in #862
  • Loading branch information
JonRowe committed Sep 24, 2013
2 parents badcbe5 + 70049d1 commit 3091424
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions lib/rspec/core/shared_context.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,9 @@ def playback_onto(group)
# @api private
def self.record(methods)
methods.each do |meth|
class_eval <<-EOS, __FILE__, __LINE__ + 1
def #{meth}(*args, &block)
__shared_context_recordings << Recording.new(:#{meth}, args, block)
end
EOS
define_method(meth) do |*args, &block|
__shared_context_recordings << Recording.new(meth, args, block)
end
end
end

Expand Down

0 comments on commit 3091424

Please sign in to comment.