lib/rspec/dry-plugins.rb in dry-plugins-0.2.0 vs lib/rspec/dry-plugins.rb in dry-plugins-0.3.0
- old
+ new
@@ -37,14 +37,15 @@
end
def a_plugins_host(name: :ExamplePluginsHost, parent: nil, &block)
an_example_class(name: name, parent: parent) do
extend Dry::Plugins
- instance_exec(&block)
+ instance_exec(&block) if block_given?
end
end
end
end
end
+
RSpec.configure do |config|
config.include Dry::Plugins::RSpec
end