Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'ruby/spec/lib/gitlab/git/repository_spec.rb')
-rw-r--r--ruby/spec/lib/gitlab/git/repository_spec.rb47
1 files changed, 0 insertions, 47 deletions
diff --git a/ruby/spec/lib/gitlab/git/repository_spec.rb b/ruby/spec/lib/gitlab/git/repository_spec.rb
index ff2e84564..70899d4c7 100644
--- a/ruby/spec/lib/gitlab/git/repository_spec.rb
+++ b/ruby/spec/lib/gitlab/git/repository_spec.rb
@@ -304,53 +304,6 @@ describe Gitlab::Git::Repository do # rubocop:disable Metrics/BlockLength
end
end
- describe '#ff_merge' do
- let(:repository) { mutable_repository }
- let(:branch_head) { '6d394385cf567f80a8fd85055db1ab4c5295806f' }
- let(:source_sha) { 'cfe32cf61b73a0d5e9f13e774abde7ff789b1660' }
- let(:target_branch) { 'test-ff-target-branch' }
-
- before do
- create_branch(repository, target_branch, branch_head)
- end
-
- subject { repository.ff_merge(user, source_sha, target_branch) }
-
- it 'performs a ff_merge' do
- expect(subject.newrev).to eq(source_sha)
- expect(subject.repo_created).to be(false)
- expect(subject.branch_created).to be(false)
-
- expect(repository.commit(target_branch).id).to eq(source_sha)
- end
-
- context 'with a non-existing target branch' do
- subject { repository.ff_merge(user, source_sha, 'this-isnt-real') }
-
- it 'throws an ArgumentError' do
- expect { subject }.to raise_error(ArgumentError)
- end
- end
-
- context 'with a non-existing source commit' do
- let(:source_sha) { 'f001' }
-
- it 'throws an ArgumentError' do
- expect { subject }.to raise_error(ArgumentError)
- end
- end
-
- context 'when the source sha is not a descendant of the branch head' do
- let(:source_sha) { '1a0b36b3cdad1d2ee32457c102a8c0b7056fa863' }
-
- it "doesn't perform the ff_merge" do
- expect { subject }.to raise_error(Gitlab::Git::CommitError)
-
- expect(repository.commit(target_branch).id).to eq(branch_head)
- end
- end
- end
-
describe 'remotes' do
let(:repository) { mutable_repository }
let(:remote_name) { 'my-remote' }