2020-05-24 23:13:21 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
require 'spec_helper'
|
|
|
|
require 'rake_helper'
|
|
|
|
|
2020-07-28 23:09:34 +05:30
|
|
|
RSpec.describe SystemCheck::App::HashedStorageEnabledCheck do
|
2020-05-24 23:13:21 +05:30
|
|
|
before do
|
|
|
|
silence_output
|
|
|
|
end
|
|
|
|
|
|
|
|
describe '#check?' do
|
|
|
|
it 'fails when hashed storage is disabled' do
|
|
|
|
stub_application_setting(hashed_storage_enabled: false)
|
|
|
|
|
|
|
|
expect(subject.check?).to be_falsey
|
|
|
|
end
|
|
|
|
|
|
|
|
it 'succeeds when hashed storage is enabled' do
|
|
|
|
stub_application_setting(hashed_storage_enabled: true)
|
|
|
|
|
|
|
|
expect(subject.check?).to be_truthy
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|