Sha256: e4f933488d6c5f6970ff35fd932b842ae018454a993e27673e99054aae7cf8c4

Contents?: true

Size: 538 Bytes

Versions: 1

Compression:

Stored size: 538 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/../../../spec_helper')

describe 'rails view helper' do
  load_helper :view

  before :each do              
    create_view :account, :edit do
      %q{
        <h1><%= title %></h1>
      }
    end    
  end

  after :each do              
    remove_view :account, :edit
  end
    
  it "should have an account/edit view file that displays a title" do      
    Rails.application.should have_view :account, :edit do |file|
      file.should match /<%=\s*title\s*%>/
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
generator-spec-0.5.0 spec/generator_spec/matchers/rails/view_matcher_spec.rb