GitLab upgraded to 13.9.1-ee.0 - changelog: https://gitlab.com/gitlab-org/gitlab/blob/master/CHANGELOG-EE.md

Commit e6994873 authored by Tim Smith's avatar Tim Smith

Add some useful ChefSpec for the user_ulimit resource

Signed-off-by: default avatarTim Smith <tsmith@chef.io>
parent 2496d1f7
require 'spec_helper'
describe 'custom resource test recipe on ubuntu 16.04' do
let(:runner) { ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '16.04') }
let(:chef_run) { runner.converge('test::default') }
it 'converges successfully' do
expect { :chef_run }.to_not raise_error
end
end
require 'spec_helper'
describe 'user_ulimit resource' do
step_into :user_ulimit
platform 'ubuntu'
context 'without the filename specified' do
recipe do
user_ulimit 'tomcat' do
filehandle_soft_limit 8192
end
end
it { is_expected.to create_template('/etc/security/limits.d/tomcat_limits.conf') }
end
context 'with the filename specified and not ending in .conf' do
recipe do
user_ulimit 'tomcat' do
filename 'foo'
filehandle_soft_limit 8192
end
end
it { is_expected.to create_template('/etc/security/limits.d/foo.conf') }
end
context 'with the filename specified and ending in .conf' do
recipe do
user_ulimit 'tomcat' do
filename 'foo.conf'
filehandle_soft_limit 8192
end
end
it { is_expected.to create_template('/etc/security/limits.d/foo.conf') }
end
context 'with the username set to *' do
recipe do
user_ulimit 'tomcat' do
username '*'
filehandle_soft_limit 8192
end
end
it { is_expected.to create_template('/etc/security/limits.d/00_all_limits.conf') }
end
end
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