Skip to content

Instantly share code, notes, and snippets.

View robustdj's full-sized avatar

Derrick Camerino robustdj

View GitHub Profile
@robustdj
robustdj / video_spec.rb
Created November 1, 2010 23:52
video spec
require 'spec_helper'
describe Video do
describe :validations do
before { Factory(:video) }
it { should validate_presence_of :artist, :title, :link, :user_id }
it { should validate_uniqueness_of :link }
it { should validate_uniqueness_of :title, :scope => :artist, :message => "and Artist are not unique. This song has already been added." }
end