(FM-7795) Cleanup java tests (#350)
* Add idempotent_apply function * Remove unsupported OS specific code * Remove outdated comments * Improve unit test coverage * Fix typo
This commit is contained in:
@@ -47,7 +47,7 @@ describe 'java_default_home' do
|
||||
context 'when java not present, return nil' do
|
||||
it do
|
||||
allow(Facter::Util::Resolution).to receive(:exec) # Catch all other calls
|
||||
expect(Facter::Util::Resolution).to receive(:which).with('java').at_least(1).and_return(false)
|
||||
expect(Facter::Util::Resolution).to receive(:which).with('java').at_least(1).and_return(nil)
|
||||
expect(Facter.value(:java_default_home)).to be_nil
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user