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

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Drozdov <idrozdov@gitlab.com>2019-06-18 17:20:11 +0300
committerIgor Drozdov <idrozdov@gitlab.com>2019-06-28 16:22:35 +0300
commitca5cd7b7fb5108d30d0f6b74e31da736024592dd (patch)
treeaec9468afa579b128b7e09f6e78e7357d6413b85 /spec/finders
parent546355f734f74c040d0ef0917ade50751fd90731 (diff)
Add endpoint for fetching diverging commit counts
Extract diverging_commit_counts into a service class
Diffstat (limited to 'spec/finders')
-rw-r--r--spec/finders/branches_finder_spec.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/spec/finders/branches_finder_spec.rb b/spec/finders/branches_finder_spec.rb
index 7d164539d9a..3fc86f3e408 100644
--- a/spec/finders/branches_finder_spec.rb
+++ b/spec/finders/branches_finder_spec.rb
@@ -62,6 +62,15 @@ describe BranchesFinder do
expect(result.count).to eq(0)
end
+
+ it 'filters branches by provided names' do
+ branches_finder = described_class.new(repository, { names: ['fix', 'csv', 'lfs', 'does-not-exist'] })
+
+ result = branches_finder.execute
+
+ expect(result.count).to eq(3)
+ expect(result.map(&:name)).to eq(%w{csv fix lfs})
+ end
end
context 'filter and sort' do