class RSpec::Core::SharedExampleGroupModule
group.
eval’d when the ‘SharedExampleGroupModule` instance is included in an example
The functionality is defined by the provided block, which is lazily
Represents some functionality that is shared with multiple example groups.
def included(klass)
Our definition evaluates the shared group block in the context of the
Ruby callback for when a module is included in another module is class.
def included(klass) inclusion_line = klass.metadata[:location] SharedExampleGroupInclusionStackFrame.with_frame(@description, inclusion_line) do klass.class_exec(&@definition) end end
def initialize(description, definition)
def initialize(description, definition) @description = description @definition = definition end
def inspect
def inspect "#<#{self.class.name} #{@description.inspect}>" end