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:
authorJames Lopez <james@jameslopez.es>2016-12-01 17:40:46 +0300
committerJames Lopez <james@jameslopez.es>2017-01-17 13:32:55 +0300
commitdaa4f3ded718f4144877b7f0402bd495151c28de (patch)
treec9fdc94111f9f27d4faddae666824fc2e0329cd8 /spec/lib/gitlab/cycle_analytics
parent58dddcdfed6212046447de8b6d304ffd463d0350 (diff)
fix spec failures after merge
Diffstat (limited to 'spec/lib/gitlab/cycle_analytics')
-rw-r--r--spec/lib/gitlab/cycle_analytics/plan_event_spec.rb2
-rw-r--r--spec/lib/gitlab/cycle_analytics/shared_event_spec.rb2
-rw-r--r--spec/lib/gitlab/cycle_analytics/shared_stage_spec.rb6
3 files changed, 5 insertions, 5 deletions
diff --git a/spec/lib/gitlab/cycle_analytics/plan_event_spec.rb b/spec/lib/gitlab/cycle_analytics/plan_event_spec.rb
index 5c4b8b343bd..df407e51c64 100644
--- a/spec/lib/gitlab/cycle_analytics/plan_event_spec.rb
+++ b/spec/lib/gitlab/cycle_analytics/plan_event_spec.rb
@@ -11,7 +11,7 @@ describe Gitlab::CycleAnalytics::PlanEvent do
context 'no commits' do
it 'does not blow up if there are no commits' do
- allow_any_instance_of(Gitlab::CycleAnalytics::EventsQuery).to receive(:execute).and_return([{}])
+ allow_any_instance_of(Gitlab::CycleAnalytics::MetricsFetcher).to receive(:events).and_return([{}])
expect { event.fetch }.not_to raise_error
end
diff --git a/spec/lib/gitlab/cycle_analytics/shared_event_spec.rb b/spec/lib/gitlab/cycle_analytics/shared_event_spec.rb
index 0b0ea662b74..5e1c7531fb5 100644
--- a/spec/lib/gitlab/cycle_analytics/shared_event_spec.rb
+++ b/spec/lib/gitlab/cycle_analytics/shared_event_spec.rb
@@ -7,7 +7,7 @@ shared_examples 'default query config' do
branch: nil)
end
- let(:event) { described_class.new(fetcher: fetcher, stage: stage_name, options: {}) }
+ let(:event) { described_class.new(fetcher: fetcher, options: {}) }
it 'has the start attributes' do
expect(event.start_time_attrs).not_to be_nil
diff --git a/spec/lib/gitlab/cycle_analytics/shared_stage_spec.rb b/spec/lib/gitlab/cycle_analytics/shared_stage_spec.rb
index f4189d3c7fc..cfb5dc12ff1 100644
--- a/spec/lib/gitlab/cycle_analytics/shared_stage_spec.rb
+++ b/spec/lib/gitlab/cycle_analytics/shared_stage_spec.rb
@@ -1,7 +1,7 @@
require 'spec_helper'
shared_examples 'base stage' do
- let(:stage) { described_class.new(project: double, options: {}, stage: stage_name) }
+ let(:stage) { described_class.new(project: double, options: {}) }
before do
allow_any_instance_of(Gitlab::CycleAnalytics::MetricsFetcher).to receive(:median).and_return(1.12)
@@ -20,8 +20,8 @@ shared_examples 'base stage' do
expect(stage.median_data[:description]).not_to be_nil
end
- it 'has the stage' do
- expect(stage.stage).to eq(stage_name)
+ it 'has the title' do
+ expect(stage.title).to eq(stage_name.to_s.capitalize)
end
it 'has the events' do