Skip to content

Instantly share code, notes, and snippets.

@robotarmy

robotarmy/t.rb

Created Jun 15, 2010
Embed
What would you like to do?
describe ‘Fans Are Callable By Bands” do
it “band has a fan” do
a = Fan.create(:name => ‘Peter’ , :phone => ‘1231231’)
b = Band.find_by_name(’Rolling Stones’)
b.fans << a
b.save
a.reload
a.bands.should include b
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment