Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require File.dirname(__FILE__) + '/../test_helper'
- class PageTest < Test::Unit::TestCase
- context "A page instance" do
- should "be able to have children" do
- assert_difference "Page.count", 1 do
- assert_difference "pages(:home).children.size", 1 do
- pages(:home).children.create(:title=>"Sign Up", :body=>"Sign up text!")
- end
- end
- end
- end
- end
Add Comment
Please, Sign In to add comment