Commit ec38adc4 authored by Kamil Trzciński's avatar Kamil Trzciński

Merge branch '296138-disable-pages_update_legacy_storage-feature-flag-on-gitlab-com' into 'master'

Remove pages_update_legacy_storage feature flag [RUN ALL RSPEC] [RUN AS-IF-FOSS]

See merge request gitlab-org/gitlab!60005
parents f4cdff49 c881c280
---
title: Remove pages_update_legacy_storage feature flag
merge_request: 60005
author:
type: added
---
name: pages_update_legacy_storage
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/50683
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/296138
milestone: '13.9'
type: development
group: group::release
default_enabled: true
......@@ -11,10 +11,6 @@ module Gitlab
super
end
def local_store
@local_store ||= ::Gitlab::Pages::Stores::LocalStore.new(super)
end
private
def disk_access_denied?
......
# frozen_string_literal: true
module Gitlab
module Pages
module Stores
class LocalStore < ::SimpleDelegator
def enabled
return false unless Feature.enabled?(:pages_update_legacy_storage, default_enabled: true)
super
end
end
end
end
end
......@@ -47,12 +47,4 @@ RSpec.describe Gitlab::Pages::Settings do
end
end
end
describe '#local_store' do
subject(:local_store) { described_class.new(settings).local_store }
it 'is an instance of Gitlab::Pages::Stores::LocalStore' do
expect(local_store).to be_a(Gitlab::Pages::Stores::LocalStore)
end
end
end
# frozen_string_literal: true
require 'spec_helper'
RSpec.describe Gitlab::Pages::Stores::LocalStore do
describe '#enabled' do
let(:local_store) { double(enabled: true) }
subject(:local_store_enabled) { described_class.new(local_store).enabled }
context 'when the pages_update_legacy_storage FF is disabled' do
before do
stub_feature_flags(pages_update_legacy_storage: false)
end
it { is_expected.to be_falsey }
end
context 'when the pages_update_legacy_storage FF is enabled' do
it 'is equal to the original value' do
expect(local_store_enabled).to eq(local_store.enabled)
end
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment