"storage/myisam/myisamchk.c" did not exist on "a8ea31fae6737c453d2dd9719a75f905c06048b3"
Commit 15914001 authored by Luke "Jared" Bennett's avatar Luke "Jared" Bennett

Separate examples for each other

parent 7e525015
require 'spec_helper'
describe 'Discussion Comments Merge Request', :feature, :js do
include RepoHelpers
let(:user) { create(:user) }
let(:project) { create(:project) }
let(:merge_request) { create(:merge_request, source_project: project) }
before do
project.add_master(user)
login_as(user)
visit namespace_project_commit_path(project.namespace, project, sample_commit.id)
end
it_behaves_like 'discussion comments', 'commit'
end
require 'spec_helper'
describe 'Discussion Comments Issue', :feature, :js do
let(:user) { create(:user) }
let(:project) { create(:empty_project) }
let(:issue) { create(:issue, project: project) }
before do
project.add_master(user)
login_as(user)
visit namespace_project_issue_path(project.namespace, project, issue)
end
it_behaves_like 'discussion comments', 'issue'
end
require 'spec_helper'
describe 'Discussion Comments Merge Request', :feature, :js do
let(:user) { create(:user) }
let(:project) { create(:project) }
let(:merge_request) { create(:merge_request, source_project: project) }
before do
project.add_master(user)
login_as(user)
visit namespace_project_merge_request_path(project.namespace, project, merge_request)
end
it_behaves_like 'discussion comments', 'merge request'
end
require 'spec_helper'
describe 'Discussion Comments Issue', :feature, :js do
let(:user) { create(:user) }
let(:project) { create(:empty_project) }
let(:snippet) { create(:project_snippet, :private, project: project, author: user) }
before do
project.add_master(user)
login_as(user)
visit namespace_project_snippet_path(project.namespace, project, snippet)
end
it_behaves_like 'discussion comments', 'snippet'
end
require 'spec_helper'
shared_examples 'discussion comments' do |resource_name|
let(:form_selector) { '.js-main-target-form' }
let(:dropdown_selector) { "#{form_selector} .comment-type-dropdown" }
......@@ -213,65 +211,3 @@ shared_examples 'discussion comments' do |resource_name|
end
end
end
describe 'Discussion Comments', :feature, :js do
include RepoHelpers
let(:user) { create(:user) }
describe 'on a merge request' do
let(:project) { create(:project) }
let(:merge_request) { create(:merge_request, source_project: project) }
before do
login
visit namespace_project_merge_request_path(project.namespace, project, merge_request)
end
it_behaves_like 'discussion comments', 'merge request'
end
describe 'on an issue' do
let(:project) { create(:empty_project) }
let(:issue) { create(:issue, project: project) }
before do
login
visit namespace_project_issue_path(project.namespace, project, issue)
end
it_behaves_like 'discussion comments', 'issue'
end
describe 'on an snippet' do
let(:project) { create(:empty_project) }
let(:snippet) { create(:project_snippet, :private, project: project, author: user) }
before do
login
visit namespace_project_snippet_path(project.namespace, project, snippet)
end
it_behaves_like 'discussion comments', 'snippet'
end
describe 'on a commit' do
let(:project) { create(:project) }
before do
login
visit namespace_project_commit_path(project.namespace, project, sample_commit.id)
end
it_behaves_like 'discussion comments', 'commit'
end
def login
project.add_master(user)
login_as(user)
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment