Files
cookbook-openstack-common/spec/sysctl_spec.rb
Lance Albertson 8d07e9acee Cookstyle 6.19.5 fixes
Also remove unused database resources that somehow got imported in
https://review.opendev.org/701027.

Change-Id: I5241e0f1eb3bf44158bc64019a3880d83a6d4bdc
Depends-On: https://review.opendev.org/756168
Signed-off-by: Lance Albertson <lance@osuosl.org>
2020-10-05 17:02:11 -07:00

23 lines
628 B
Ruby

require_relative 'spec_helper'
describe 'openstack-common::sysctl' do
describe 'ubuntu' do
sysctl_kv = {
'sysctl_key1' => 'sysctl_value1',
'sysctl_key2' => 'sysctl_value2',
}
let(:runner) { ChefSpec::SoloRunner.new(UBUNTU_OPTS) }
let(:node) { runner.node }
cached(:chef_run) do
node.override['openstack']['sysctl'] = sysctl_kv
runner.converge(described_recipe)
end
it do
expect(chef_run).to apply_sysctl('sysctl_key1').with(value: 'sysctl_value1')
end
it do
expect(chef_run).to apply_sysctl('sysctl_key2').with(value: 'sysctl_value2')
end
end
end