| It seems like the facter 4 hyper-v unit test gets the information from the OS instead of a mocked value:
Failures: |
|
1) Facts::Linux::Virtual#call_the_resolver when is hyper-v discovered with lspci returns virtual fact |
Failure/Error: |
expect(fact.call_the_resolver).to be_an_instance_of(Facter::ResolvedFact).and \ |
have_attributes(name: 'virtual', value: value) |
|
expected #<Facter::ResolvedFact:0x000055b2f3048728 @name="virtual", @value="vmware", @type=:core, @user_query=nil, @filter_tokens=[]> to have attributes {:name => "virtual", :value => "hyperv"} but had attributes {:name => "virtual", :value => "vmware"} |
Diff for (have attributes {:name => "virtual", :value => "hyperv"}): |
@@ -1,3 +1,7 @@ |
-:name => "virtual", |
-:value => "hyperv", |
+#<Facter::ResolvedFact:0x000055b2f3048728 |
+ @filter_tokens=[], |
+ @name="virtual", |
+ @type=:core, |
+ @user_query=nil, |
+ @value="vmware"> |
|
# ./spec/facter/facts/linux/virtual_spec.rb:134:in `block (4 levels) in <top (required)>' |
|
Finished in 2.04 seconds (files took 1.11 seconds to load) |
2431 examples, 1 failure |
|
Failed examples: |
|
rspec ./spec/facter/facts/linux/virtual_spec.rb:133 # Facts::Linux::Virtual#call_the_resolver when is hyper-v discovered with lspci returns virtual fact
|
Steps to reproduce:
- Start a vmpooler VM (tested on Ubuntu 18.04)
- Clone facter, 4.x branch
- Run ./check.sh
|