Sha256: df14386dd0955cd68b652721a156a5ccb86a20307cd14b662ce4d13a659b79a9

Contents?: true

Size: 783 Bytes

Versions: 60

Compression:

Stored size: 783 Bytes

Contents

require 'spec_helper'

describe "accepts/new" do
  fixtures :all

  before(:each) do
    assign(:accept, stub_model(Accept,
      :item_id => 1
    ).as_new_record)
    assign(:basket, FactoryGirl.create(:basket))
    assign(:accepts, Kaminari::paginate_array([
      stub_model(Accept,
        :item_id => 1,
        :created_at => Time.zone.now
      ),
      stub_model(Accept,
        :item_id => 1,
        :created_at => Time.zone.now
      )
    ]).page(1))
  end

  it "renders new accept form" do
    render

    # Run the generator again with the --webrat flag if you want to use webrat matchers
    assert_select "form", :action => accepts_path, :method => "post" do
      assert_select "input#accept_item_identifier", :name => "accept[item_identifier]"
    end
  end
end

Version data entries

60 entries across 60 versions & 2 rubygems

Version Path
enju_library-0.1.0.pre36 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre35 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre34 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre33 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre32 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre31 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre30 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre29 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre28 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre27 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre26 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre25 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre24 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre23 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre22 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre21 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre20 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre19 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre18 spec/views/accepts/new.html.erb_spec.rb
enju_library-0.1.0.pre17 spec/views/accepts/new.html.erb_spec.rb