Skip to content

Commit

Permalink
Fix failing specs
Browse files Browse the repository at this point in the history
Signed-off-by: Tim Smith <tsmith@chef.io>
  • Loading branch information
tas50 committed Jan 5, 2020
1 parent 3d2c9bb commit 3872610
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
8 changes: 4 additions & 4 deletions spec/default_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -74,23 +74,23 @@

context 'config prefix' do
context 'on macOS' do
let(:chef_run) { ChefSpec::SoloRunner.new(platform: 'mac_os_x', version: '10.13').converge(described_recipe) }
let(:chef_run) { ChefSpec::SoloRunner.new(platform: 'mac_os_x').converge(described_recipe) }

it 'uses /private/etc' do
expect(chef_run).to create_template('/private/etc/sudoers')
end
end

context 'on SmartOS' do
let(:chef_run) { ChefSpec::SoloRunner.new(platform: 'smartos', version: '5.11').converge(described_recipe) }
let(:chef_run) { ChefSpec::SoloRunner.new(platform: 'smartos').converge(described_recipe) }

it 'uses /opt/local/etc' do
expect(chef_run).to create_template('/opt/local/etc/sudoers')
end
end

context 'on Ubuntu' do
let(:chef_run) { ChefSpec::SoloRunner.new(platform: 'ubuntu', version: '16.04').converge(described_recipe) }
let(:chef_run) { ChefSpec::SoloRunner.new(platform: 'ubuntu').converge(described_recipe) }

it 'uses /etc' do
expect(chef_run).to create_template('/etc/sudoers')
Expand Down Expand Up @@ -164,7 +164,7 @@

context 'Non-Linux distro' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'freebsd', version: '11.0').converge(described_recipe)
ChefSpec::SoloRunner.new(platform: 'freebsd').converge(described_recipe)
end

it 'does not create the sudoers.d directory' do
Expand Down
1 change: 0 additions & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,4 @@
config.formatter = :documentation # Use the specified formatter
config.log_level = :error # Avoid deprecation notice SPAM
config.platform = 'ubuntu'
config.version = '16.04'
end

0 comments on commit 3872610

Please sign in to comment.