diff options
author | Hans de Graaff <hans@degraaff.org> | 2010-09-18 17:31:11 +0200 |
---|---|---|
committer | Hans de Graaff <hans@degraaff.org> | 2010-09-18 17:31:11 +0200 |
commit | 1125e1e050a3807df2ada4d8cf2d36c22a75ed2b (patch) | |
tree | e1b398eb4486e245207c3a815b0ab4fbd9607c0e | |
parent | 889e1504c101b36741141ef95cf5cbdfedd95e56 (diff) | |
download | facter-1125e1e050a3807df2ada4d8cf2d36c22a75ed2b.tar.gz facter-1125e1e050a3807df2ada4d8cf2d36c22a75ed2b.tar.xz facter-1125e1e050a3807df2ada4d8cf2d36c22a75ed2b.zip |
Make sure FreeBSD spec also works on systems that have /proc/cpuinfo.
-rw-r--r-- | spec/unit/util/virtual.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/spec/unit/util/virtual.rb b/spec/unit/util/virtual.rb index 1e31a2f..cc528d1 100644 --- a/spec/unit/util/virtual.rb +++ b/spec/unit/util/virtual.rb @@ -101,6 +101,7 @@ describe Facter::Util::Virtual do end it "should detect kvm on FreeBSD" do + FileTest.stubs(:exists?).with("/proc/cpuinfo").returns(false) Facter.fact(:kernel).stubs(:value).returns("FreeBSD") Facter::Util::Resolution.stubs(:exec).with("/sbin/sysctl -n hw.model").returns("QEMU Virtual CPU version 0.12.4") Facter::Util::Virtual.should be_kvm |