Sha256: fa25ccef7cae0d6a5d14ce36ff870667c277d61c620f683b37368061a692167a

Contents?: true

Size: 350 Bytes

Versions: 7

Compression:

Stored size: 350 Bytes

Contents

require 'spec_helper'

describe Draper::HelperProxy do
  subject(:helper_proxy) { Draper::HelperProxy.new }
  let(:view_context) { Object.new }
  before { helper_proxy.stub(:view_context).and_return(view_context) }

  it "proxies methods to the view context" do
    view_context.should_receive(:foo).with("bar")
    helper_proxy.foo("bar")
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
draper-1.0.0 spec/draper/helper_proxy_spec.rb
draper-1.0.0.beta6 spec/draper/helper_proxy_spec.rb
draper-1.0.0.beta5 spec/draper/helper_proxy_spec.rb
draper-1.0.0.beta4 spec/draper/helper_proxy_spec.rb
draper-1.0.0.beta3 spec/draper/helper_proxy_spec.rb
draper-1.0.0.beta2 spec/draper/helper_proxy_spec.rb
draper-1.0.0.beta1 spec/draper/helper_proxy_spec.rb