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:
Diffstat (limited to 'spec/experiments')
-rw-r--r--spec/experiments/application_experiment_spec.rb8
-rw-r--r--spec/experiments/concerns/project_commit_count_spec.rb2
2 files changed, 3 insertions, 7 deletions
diff --git a/spec/experiments/application_experiment_spec.rb b/spec/experiments/application_experiment_spec.rb
index 15b45099a06..13c12afc15d 100644
--- a/spec/experiments/application_experiment_spec.rb
+++ b/spec/experiments/application_experiment_spec.rb
@@ -8,13 +8,9 @@ RSpec.describe ApplicationExperiment, :experiment do
let(:context) { {} }
let(:feature_definition) { { name: 'namespaced_stub', type: 'experiment', default_enabled: false } }
- around do |example|
- Feature::Definition.definitions[:namespaced_stub] = Feature::Definition.new('namespaced_stub.yml', feature_definition)
- example.run
- Feature::Definition.definitions.delete(:namespaced_stub)
- end
-
before do
+ stub_feature_flag_definition(:namespaced_stub, feature_definition)
+
allow(application_experiment).to receive(:enabled?).and_return(true)
end
diff --git a/spec/experiments/concerns/project_commit_count_spec.rb b/spec/experiments/concerns/project_commit_count_spec.rb
index 5616f167cb4..f5969ad6241 100644
--- a/spec/experiments/concerns/project_commit_count_spec.rb
+++ b/spec/experiments/concerns/project_commit_count_spec.rb
@@ -33,7 +33,7 @@ RSpec.describe ProjectCommitCount do
allow(Gitlab::GitalyClient).to receive(:call).and_call_original
allow(Gitlab::GitalyClient).to receive(:call).with(anything, :commit_service, :count_commits, anything, anything).and_raise(e = StandardError.new('_message_'))
- expect(Gitlab::ErrorTracking).to receive(:track_exception).with(e, caller_info: :identifiable)
+ expect(Gitlab::ErrorTracking).to receive(:track_exception).with(e, { caller_info: :identifiable })
expect(subject).to eq(42)
end