New Feature: Git Blame for file
This commit is contained in:
parent
2e54ac17c5
commit
9cd8f7b082
9 changed files with 135 additions and 15 deletions
25
spec/requests/file_blame_spec.rb
Normal file
25
spec/requests/file_blame_spec.rb
Normal file
|
@ -0,0 +1,25 @@
|
|||
require 'spec_helper'
|
||||
|
||||
describe "Blame file" do
|
||||
before { login_as :user }
|
||||
|
||||
describe "GET /:projectname/:commit/blob/Gemfile" do
|
||||
before do
|
||||
@project = Factory :project
|
||||
@project.add_access(@user, :read)
|
||||
|
||||
visit tree_project_ref_path(@project, @project.root_ref, :path => "Gemfile")
|
||||
click_link "blame"
|
||||
end
|
||||
|
||||
it "should be correct path" do
|
||||
current_path.should == blame_file_project_ref_path(@project, @project.root_ref, :path => "Gemfile")
|
||||
end
|
||||
|
||||
it "should contain file view" do
|
||||
page.should have_content("rubygems.org")
|
||||
page.should have_content("Dmitriy Zaporozhets")
|
||||
page.should have_content("bc3735004cb Moving to rails 3.2")
|
||||
end
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue