Skip to content

Instantly share code, notes, and snippets.

@oleander
Created June 22, 2011 13:08
Show Gist options
  • Select an option

  • Save oleander/1040058 to your computer and use it in GitHub Desktop.

Select an option

Save oleander/1040058 to your computer and use it in GitHub Desktop.
before :each do
@book = Factory(:book)
@pages = []
5.times { @pages << Factory(:page, :book => @book) }
end
it "should find the spread after" do
prev = Spread.next(Spread.find(@book, 2))
prev.left.should == @pages[3]
prev.right.should == @pages[4]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment