diff options
| author | James Turnbull <james@lovedthanlost.net> | 2011-03-08 20:18:30 +1100 |
|---|---|---|
| committer | James Turnbull <james@lovedthanlost.net> | 2011-03-17 07:56:07 +1100 |
| commit | 0411d2eacbfad9d07977dea8975b604b7cdd1aa5 (patch) | |
| tree | 30c79a3b1a623a7bff5f8e68ec0c99d69d4bcc71 /spec/unit/util | |
| parent | 5b6f4fa4aae419bd2d65e1af6e185123dd432ac6 (diff) | |
| download | facter-0411d2eacbfad9d07977dea8975b604b7cdd1aa5.tar.gz facter-0411d2eacbfad9d07977dea8975b604b7cdd1aa5.tar.xz facter-0411d2eacbfad9d07977dea8975b604b7cdd1aa5.zip | |
Fixed #2346 - Part 1: Added arp fact for Linux
Added facts arp (like the ipaddress etc) facts
Added facts arp_interfacename
Diffstat (limited to 'spec/unit/util')
| -rwxr-xr-x | spec/unit/util/ip_spec.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/spec/unit/util/ip_spec.rb b/spec/unit/util/ip_spec.rb index 1a545b8..0374e75 100755 --- a/spec/unit/util/ip_spec.rb +++ b/spec/unit/util/ip_spec.rb @@ -227,4 +227,11 @@ describe Facter::Util::IP do Facter::Util::IP.convert_from_hex?(platform).should == true end end + + it "should return an arp address on Linux" do + Facter.stubs(:value).with(:kernel).returns("Linux") + + Facter::Util::IP.expects(:get_arp_value).with("eth0").returns("00:00:0c:9f:f0:04") + Facter::Util::IP.get_arp_value("eth0").should == "00:00:0c:9f:f0:04" + end end |
