Skip to content

Commit

Permalink
spec the branch reassociating
Browse files Browse the repository at this point in the history
  • Loading branch information
Rich Cavanaugh authored and Rich Cavanaugh committed Oct 18, 2009
1 parent 15635e7 commit 32b7d3d
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions spec/branch_spec.rb
Expand Up @@ -18,6 +18,18 @@ class Project
@project.should == @project.branch.branch_source
end

it "should always tie the branch to the correct version" do
b = @project.branch!
@project.revise!
prev = @project.find_revision(:last)
b.reload.branch_source.should == prev
end

it "should have branches" do
b = @project.branch!
@project.branches.size.should == 1
end

it "should branch without saving" do
@project.branch.should be_new_record
end
Expand Down

0 comments on commit 32b7d3d

Please sign in to comment.