You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ensure FacterImpl consistency between example groups
Using the 'rspec' facter implementation we could sometimes get in a case
where the values of FacterImpl and Puppet.runtime[:facter] diverged
between example groups.
Because rspec-puppet overrides facts using the FacterImpl constant
(which is only set once), Puppet.runtime[:facter] would point to a
different instance of FacterTestImpl with no available facts, causing
calls to Puppet.runtime[:facter].value to fail.
To prevent this from happening, set Puppet.runtime[:facter] to the value
of FacterImpl; this way we make sure Puppet.runtime[:facter] and
FacterImpl operate on the same instance of FacterTestImpl.
0 commit comments