2019-07-25 01:21:37 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2019-02-20 16:29:48 -05:00
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
describe Gitlab::Chat, :use_clean_rails_memory_store_caching do
|
|
|
|
describe '.available?' do
|
|
|
|
it 'returns true when the chatops feature is available' do
|
2020-05-29 14:08:26 -04:00
|
|
|
stub_feature_flags(chatops: true)
|
2019-02-20 16:29:48 -05:00
|
|
|
|
|
|
|
expect(described_class).to be_available
|
|
|
|
end
|
|
|
|
|
|
|
|
it 'returns false when the chatops feature is not available' do
|
2020-05-29 14:08:26 -04:00
|
|
|
stub_feature_flags(chatops: false)
|
2019-02-20 16:29:48 -05:00
|
|
|
|
|
|
|
expect(described_class).not_to be_available
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|