diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-06-18 14:18:50 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-06-18 14:18:50 +0300 |
commit | 8c7f4e9d5f36cff46365a7f8c4b9c21578c1e781 (patch) | |
tree | a77e7fe7a93de11213032ed4ab1f33a3db51b738 /spec/lib/gitlab/gon_helper_spec.rb | |
parent | 00b35af3db1abfe813a778f643dad221aad51fca (diff) |
Add latest changes from gitlab-org/gitlab@13-1-stable-ee
Diffstat (limited to 'spec/lib/gitlab/gon_helper_spec.rb')
-rw-r--r-- | spec/lib/gitlab/gon_helper_spec.rb | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/spec/lib/gitlab/gon_helper_spec.rb b/spec/lib/gitlab/gon_helper_spec.rb index 1ff2334bacf..7b0e0d01257 100644 --- a/spec/lib/gitlab/gon_helper_spec.rb +++ b/spec/lib/gitlab/gon_helper_spec.rb @@ -12,21 +12,19 @@ describe Gitlab::GonHelper do describe '#push_frontend_feature_flag' do it 'pushes a feature flag to the frontend' do gon = instance_double('gon') + thing = stub_feature_flag_gate('thing') + + stub_feature_flags(my_feature_flag: thing) allow(helper) .to receive(:gon) .and_return(gon) - expect(Feature) - .to receive(:enabled?) - .with(:my_feature_flag, 10) - .and_return(true) - expect(gon) .to receive(:push) .with({ features: { 'myFeatureFlag' => true } }, true) - helper.push_frontend_feature_flag(:my_feature_flag, 10) + helper.push_frontend_feature_flag(:my_feature_flag, thing) end end |