gitlabhq/spec/requests/commits_notes_spec.rb

29 lines
710 B
Ruby
Raw Normal View History

2011-10-08 23:36:38 +02:00
require 'spec_helper'
describe "Issues" do
let(:project) { Factory :project }
let!(:commit) { project.repo.commits.first }
before do
2011-10-08 23:36:38 +02:00
login_as :user
project.add_access(@user, :read, :write)
end
describe "add new note", :js => true do
before do
2011-10-08 23:36:38 +02:00
visit project_commit_path(project, commit)
fill_in "note_note", :with => "I commented this commit"
click_button "Add note"
end
it "should conatin new note" do
page.should have_content("I commented this commit")
end
2012-01-21 13:54:32 +01:00
it "should be displayed when i visit this commit again" do
visit project_commit_path(project, commit)
page.should have_content("I commented this commit")
end
2011-10-08 23:36:38 +02:00
end
end