Skip to content

Commit

Permalink
Rubocop: Fix RSpec/InstanceVariable
Browse files Browse the repository at this point in the history
  • Loading branch information
alexjfisher committed Feb 9, 2020
1 parent 7708708 commit 650cd7e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions spec/unit/puppet/type/rvm_system_ruby_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,18 @@

describe Puppet::Type.type(:rvm_system_ruby) do
context 'with autolib_mode set' do
let(:system_ruby) do
Puppet::Type.type(:rvm_system_ruby).new(name: 'jruby-1.7.6', autolib_mode: 'read-fail')
end

it 'does not raise error' do
expect do
Puppet::Type.type(:rvm_system_ruby).new(name: 'ruby-1.9.3-p448', autolib_mode: 'enabled')
end.not_to raise_error
end

it 'sets mode correctly' do
@system_ruby = Puppet::Type.type(:rvm_system_ruby).new(name: 'jruby-1.7.6', autolib_mode: 'read-fail')
expect(@system_ruby[:autolib_mode]).to eq('read-fail')
expect(system_ruby[:autolib_mode]).to eq('read-fail')
end
end

Expand Down

0 comments on commit 650cd7e

Please sign in to comment.