Merge branch 'fix/2.5.x/facter_loader' into 2.5.x
* fix/2.5.x/facter_loader: (maint) Fix spec failures resulting from Facter API changes
This commit is contained in:
commit
3f310ec874
1 changed files with 9 additions and 1 deletions
|
@ -4,8 +4,16 @@ require 'spec_helper'
|
||||||
|
|
||||||
describe "PE Version specs" do
|
describe "PE Version specs" do
|
||||||
before :each do
|
before :each do
|
||||||
|
# Explicitly load the pe_version.rb file which contains generated facts
|
||||||
|
# that cannot be automatically loaded. Puppet 2.x implements
|
||||||
|
# Facter.collection.load while Facter 1.x markes Facter.collection.load as
|
||||||
|
# a private method.
|
||||||
|
if Facter.collection.respond_to? :load
|
||||||
|
Facter.collection.load(:pe_version)
|
||||||
|
else
|
||||||
Facter.collection.loader.load(:pe_version)
|
Facter.collection.loader.load(:pe_version)
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
context "If PE is installed" do
|
context "If PE is installed" do
|
||||||
%w{ 2.6.1 2.10.300 }.each do |version|
|
%w{ 2.6.1 2.10.300 }.each do |version|
|
||||||
|
|
Loading…
Reference in a new issue