Sha256: 9de110754b790ad027133e42ff7cfdecdc706f3541a82a9d9308ac047b56842d
Contents?: true
Size: 633 Bytes
Versions: 3
Compression:
Stored size: 633 Bytes
Contents
# Run Capybara Spec on Dummy app PostsController require 'dummy_spec_helper' feature 'show list of items' do let(:names) { ['Item 1', 'Item 2'] } let(:name) { names.first } before :each do names.each{|n| Item.new n } visit items_path end context '2 items' do scenario 'display item 1 and 2' do page.should have_content names.first page.should have_content names.last end end end feature 'show item' do let(:name) { 'Item 1' } before do Item.new name end scenario 'display one item' do visit item_path(1) page.should have_content "A very nice #{name}" end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
context_exposer-0.4.1 | spec/app/items_spec.rb |
context_exposer-0.4.0 | spec/app/items_spec.rb |
context_exposer-0.3.0 | spec/app/items_spec.rb |