Commit 17dab64a authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Improve gitlab config tests

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent d9519573
......@@ -46,11 +46,6 @@ eos
describe :redis_command do
subject { config.redis_command }
it { should be_an(Array) }
it { should include(config.redis['host']) }
it { should include(config.redis['bin']) }
it { should include(config.redis['port'].to_s) }
context "with empty redis config" do
before do
config.stub(:redis) { {} }
......@@ -60,6 +55,17 @@ eos
it { should include('redis-cli') }
end
context "with host and port" do
before do
config.stub(:redis) { {'host' => 'localhost', 'port' => 1123, 'bin' => '/usr/bin/redis-cli'} }
end
it { should be_an(Array) }
it { should include(config.redis['host']) }
it { should include(config.redis['bin']) }
it { should include(config.redis['port'].to_s) }
end
context "with redis socket" do
let(:socket) { '/tmp/redis.socket' }
before do
......
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