Sha256: 8b536ab9df0d5d9b33e3fae0cc1a5038e04b254611280f2d77fa681f7d25f2ef
Contents?: true
Size: 1.08 KB
Versions: 21
Compression:
Stored size: 1.08 KB
Contents
require 'dummy_spec_helper' feature "Concertos", %q{ In order to have an awesome musical pages As an user having role_groups 'composers' I want to do something with concertos (According to role_groups) } do background do Concerto.create!(:title => 'one') Concerto.create!(:title => 'two') @composer = Admin.create!(:name => 'composer', :role_groups => 'composers', :email => 'stanislaw@mail.ru') @musician = User.create! :name => 'musician', :role_groups => 'musicians', :email => 'editor@mail.ru' end scenario "Concerto index" do visit '/concertos' page.should have_content('one') page.should have_content('two') end scenario "Show concerto to composer" do visit '/login_user/composer' visit '/concertos/one' # using friendly id :) page.should have_content('one') visit '/concertos/two' page.should have_content('two') end scenario "Show concerto to musician" do visit '/login_user/musician' visit '/concertos/one' # using friendly id :) page.should have_content('one') #page.should have_content('two') end end
Version data entries
21 entries across 21 versions & 1 rubygems