spec/draper/helper_proxy_spec.rb in draper-3.0.0.pre1 vs spec/draper/helper_proxy_spec.rb in draper-3.0.0

- old
+ new

@@ -16,18 +16,18 @@ it "proxies methods to the view context" do view_context = double helper_proxy = HelperProxy.new(view_context) - view_context.stub(:foo) { |arg| arg } + allow(view_context).to receive(:foo) { |arg| arg } expect(helper_proxy.foo(:passed)).to be :passed end it "passes blocks" do view_context = double helper_proxy = HelperProxy.new(view_context) - view_context.stub(:foo) { |&block| block.call } + allow(view_context).to receive(:foo) { |&block| block.call } expect(helper_proxy.foo{:yielded}).to be :yielded end it "defines the method for better performance" do helper_proxy = HelperProxy.new(double(foo: "bar"))