2020-11-24 15:15:51 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
RSpec.describe ContainerRegistryHelper do
|
2021-03-11 19:13:27 +05:30
|
|
|
describe '#container_registry_expiration_policies_throttling?' do
|
|
|
|
subject { helper.container_registry_expiration_policies_throttling? }
|
2020-11-24 15:15:51 +05:30
|
|
|
|
2022-05-07 20:08:51 +05:30
|
|
|
it { is_expected.to eq(true) }
|
2020-11-24 15:15:51 +05:30
|
|
|
|
2022-05-07 20:08:51 +05:30
|
|
|
context 'with container_registry_expiration_policies_throttling disabled' do
|
2020-11-24 15:15:51 +05:30
|
|
|
before do
|
2022-05-07 20:08:51 +05:30
|
|
|
stub_feature_flags(container_registry_expiration_policies_throttling: false)
|
2020-11-24 15:15:51 +05:30
|
|
|
end
|
|
|
|
|
2022-05-07 20:08:51 +05:30
|
|
|
it { is_expected.to eq(false) }
|
2020-11-24 15:15:51 +05:30
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|