Sha256: c4bfff4fca7e51fe6574a680d8a94ba72dd9279a274e101a964ddadc1c0580a6
Contents?: true
Size: 795 Bytes
Versions: 2
Compression:
Stored size: 795 Bytes
Contents
require 'spec_helper' feature 'decorating controller ivar' do background do @matz = Author.create! :name => 'matz' Author.create! :name => 'takahashim' end after do Author.delete_all end scenario 'decorating a model object in ivar' do visit "/authors/#{@matz.id}" page.should have_content 'matz' page.should have_content 'matz'.capitalize end scenario 'decorating model scope in ivar' do visit '/authors' page.should have_content 'takahashim' page.should have_content 'takahashim'.reverse page.should have_selector 'a[title="takahashim"]' end scenario "decorating models' array in ivar" do visit '/authors?variable_type=array' page.should have_content 'takahashim' page.should have_content 'takahashim'.reverse end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
r_decorator-0.0.4 | spec/features/controller_ivar_spec.rb |
r_decorator-0.0.3 | spec/features/controller_ivar_spec.rb |