Skip to content

Instantly share code, notes, and snippets.

@futurechimp
Created February 17, 2012 14:13
Show Gist options
  • Save futurechimp/1853647 to your computer and use it in GitHub Desktop.
Save futurechimp/1853647 to your computer and use it in GitHub Desktop.
require File.expand_path(File.dirname(__FILE__) + '/../test_config.rb')
describe "User Model" do
# Associations
#
it "has_many videos" do
v1 = Video.make
v2 = Video.make
user = User.make
user.videos << v1
user.videos << v2
assert_equal 2, user.videos.length
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment