File tree Expand file tree Collapse file tree 8 files changed +28
-18
lines changed Expand file tree Collapse file tree 8 files changed +28
-18
lines changed Original file line number Diff line number Diff line change @@ -232,18 +232,21 @@ simple tests against it after applying the module. You can run this
232232with:
233233
234234``` sh
235- BEAKER_setfile=debian11-64 bundle exec rake beaker
235+ BEAKER_PUPPET_COLLECTION=puppet7 BEAKER_setfile=debian11-64 bundle exec rake beaker
236236```
237237
238- You can replace the string ` debian10 ` with any common operating system.
238+ You can replace the string ` debian11 ` with any common operating system.
239239The following strings are known to work:
240240
241- * ubuntu1804
242241* ubuntu2004
243- * debian10
242+ * ubuntu2204
244243* debian11
245244* centos7
246245* centos8
246+ * centos9
247+ * almalinux8
248+ * almalinux9
249+ * fedora36
247250
248251For more information and tips & tricks, see [ voxpupuli-acceptance's documentation] ( https://github.com/voxpupuli/voxpupuli-acceptance#running-tests ) .
249252
Original file line number Diff line number Diff line change 22# Managed by modulesync - DO NOT EDIT
33# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/
44
5- modulesync_config_version : ' 6 .0.0'
5+ modulesync_config_version : ' 7 .0.0'
Original file line number Diff line number Diff line change 44source ENV [ 'GEM_SOURCE' ] || 'https://rubygems.org'
55
66group :test do
7- gem 'voxpupuli-test' , '~> 6 .0' , :require => false
7+ gem 'voxpupuli-test' , '~> 7 .0' , :require => false
88 gem 'coveralls' , :require => false
99 gem 'simplecov-console' , :require => false
1010 gem 'puppet_metadata' , '~> 3.0' , :require => false
Original file line number Diff line number Diff line change 1717 add_custom_fact name . to_sym , value
1818 end
1919end
20+ Dir [ './spec/support/spec/**/*.rb' ] . sort . each { |f | require f }
Original file line number Diff line number Diff line change 55
66require 'voxpupuli/acceptance/spec_helper_acceptance'
77
8- configure_beaker
8+ configure_beaker ( modules : :metadata )
99
1010Dir [ './spec/support/acceptance/**/*.rb' ] . sort . each { |f | require f }
Original file line number Diff line number Diff line change 77 Facter . clear
88 end
99
10+ # rubocop:disable RSpec/IndexedLet
1011 let ( :pip_version_output ) do
1112 <<~EOS
1213 pip 6.0.6 from /opt/boxen/homebrew/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip-6.0.6-py2.7.egg (python 2.7)
2425 pip 18.1 from /usr/lib/python3/dist-packages/pip (python 3.7)
2526 EOS
2627 end
28+ # rubocop:enable RSpec/IndexedLet
2729
2830 describe 'pip_version' do
2931 context 'returns pip version when pip present' do
3739 context 'returns nil when pip not present' do
3840 it do
3941 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'pip' ) . and_return ( false )
40- expect ( Facter . value ( :pip_version ) ) . to eq ( nil )
42+ expect ( Facter . value ( :pip_version ) ) . to be_nil
4143 end
4244 end
4345 end
5456 context 'returns nil when pip2 not present' do
5557 it do
5658 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'pip2' ) . and_return ( false )
57- expect ( Facter . value ( :pip2_version ) ) . to eq ( nil )
59+ expect ( Facter . value ( :pip2_version ) ) . to be_nil
5860 end
5961 end
6062 end
7173 context 'returns nil when pip3 not present' do
7274 it do
7375 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'pip3' ) . and_return ( false )
74- expect ( Facter . value ( :pip3_version ) ) . to eq ( nil )
76+ expect ( Facter . value ( :pip3_version ) ) . to be_nil
7577 end
7678 end
7779 end
Original file line number Diff line number Diff line change 77 Facter . clear
88 end
99
10+ # rubocop:disable RSpec/IndexedLet
1011 let ( :python2_version_output ) do
1112 <<~EOS
1213 Python 2.7.9
1718 Python 3.3.0
1819 EOS
1920 end
21+ # rubocop:enable RSpec/IndexedLet
2022
2123 describe 'python_release' do
2224 context 'returns Python release when `python` present' do
3133 it do
3234 allow ( Facter ::Util ::Resolution ) . to receive ( :exec ) . and_return ( false )
3335 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python' ) . and_return ( false )
34- expect ( Facter . value ( :python_release ) ) . to eq ( nil )
36+ expect ( Facter . value ( :python_release ) ) . to be_nil
3537 end
3638 end
3739 end
6062 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python' ) . and_return ( true )
6163 allow ( Facter ::Util ::Resolution ) . to receive ( :exec ) . with ( 'python -V 2>&1' ) . and_return ( python3_version_output )
6264 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python2' ) . and_return ( false )
63- expect ( Facter . value ( :python2_release ) ) . to eq ( nil )
65+ expect ( Facter . value ( :python2_release ) ) . to be_nil
6466 end
6567 end
6668
6769 context 'returns nil when `python2` and `python` are absent' do
6870 it do
6971 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python' ) . and_return ( false )
7072 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python2' ) . and_return ( false )
71- expect ( Facter . value ( :python2_release ) ) . to eq ( nil )
73+ expect ( Facter . value ( :python2_release ) ) . to be_nil
7274 end
7375 end
7476 end
8587 context 'returns nil when `python3` not present' do
8688 it do
8789 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python3' ) . and_return ( false )
88- expect ( Facter . value ( :python3_release ) ) . to eq ( nil )
90+ expect ( Facter . value ( :python3_release ) ) . to be_nil
8991 end
9092 end
9193 end
Original file line number Diff line number Diff line change 77 Facter . clear
88 end
99
10+ # rubocop:disable RSpec/IndexedLet
1011 let ( :python2_version_output ) do
1112 <<~EOS
1213 Python 2.7.9
1718 Python 3.3.0
1819 EOS
1920 end
21+ # rubocop:enable RSpec/IndexedLet
2022
2123 describe 'python_version' do
2224 context 'returns Python version when `python` present' do
3032 context 'returns nil when `python` not present' do
3133 it do
3234 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python' ) . and_return ( false )
33- expect ( Facter . value ( :python_version ) ) . to eq ( nil )
35+ expect ( Facter . value ( :python_version ) ) . to be_nil
3436 end
3537 end
3638 end
5961 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python' ) . and_return ( true )
6062 allow ( Facter ::Util ::Resolution ) . to receive ( :exec ) . with ( 'python -V 2>&1' ) . and_return ( python3_version_output )
6163 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python2' ) . and_return ( false )
62- expect ( Facter . value ( :python2_version ) ) . to eq ( nil )
64+ expect ( Facter . value ( :python2_version ) ) . to be_nil
6365 end
6466 end
6567
6668 context 'returns nil when `python2` and `python` are absent' do
6769 it do
6870 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python2' ) . and_return ( false )
6971 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python' ) . and_return ( false )
70- expect ( Facter . value ( :python2_version ) ) . to eq ( nil )
72+ expect ( Facter . value ( :python2_version ) ) . to be_nil
7173 end
7274 end
7375 end
8486 context 'returns nil when `python3` not present' do
8587 it do
8688 allow ( Facter ::Util ::Resolution ) . to receive ( :which ) . with ( 'python3' ) . and_return ( false )
87- expect ( Facter . value ( :python3_version ) ) . to eq ( nil )
89+ expect ( Facter . value ( :python3_version ) ) . to be_nil
8890 end
8991 end
9092 end
You can’t perform that action at this time.
0 commit comments