Skip to content

Commit 30bbc21

Browse files
committed
(maint) Revive spec tests
The PDK update from a previous commit was a little too aggressive and got rid of some things we need to run spec tests on this module. Re-adding those things along with some other changes, this change restores our ability to run the spec tests on this repo. For the future, when we want to run these spec tests in a github action, we'll need to set up credentials to clone test fixtures that are now all in private repos.
1 parent 95d663a commit 30bbc21

3 files changed

Lines changed: 18 additions & 3 deletions

File tree

.fixtures.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,20 @@ fixtures:
1717
repositories:
1818
puppet-enterprise-modules:
1919
repo: 'git@github.com:puppetlabs/puppet-enterprise-modules.git'
20-
ref: 'origin/kearney'
20+
ref: 'origin/2019.8.x'
2121
target: 'spec/fixtures'
2222
pe_r10k:
2323
repo: "git@github.com:puppetlabs/puppetlabs-pe_r10k.git"
2424
ref: origin/2016.2.x
2525
enterprise_tasks:
2626
repo: "git@github.com:puppetlabs/enterprise_tasks.git"
27-
ref: origin/master
27+
ref: origin/main
2828
pe_xl:
2929
repo: "git@github.com:reidmv/reidmv-pe_xl.git"
3030
ref: origin/main
3131
provision:
3232
repo: "git@github.com:puppetlabs/provision.git"
33-
ref: origin/master
33+
ref: origin/main
3434

3535
symlinks:
3636
puppet_enterprise: "#{source_dir}/spec/fixtures/puppet-enterprise-modules/modules/puppet_enterprise"

Gemfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ group :development do
6161
gem "rb-readline", '= 0.5.5', require: false, platforms: [:mswin, :mingw, :x64_mingw]
6262
gem "bigdecimal", '< 3.2.2', require: false, platforms: [:mswin, :mingw, :x64_mingw]
6363
gem "puppet-resource_api", require: false
64+
gem 'webmock', '~> 3.0', require: false
6465
end
6566
group :development, :release_prep do
6667
gem "puppet-strings", '~> 4.0', require: false

spec/spec_helper.rb

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66

77
require 'puppetlabs_spec_helper/module_spec_helper'
88
require 'rspec-puppet-facts'
9+
require 'shared/contexts'
910

1011
require 'spec_helper_local' if File.file?(File.join(File.dirname(__FILE__), 'spec_helper_local.rb'))
1112

@@ -14,6 +15,19 @@
1415
default_facts = {
1516
puppetversion: Puppet.version,
1617
facterversion: Facter.version,
18+
platform_symlink_writable: true,
19+
path: '/usr/local/sbin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin:/usr/local/bin',
20+
os: {
21+
'family' => 'RedHat',
22+
'name' => 'CentOS',
23+
'release' => {
24+
'major' => '6',
25+
},
26+
},
27+
pe_build: '2018.1.0',
28+
platform_tag: 'el-7-x86_64',
29+
memory: { 'system' => { 'total_bytes' => 4_294_967_296 } },
30+
processors: { 'count' => 1 }
1731
}
1832

1933
default_fact_files = [

0 commit comments

Comments
 (0)