Sha256: e8be78f9ebb3866e9eeb06fd9dbd64aab2c3c33c9d7efdf31ac302f16af102f3
Contents?: true
Size: 550 Bytes
Versions: 30
Compression:
Stored size: 550 Bytes
Contents
require "spec_helper" describe Blogit::Blogs do it "should be included in ActiveRecord::Base" do ActiveRecord::Base.included_modules.should include(Blogit::Blogs) end describe :blogs do it "should be a class macro to AR Base" do ActiveRecord::Base.methods.should include(:blogs) end it "should build a hm assosciation on the model it's called in" do lambda { User.new.blog_posts }.should_not raise_exception(NoMethodError) User.new.blog_posts.should be_an(Array) end end end
Version data entries
30 entries across 30 versions & 1 rubygems