Skip to content
Snippets Groups Projects

Assign approvers based on code owners

Merged Mark Chao requested to merge 1012-assign-code-owner-as-approver into master
Compare and Show latest version
2 files
+ 6
5
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -620,7 +620,7 @@ def set_compare(merge_request)
describe '#touched_file_paths' do
subject(:merge_request) do
build(:merge_request, source_branch: 'create-delete-modify', target_branch: 'master')
build(:merge_request, source_branch: 'after-create-delete-modify-move', target_branch: 'before-create-delete-modify-move')
end
let(:diffs) { double(:diffs) }
@@ -634,7 +634,7 @@ def set_compare(merge_request)
context 'when ref is specified' do
it 'returns affected file paths from compare' do
expect(merge_request.touched_file_paths('884e755e7e40603703b028c47197fb37563a5ae4')).to eq(%w{files/html/500.html files/markdown/foo-style-guide.md files/markdown/ruby-style-guide.md})
expect(merge_request.touched_file_paths('3049d75cb3cf66c9558f538d02d68b8c051c9d52')).to eq(%w{foo/for_create.txt foo/for_delete.txt foo/for_edit.txt})
end
end
@@ -665,7 +665,7 @@ def set_compare(merge_request)
it 'returns affected file paths for tip of the source branch' do
merge_request.save
expect(merge_request.touched_file_paths).to eq(%w{bar/branch-test.txt baz/branch-test.txt files/html/500.html files/markdown/foo-style-guide.md files/markdown/ruby-style-guide.md})
expect(merge_request.touched_file_paths).to eq(%w{foo/for_move.txt foo/bar/for_move.txt foo/for_create.txt foo/for_delete.txt foo/for_edit.txt})
end
end
end
Loading