Sha256: e6c693a8ed3448025579b6acea40d74abef57bc1f6d430d361b3acf2dbf0941a

Contents?: true

Size: 753 Bytes

Versions: 21

Compression:

Stored size: 753 Bytes

Contents

require 'spec_helper'

describe "accepts/new" do
  before(:each) do
    assign(:accept, stub_model(Accept,
      :item_id => 1
    ).as_new_record)
    assign(:basket, FactoryGirl.create(:basket))
    assign(:accepts, [
      stub_model(Accept,
        :item_id => 1,
        :created_at => Time.zone.now
      ),
      stub_model(Accept,
        :item_id => 1,
        :created_at => Time.zone.now
      )
    ].paginate(: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

21 entries across 21 versions & 1 rubygems

Version Path
enju_circulation-0.0.71 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.70 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.69 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.68 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.67 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.66 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.65 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.64 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.63 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.62 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.61 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.60 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.59 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.58 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.57 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.56 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.55 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.54 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.53 spec/views/accepts/new.html.erb_spec.rb
enju_circulation-0.0.52 spec/views/accepts/new.html.erb_spec.rb