Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(FACT-2724) Confine blocks behave differently with Facter 4, causing spec tests to suddenly fail #2010

Merged
merged 1 commit into from
Aug 4, 2020

Conversation

BogdanIrimie
Copy link
Contributor

problem

virtual fact was returning nil on physical macOS hosts. The test mocked virtual fact by using

allow(Facter.fact(:virtual)).to receive(:value).and_return('physical')

and because Facter.fact(:virtual) returned nil on physical macOS hosts, the mock was basically

allow(nil).to receive(:value).and_return('physical')

fix

on macOS physiscal host, facter will return virtual => physical

@BogdanIrimie BogdanIrimie requested review from a team August 3, 2020 13:52
@puppetcla
Copy link

CLA signed by all contributors.

@BogdanIrimie BogdanIrimie added the bug Something isn't working label Aug 4, 2020
@Filipovici-Andrei Filipovici-Andrei merged commit e6d94c7 into puppetlabs:4.x Aug 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants