summaryrefslogtreecommitdiff
path: root/spec/views/matches/new.html.erb_spec.rb
blob: c3537dcc19f3d3702f8a11de8dda001aa32a7a32 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
require 'spec_helper'

describe "matches/new" do
  before(:each) do
    assign(:match, stub_model(Match,
      :tournament => nil
    ).as_new_record)
  end

  it "renders new match form" do
    render

    # Run the generator again with the --webrat flag if you want to use webrat matchers
    assert_select "form[action=?][method=?]", matches_path, "post" do
      assert_select "input#match_tournament[name=?]", "match[tournament]"
    end
  end
end