beaker-vagrant 0.7.0 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/dependabot.yml +9 -0
- data/.github/workflows/release.yml +17 -9
- data/.github/workflows/test.yml +40 -11
- data/.rubocop.yml +4 -0
- data/.rubocop_todo.yml +383 -0
- data/CHANGELOG.md +202 -0
- data/Gemfile +3 -24
- data/README.md +26 -9
- data/Rakefile +34 -120
- data/beaker-vagrant.gemspec +24 -24
- data/bin/beaker-vagrant +1 -3
- data/lib/beaker/hypervisor/vagrant/mount_folder.rb +1 -1
- data/lib/beaker/hypervisor/vagrant.rb +72 -83
- data/lib/beaker/hypervisor/vagrant_custom.rb +1 -1
- data/lib/beaker/hypervisor/vagrant_desktop.rb +9 -5
- data/lib/beaker/hypervisor/vagrant_libvirt.rb +1 -7
- data/lib/beaker/hypervisor/vagrant_parallels.rb +2 -2
- data/lib/beaker/hypervisor/vagrant_virtualbox.rb +35 -32
- data/lib/beaker/hypervisor/vagrant_workstation.rb +9 -5
- data/lib/beaker-vagrant/version.rb +1 -1
- data/spec/beaker/hypervisor/vagrant_custom_spec.rb +14 -15
- data/spec/beaker/hypervisor/vagrant_desktop_spec.rb +20 -20
- data/spec/beaker/hypervisor/vagrant_fusion_spec.rb +11 -11
- data/spec/beaker/hypervisor/vagrant_libvirt_spec.rb +23 -22
- data/spec/beaker/hypervisor/vagrant_parallels_spec.rb +15 -15
- data/spec/beaker/hypervisor/vagrant_spec.rb +301 -309
- data/spec/beaker/hypervisor/vagrant_virtualbox_spec.rb +50 -29
- data/spec/beaker/hypervisor/vagrant_workstation_spec.rb +20 -20
- data/spec/spec_helper.rb +1 -2
- metadata +69 -36
data/CHANGELOG.md
ADDED
@@ -0,0 +1,202 @@
|
|
1
|
+
# Changelog
|
2
|
+
|
3
|
+
## [1.0.0](https://github.com/voxpupuli/beaker-vagrant/tree/1.0.0) (2023-03-27)
|
4
|
+
|
5
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.7.1...1.0.0)
|
6
|
+
|
7
|
+
**Breaking changes:**
|
8
|
+
|
9
|
+
- Drop Ruby 2.4/2.5/2.6 support [\#55](https://github.com/voxpupuli/beaker-vagrant/pull/55) ([bastelfreak](https://github.com/bastelfreak))
|
10
|
+
|
11
|
+
**Implemented enhancements:**
|
12
|
+
|
13
|
+
- Add Ruby 3.2 to CI [\#66](https://github.com/voxpupuli/beaker-vagrant/pull/66) ([bastelfreak](https://github.com/bastelfreak))
|
14
|
+
- Add Ruby 3.0/3.1 to CI [\#59](https://github.com/voxpupuli/beaker-vagrant/pull/59) ([bastelfreak](https://github.com/bastelfreak))
|
15
|
+
|
16
|
+
**Merged pull requests:**
|
17
|
+
|
18
|
+
- Rubocop: Fix layout cops [\#65](https://github.com/voxpupuli/beaker-vagrant/pull/65) ([bastelfreak](https://github.com/bastelfreak))
|
19
|
+
- drop yard doc generation code [\#64](https://github.com/voxpupuli/beaker-vagrant/pull/64) ([bastelfreak](https://github.com/bastelfreak))
|
20
|
+
- CI: Fix release workflow [\#63](https://github.com/voxpupuli/beaker-vagrant/pull/63) ([bastelfreak](https://github.com/bastelfreak))
|
21
|
+
- rubocop: Fix Style cops [\#62](https://github.com/voxpupuli/beaker-vagrant/pull/62) ([bastelfreak](https://github.com/bastelfreak))
|
22
|
+
- Allow fakefs 2.x [\#61](https://github.com/voxpupuli/beaker-vagrant/pull/61) ([ekohl](https://github.com/ekohl))
|
23
|
+
- Bump actions/checkout from 2 to 3 [\#60](https://github.com/voxpupuli/beaker-vagrant/pull/60) ([dependabot[bot]](https://github.com/apps/dependabot))
|
24
|
+
- dependabot: check for github actions and gems [\#58](https://github.com/voxpupuli/beaker-vagrant/pull/58) ([bastelfreak](https://github.com/bastelfreak))
|
25
|
+
- Implement RuboCop [\#57](https://github.com/voxpupuli/beaker-vagrant/pull/57) ([bastelfreak](https://github.com/bastelfreak))
|
26
|
+
- apply best-practices to GitHub workflow [\#56](https://github.com/voxpupuli/beaker-vagrant/pull/56) ([bastelfreak](https://github.com/bastelfreak))
|
27
|
+
- Remove unused rspec-its dependency [\#52](https://github.com/voxpupuli/beaker-vagrant/pull/52) ([ekohl](https://github.com/ekohl))
|
28
|
+
|
29
|
+
## [0.7.1](https://github.com/voxpupuli/beaker-vagrant/tree/0.7.1) (2021-05-26)
|
30
|
+
|
31
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.7.0...0.7.1)
|
32
|
+
|
33
|
+
**Fixed bugs:**
|
34
|
+
|
35
|
+
- Remove set\_host\_default from vagrant\_libvirt [\#50](https://github.com/voxpupuli/beaker-vagrant/pull/50) ([trevor-vaughan](https://github.com/trevor-vaughan))
|
36
|
+
|
37
|
+
**Closed issues:**
|
38
|
+
|
39
|
+
- The recent change to the set\_host\_default method in vagrant\_libvirt broke multi-node testing [\#49](https://github.com/voxpupuli/beaker-vagrant/issues/49)
|
40
|
+
|
41
|
+
**Merged pull requests:**
|
42
|
+
|
43
|
+
- Release of 0.7.1 [\#51](https://github.com/voxpupuli/beaker-vagrant/pull/51) ([trevor-vaughan](https://github.com/trevor-vaughan))
|
44
|
+
|
45
|
+
## [0.7.0](https://github.com/voxpupuli/beaker-vagrant/tree/0.7.0) (2021-05-18)
|
46
|
+
|
47
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.6.7...0.7.0)
|
48
|
+
|
49
|
+
**Closed issues:**
|
50
|
+
|
51
|
+
- \(BKR-1697\) Fix libvirt support [\#39](https://github.com/voxpupuli/beaker-vagrant/issues/39)
|
52
|
+
|
53
|
+
**Merged pull requests:**
|
54
|
+
|
55
|
+
- Release 0.7.0 [\#48](https://github.com/voxpupuli/beaker-vagrant/pull/48) ([ekohl](https://github.com/ekohl))
|
56
|
+
- Stop using private networks on libvirt [\#47](https://github.com/voxpupuli/beaker-vagrant/pull/47) ([ekohl](https://github.com/ekohl))
|
57
|
+
- Correctly override the Vagrant path [\#46](https://github.com/voxpupuli/beaker-vagrant/pull/46) ([ekohl](https://github.com/ekohl))
|
58
|
+
- Remove redundant path in path construction [\#45](https://github.com/voxpupuli/beaker-vagrant/pull/45) ([ekohl](https://github.com/ekohl))
|
59
|
+
- Simplify vagrant\_libvirt option building [\#44](https://github.com/voxpupuli/beaker-vagrant/pull/44) ([ekohl](https://github.com/ekohl))
|
60
|
+
- Do not set an explicit mac address [\#43](https://github.com/voxpupuli/beaker-vagrant/pull/43) ([ekohl](https://github.com/ekohl))
|
61
|
+
- Get the SSH config from vagrant [\#42](https://github.com/voxpupuli/beaker-vagrant/pull/42) ([ekohl](https://github.com/ekohl))
|
62
|
+
- Lazily create the vagrant path [\#41](https://github.com/voxpupuli/beaker-vagrant/pull/41) ([ekohl](https://github.com/ekohl))
|
63
|
+
- Deactivate FakeFS after using it [\#40](https://github.com/voxpupuli/beaker-vagrant/pull/40) ([ekohl](https://github.com/ekohl))
|
64
|
+
- Add GH Action for releases [\#38](https://github.com/voxpupuli/beaker-vagrant/pull/38) ([genebean](https://github.com/genebean))
|
65
|
+
- Various compatible cleanups [\#33](https://github.com/voxpupuli/beaker-vagrant/pull/33) ([ekohl](https://github.com/ekohl))
|
66
|
+
|
67
|
+
## [0.6.7](https://github.com/voxpupuli/beaker-vagrant/tree/0.6.7) (2021-02-26)
|
68
|
+
|
69
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.6.6...0.6.7)
|
70
|
+
|
71
|
+
**Merged pull requests:**
|
72
|
+
|
73
|
+
- Move testing to GH Actions [\#36](https://github.com/voxpupuli/beaker-vagrant/pull/36) ([genebean](https://github.com/genebean))
|
74
|
+
- Fix simultaneous runs with the libvirt hypervisor [\#35](https://github.com/voxpupuli/beaker-vagrant/pull/35) ([trevor-vaughan](https://github.com/trevor-vaughan))
|
75
|
+
- Add Dependabot to keep thins up to date [\#30](https://github.com/voxpupuli/beaker-vagrant/pull/30) ([genebean](https://github.com/genebean))
|
76
|
+
|
77
|
+
## [0.6.6](https://github.com/voxpupuli/beaker-vagrant/tree/0.6.6) (2020-03-19)
|
78
|
+
|
79
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.6.5...0.6.6)
|
80
|
+
|
81
|
+
**Merged pull requests:**
|
82
|
+
|
83
|
+
- \(BKR-1423\) Fix SSH settings in nodesets [\#28](https://github.com/voxpupuli/beaker-vagrant/pull/28) ([trevor-vaughan](https://github.com/trevor-vaughan))
|
84
|
+
|
85
|
+
## [0.6.5](https://github.com/voxpupuli/beaker-vagrant/tree/0.6.5) (2020-03-10)
|
86
|
+
|
87
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.6.4...0.6.5)
|
88
|
+
|
89
|
+
**Merged pull requests:**
|
90
|
+
|
91
|
+
- \(BKR-1635\) Fix and document `natdns` [\#27](https://github.com/voxpupuli/beaker-vagrant/pull/27) ([op-ct](https://github.com/op-ct))
|
92
|
+
|
93
|
+
## [0.6.4](https://github.com/voxpupuli/beaker-vagrant/tree/0.6.4) (2020-01-21)
|
94
|
+
|
95
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.6.3...0.6.4)
|
96
|
+
|
97
|
+
**Merged pull requests:**
|
98
|
+
|
99
|
+
- Fix WinRM error message matching [\#26](https://github.com/voxpupuli/beaker-vagrant/pull/26) ([trevor-vaughan](https://github.com/trevor-vaughan))
|
100
|
+
|
101
|
+
## [0.6.3](https://github.com/voxpupuli/beaker-vagrant/tree/0.6.3) (2019-12-17)
|
102
|
+
|
103
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.6.2...0.6.3)
|
104
|
+
|
105
|
+
**Merged pull requests:**
|
106
|
+
|
107
|
+
- Work around common WinRM issue in Vagrant [\#25](https://github.com/voxpupuli/beaker-vagrant/pull/25) ([trevor-vaughan](https://github.com/trevor-vaughan))
|
108
|
+
- \(BKR-1628\) fix up CI for coming changes [\#24](https://github.com/voxpupuli/beaker-vagrant/pull/24) ([kevpl](https://github.com/kevpl))
|
109
|
+
- Never use QEMU session with libvirt [\#23](https://github.com/voxpupuli/beaker-vagrant/pull/23) ([ekohl](https://github.com/ekohl))
|
110
|
+
|
111
|
+
## [0.6.2](https://github.com/voxpupuli/beaker-vagrant/tree/0.6.2) (2019-02-11)
|
112
|
+
|
113
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.6.1...0.6.2)
|
114
|
+
|
115
|
+
**Merged pull requests:**
|
116
|
+
|
117
|
+
- Use winrm communicator for Windows [\#22](https://github.com/voxpupuli/beaker-vagrant/pull/22) ([treydock](https://github.com/treydock))
|
118
|
+
- \(BKR-1553\) Set PermitUserEnvironment [\#21](https://github.com/voxpupuli/beaker-vagrant/pull/21) ([ekohl](https://github.com/ekohl))
|
119
|
+
- Call configure method of parent class. [\#20](https://github.com/voxpupuli/beaker-vagrant/pull/20) ([tdevelioglu](https://github.com/tdevelioglu))
|
120
|
+
- remove audio of SUT with virtualbox [\#18](https://github.com/voxpupuli/beaker-vagrant/pull/18) ([Dan33l](https://github.com/Dan33l))
|
121
|
+
|
122
|
+
## [0.6.1](https://github.com/voxpupuli/beaker-vagrant/tree/0.6.1) (2018-12-13)
|
123
|
+
|
124
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.6.0...0.6.1)
|
125
|
+
|
126
|
+
**Merged pull requests:**
|
127
|
+
|
128
|
+
- Set RUBYOPT to an empty string for bundler [\#19](https://github.com/voxpupuli/beaker-vagrant/pull/19) ([ekohl](https://github.com/ekohl))
|
129
|
+
|
130
|
+
## [0.6.0](https://github.com/voxpupuli/beaker-vagrant/tree/0.6.0) (2018-11-13)
|
131
|
+
|
132
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.5.0...0.6.0)
|
133
|
+
|
134
|
+
**Merged pull requests:**
|
135
|
+
|
136
|
+
- \(BKR-1509\) Hypervisor usage instructions for Beaker 4.0 [\#17](https://github.com/voxpupuli/beaker-vagrant/pull/17) ([Dakta](https://github.com/Dakta))
|
137
|
+
- BKR-1508 [\#16](https://github.com/voxpupuli/beaker-vagrant/pull/16) ([ardeshireshghi](https://github.com/ardeshireshghi))
|
138
|
+
- \(MAINT\) Upgrade acceptance tests and docs [\#15](https://github.com/voxpupuli/beaker-vagrant/pull/15) ([Dakta](https://github.com/Dakta))
|
139
|
+
- Fix `BEAKER_provision=no` workflow [\#13](https://github.com/voxpupuli/beaker-vagrant/pull/13) ([joshuaspence](https://github.com/joshuaspence))
|
140
|
+
|
141
|
+
## [0.5.0](https://github.com/voxpupuli/beaker-vagrant/tree/0.5.0) (2018-05-03)
|
142
|
+
|
143
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.4.0...0.5.0)
|
144
|
+
|
145
|
+
**Merged pull requests:**
|
146
|
+
|
147
|
+
- \(maint\) add support for extra vmware configuration [\#14](https://github.com/voxpupuli/beaker-vagrant/pull/14) ([lmayorga1980](https://github.com/lmayorga1980))
|
148
|
+
- Bugfix: Issue with user given invalid keys for synced folders [\#9](https://github.com/voxpupuli/beaker-vagrant/pull/9) ([cardil](https://github.com/cardil))
|
149
|
+
|
150
|
+
## [0.4.0](https://github.com/voxpupuli/beaker-vagrant/tree/0.4.0) (2018-02-22)
|
151
|
+
|
152
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.3.0...0.4.0)
|
153
|
+
|
154
|
+
**Merged pull requests:**
|
155
|
+
|
156
|
+
- \(BKR-1237\)set vm.base\_mac for freebsd in Vagrantfile [\#6](https://github.com/voxpupuli/beaker-vagrant/pull/6) ([bastelfreak](https://github.com/bastelfreak))
|
157
|
+
|
158
|
+
## [0.3.0](https://github.com/voxpupuli/beaker-vagrant/tree/0.3.0) (2018-02-16)
|
159
|
+
|
160
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.2.1...0.3.0)
|
161
|
+
|
162
|
+
**Merged pull requests:**
|
163
|
+
|
164
|
+
- Add support for alternate volume storage controllers [\#12](https://github.com/voxpupuli/beaker-vagrant/pull/12) ([beezly](https://github.com/beezly))
|
165
|
+
|
166
|
+
## [0.2.1](https://github.com/voxpupuli/beaker-vagrant/tree/0.2.1) (2018-02-12)
|
167
|
+
|
168
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.2.0...0.2.1)
|
169
|
+
|
170
|
+
**Merged pull requests:**
|
171
|
+
|
172
|
+
- Improve documentation on volumes support [\#11](https://github.com/voxpupuli/beaker-vagrant/pull/11) ([beezly](https://github.com/beezly))
|
173
|
+
- add support for ioapic for virtualbox [\#10](https://github.com/voxpupuli/beaker-vagrant/pull/10) ([lmayorga1980](https://github.com/lmayorga1980))
|
174
|
+
|
175
|
+
## [0.2.0](https://github.com/voxpupuli/beaker-vagrant/tree/0.2.0) (2018-01-09)
|
176
|
+
|
177
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.1.1...0.2.0)
|
178
|
+
|
179
|
+
**Merged pull requests:**
|
180
|
+
|
181
|
+
- \(BKR-1264\) Ensure vm.hostname is legal [\#8](https://github.com/voxpupuli/beaker-vagrant/pull/8) ([jcoconnor](https://github.com/jcoconnor))
|
182
|
+
|
183
|
+
## [0.1.1](https://github.com/voxpupuli/beaker-vagrant/tree/0.1.1) (2017-11-20)
|
184
|
+
|
185
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/0.1.0...0.1.1)
|
186
|
+
|
187
|
+
**Merged pull requests:**
|
188
|
+
|
189
|
+
- add support for download\_insecure config [\#5](https://github.com/voxpupuli/beaker-vagrant/pull/5) ([lmayorga1980](https://github.com/lmayorga1980))
|
190
|
+
|
191
|
+
## [0.1.0](https://github.com/voxpupuli/beaker-vagrant/tree/0.1.0) (2017-07-14)
|
192
|
+
|
193
|
+
[Full Changelog](https://github.com/voxpupuli/beaker-vagrant/compare/d9545ba78c5d9ef827503c047fb7efd482734dbf...0.1.0)
|
194
|
+
|
195
|
+
**Merged pull requests:**
|
196
|
+
|
197
|
+
- \(MAINT\) Create constant for gem version [\#2](https://github.com/voxpupuli/beaker-vagrant/pull/2) ([rishijavia](https://github.com/rishijavia))
|
198
|
+
- \(MAINT\) Update README to correct hypervisor name [\#1](https://github.com/voxpupuli/beaker-vagrant/pull/1) ([rishijavia](https://github.com/rishijavia))
|
199
|
+
|
200
|
+
|
201
|
+
|
202
|
+
\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/github-changelog-generator/github-changelog-generator)*
|
data/Gemfile
CHANGED
@@ -1,27 +1,6 @@
|
|
1
|
-
source ENV['GEM_SOURCE'] ||
|
1
|
+
source ENV['GEM_SOURCE'] || 'https://rubygems.org'
|
2
2
|
|
3
3
|
gemspec
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
def location_for(place, fake_version = nil)
|
8
|
-
if place =~ /^git:([^#]*)#(.*)/
|
9
|
-
[fake_version, { :git => $1, :branch => $2, :require => false }].compact
|
10
|
-
elsif place =~ /^file:\/\/(.*)/
|
11
|
-
['>= 0', { :path => File.expand_path($1), :require => false }]
|
12
|
-
else
|
13
|
-
[place, { :require => false }]
|
14
|
-
end
|
15
|
-
end
|
16
|
-
|
17
|
-
|
18
|
-
# We don't put beaker in as a test dependency because we
|
19
|
-
# don't want to create a transitive dependency
|
20
|
-
group :acceptance_testing do
|
21
|
-
gem "beaker", *location_for(ENV['BEAKER_VERSION'] || '~> 4.0')
|
22
|
-
end
|
23
|
-
|
24
|
-
|
25
|
-
if File.exists? "#{__FILE__}.local"
|
26
|
-
eval(File.read("#{__FILE__}.local"), binding)
|
4
|
+
group :release do
|
5
|
+
gem 'github_changelog_generator', require: false
|
27
6
|
end
|
data/README.md
CHANGED
@@ -1,10 +1,18 @@
|
|
1
1
|
# beaker-vagrant
|
2
2
|
|
3
|
+
[![License](https://img.shields.io/github/license/voxpupuli/beaker-vagrant.svg)](https://github.com/voxpupuli/beaker-vagrant/blob/master/LICENSE)
|
4
|
+
[![Test](https://github.com/voxpupuli/beaker-vagrant/actions/workflows/test.yml/badge.svg)](https://github.com/voxpupuli/beaker-vagrant/actions/workflows/test.yml)
|
5
|
+
[![codecov](https://codecov.io/gh/voxpupuli/beaker-vagrant/branch/master/graph/badge.svg?token=Mypkl78hvK)](https://codecov.io/gh/voxpupuli/beaker-vagrant)
|
6
|
+
[![Release](https://github.com/voxpupuli/beaker-vagrant/actions/workflows/release.yml/badge.svg)](https://github.com/voxpupuli/beaker-vagrant/actions/workflows/release.yml)
|
7
|
+
[![RubyGem Version](https://img.shields.io/gem/v/beaker-vagrant.svg)](https://rubygems.org/gems/beaker-vagrant)
|
8
|
+
[![RubyGem Downloads](https://img.shields.io/gem/dt/beaker-vagrant.svg)](https://rubygems.org/gems/beaker-vagrant)
|
9
|
+
[![Donated by Puppet Inc](https://img.shields.io/badge/donated%20by-Puppet%20Inc-fb7047.svg)](#transfer-notice)
|
10
|
+
|
3
11
|
Beaker library to use vagrant hypervisor
|
4
12
|
|
5
13
|
# How to use this wizardry
|
6
14
|
|
7
|
-
This is a gem that allows you to use hosts with [vagrant](docs/vagrant.md) hypervisor with [beaker](https://github.com/
|
15
|
+
This is a gem that allows you to use hosts with [vagrant](docs/vagrant.md) hypervisor with [beaker](https://github.com/voxpupuli/beaker).
|
8
16
|
|
9
17
|
## With Beaker 3.x
|
10
18
|
|
@@ -37,15 +45,24 @@ We run beaker's base acceptance tests with this library to see if the hypervisor
|
|
37
45
|
bundle exec rake test:acceptance
|
38
46
|
```
|
39
47
|
|
40
|
-
|
48
|
+
## Transfer Notice
|
49
|
+
|
50
|
+
This plugin was originally authored by [Puppet Inc](http://puppet.com).
|
51
|
+
The maintainer preferred that Puppet Community take ownership of the module for future improvement and maintenance.
|
52
|
+
Existing pull requests and issues were transferred over, please fork and continue to contribute here.
|
53
|
+
|
54
|
+
Previously: https://github.com/puppetlabs/beaker
|
41
55
|
|
42
|
-
|
56
|
+
## License
|
43
57
|
|
44
|
-
|
58
|
+
This gem is licensed under the Apache-2 license.
|
45
59
|
|
46
|
-
|
47
|
-
[Jenkins job](https://jenkins-sre.delivery.puppetlabs.net/view/all/job/qe_beaker-vagrant_init-multijob_master/)
|
48
|
-
(access to internal infrastructure will be required to view job).
|
60
|
+
## Release information
|
49
61
|
|
50
|
-
To
|
51
|
-
|
62
|
+
To make a new release, please do:
|
63
|
+
* update the version in `lib/beaker-vagrant/version.rb`
|
64
|
+
* Install gems with `bundle install --with release --path .vendor`
|
65
|
+
* generate the changelog with `bundle exec rake changelog`
|
66
|
+
* Check if the new version matches the closed issues/PRs in the changelog
|
67
|
+
* Create a PR with it
|
68
|
+
* After it got merged, push a tag. GitHub actions will do the actual release to rubygems and GitHub Packages
|
data/Rakefile
CHANGED
@@ -1,47 +1,40 @@
|
|
1
1
|
require 'rspec/core/rake_task'
|
2
2
|
|
3
3
|
namespace :test do
|
4
|
-
|
5
4
|
namespace :spec do
|
6
|
-
|
7
|
-
desc "Run spec tests"
|
5
|
+
desc 'Run spec tests'
|
8
6
|
RSpec::Core::RakeTask.new(:run) do |t|
|
9
7
|
t.rspec_opts = ['--color', '--format documentation']
|
10
8
|
t.pattern = 'spec/'
|
11
9
|
end
|
12
10
|
|
13
|
-
desc
|
11
|
+
desc 'Run spec tests with coverage'
|
14
12
|
RSpec::Core::RakeTask.new(:coverage) do |t|
|
15
13
|
ENV['BEAKER_TEMPLATE_COVERAGE'] = 'y'
|
16
14
|
t.rspec_opts = ['--color', '--format documentation']
|
17
15
|
t.pattern = 'spec/'
|
18
16
|
end
|
19
|
-
|
20
17
|
end
|
21
18
|
|
22
19
|
namespace :acceptance do
|
23
|
-
|
24
|
-
|
25
|
-
A quick acceptance test, named because it has no pre-suites to run
|
20
|
+
desc <<~EOS
|
21
|
+
A quick acceptance test, named because it has no pre-suites to run
|
26
22
|
EOS
|
27
23
|
task :quick do
|
28
|
-
|
29
24
|
# setup & load_path of beaker's acceptance base and lib directory
|
30
25
|
beaker_gem_spec = Gem::Specification.find_by_name('beaker')
|
31
26
|
beaker_gem_dir = beaker_gem_spec.gem_dir
|
32
27
|
beaker_test_base_dir = File.join(beaker_gem_dir, 'acceptance/tests/base')
|
33
28
|
load_path_option = File.join(beaker_gem_dir, 'acceptance/lib')
|
34
29
|
|
35
|
-
sh(
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
30
|
+
sh('beaker',
|
31
|
+
'--hosts', 'acceptance/config/nodes/redhat-nodes.yml',
|
32
|
+
'--tests', beaker_test_base_dir,
|
33
|
+
'--log-level', 'debug',
|
34
|
+
'--load-path', load_path_option,
|
35
|
+
'--keyfile', ENV['KEY'] || "#{ENV.fetch('HOME', nil)}/.ssh/id_rsa")
|
41
36
|
end
|
42
|
-
|
43
37
|
end
|
44
|
-
|
45
38
|
end
|
46
39
|
|
47
40
|
# namespace-named default tasks.
|
@@ -51,111 +44,32 @@ task 'test:spec' => 'test:spec:run'
|
|
51
44
|
task 'test:acceptance' => 'test:acceptance:quick'
|
52
45
|
|
53
46
|
# global defaults
|
54
|
-
task :
|
55
|
-
task :
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
#
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
found = ps.lines.grep( /#{Regexp.quote( cmdline )}/ )
|
68
|
-
if found.length > 1
|
69
|
-
raise StandardError, "Found multiple YARD Servers. Don't know what to do."
|
47
|
+
task test: 'test:spec'
|
48
|
+
task default: :test
|
49
|
+
|
50
|
+
begin
|
51
|
+
require 'rubocop/rake_task'
|
52
|
+
rescue LoadError
|
53
|
+
# RuboCop is an optional group
|
54
|
+
else
|
55
|
+
RuboCop::RakeTask.new(:rubocop) do |task|
|
56
|
+
# These make the rubocop experience maybe slightly less terrible
|
57
|
+
task.options = ['--display-cop-names', '--display-style-guide', '--extra-details']
|
58
|
+
# Use Rubocop's Github Actions formatter if possible
|
59
|
+
task.formatters << 'github' if ENV['GITHUB_ACTIONS'] == 'true'
|
70
60
|
end
|
71
|
-
|
72
|
-
yes = found.empty? ? false : true
|
73
|
-
return yes, found.first
|
74
|
-
end
|
75
|
-
|
76
|
-
def pid_from( output )
|
77
|
-
output.squeeze(' ').strip.split(' ')[1]
|
78
|
-
end
|
79
|
-
|
80
|
-
desc 'Start the documentation server in the foreground'
|
81
|
-
task :docs => 'docs:clear' do
|
82
|
-
original_dir = Dir.pwd
|
83
|
-
Dir.chdir( File.expand_path(File.dirname(__FILE__)) )
|
84
|
-
sh FOREGROUND_SERVER
|
85
|
-
Dir.chdir( original_dir )
|
86
61
|
end
|
87
62
|
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
task :gen => 'docs:clear' do
|
100
|
-
original_dir = Dir.pwd
|
101
|
-
Dir.chdir( File.expand_path(File.dirname(__FILE__)) )
|
102
|
-
output = `bundle exec yard doc`
|
103
|
-
puts output
|
104
|
-
if output =~ /\[warn\]|\[error\]/
|
105
|
-
fail "Errors/Warnings during yard documentation generation"
|
106
|
-
end
|
107
|
-
Dir.chdir( original_dir )
|
108
|
-
end
|
109
|
-
|
110
|
-
desc 'Run the documentation server in the background, alias `bg`'
|
111
|
-
task :background => 'docs:clear' do
|
112
|
-
yes, output = running?( DOCS_DAEMON )
|
113
|
-
if yes
|
114
|
-
puts "Not starting a new YARD Server..."
|
115
|
-
puts "Found one running with pid #{pid_from( output )}."
|
116
|
-
else
|
117
|
-
original_dir = Dir.pwd
|
118
|
-
Dir.chdir( File.expand_path(File.dirname(__FILE__)) )
|
119
|
-
sh "bundle exec #{DOCS_DAEMON}"
|
120
|
-
Dir.chdir( original_dir )
|
121
|
-
end
|
122
|
-
end
|
123
|
-
|
124
|
-
task(:bg) { Rake::Task['docs:background'].invoke }
|
125
|
-
|
126
|
-
desc 'Check the status of the documentation server'
|
127
|
-
task :status do
|
128
|
-
yes, output = running?( DOCS_DAEMON )
|
129
|
-
if yes
|
130
|
-
pid = pid_from( output )
|
131
|
-
puts "Found a YARD Server running with pid #{pid}"
|
132
|
-
else
|
133
|
-
puts "Could not find a running YARD Server."
|
134
|
-
end
|
135
|
-
end
|
136
|
-
|
137
|
-
desc "Stop a running YARD Server"
|
138
|
-
task :stop do
|
139
|
-
yes, output = running?( DOCS_DAEMON )
|
140
|
-
if yes
|
141
|
-
pid = pid_from( output )
|
142
|
-
puts "Found a YARD Server running with pid #{pid}"
|
143
|
-
`kill #{pid}`
|
144
|
-
puts "Stopping..."
|
145
|
-
yes, output = running?( DOCS_DAEMON )
|
146
|
-
if yes
|
147
|
-
`kill -9 #{pid}`
|
148
|
-
yes, output = running?( DOCS_DAEMON )
|
149
|
-
if yes
|
150
|
-
puts "Could not Stop Server!"
|
151
|
-
else
|
152
|
-
puts "Server stopped."
|
153
|
-
end
|
154
|
-
else
|
155
|
-
puts "Server stopped."
|
156
|
-
end
|
157
|
-
else
|
158
|
-
puts "Could not find a running YARD Server"
|
159
|
-
end
|
63
|
+
begin
|
64
|
+
require 'github_changelog_generator/task'
|
65
|
+
rescue LoadError
|
66
|
+
# Do nothing if no required gem installed
|
67
|
+
else
|
68
|
+
GitHubChangelogGenerator::RakeTask.new :changelog do |config|
|
69
|
+
config.exclude_labels = %w[duplicate question invalid wontfix wont-fix skip-changelog]
|
70
|
+
config.user = 'voxpupuli'
|
71
|
+
config.project = 'beaker-vagrant'
|
72
|
+
gem_version = Gem::Specification.load("#{config.project}.gemspec").version
|
73
|
+
config.future_release = gem_version
|
160
74
|
end
|
161
75
|
end
|
data/beaker-vagrant.gemspec
CHANGED
@@ -1,37 +1,37 @@
|
|
1
|
-
|
2
|
-
$LOAD_PATH.unshift File.expand_path("../lib", __FILE__)
|
1
|
+
$LOAD_PATH.unshift File.expand_path('lib', __dir__)
|
3
2
|
require 'beaker-vagrant/version'
|
4
3
|
|
5
4
|
Gem::Specification.new do |s|
|
6
|
-
s.name =
|
5
|
+
s.name = 'beaker-vagrant'
|
7
6
|
s.version = BeakerVagrant::VERSION
|
8
|
-
s.authors = [
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
7
|
+
s.authors = [
|
8
|
+
'Vox Pupuli',
|
9
|
+
'Rishi Javia',
|
10
|
+
'Kevin Imber',
|
11
|
+
'Tony Vu',
|
12
|
+
]
|
13
|
+
s.email = 'voxpupuli@groups.io'
|
14
|
+
s.homepage = 'https://github.com/puppetlabs/beaker-vagrant'
|
15
|
+
s.summary = 'Beaker DSL Extension Helpers!'
|
16
|
+
s.description = 'For use for the Beaker acceptance testing tool'
|
13
17
|
s.license = 'Apache2'
|
14
18
|
|
19
|
+
s.required_ruby_version = Gem::Requirement.new('>= 2.7')
|
20
|
+
|
15
21
|
s.files = `git ls-files`.split("\n")
|
16
|
-
s.
|
17
|
-
s.
|
18
|
-
s.require_paths = ["lib"]
|
22
|
+
s.executables = `git ls-files -- bin/*`.split("\n").map { |f| File.basename(f) }
|
23
|
+
s.require_paths = ['lib']
|
19
24
|
|
20
25
|
# Testing dependencies
|
21
|
-
s.add_development_dependency '
|
22
|
-
s.add_development_dependency '
|
23
|
-
# pin fakefs for Ruby < 2.3
|
24
|
-
if RUBY_VERSION < "2.3"
|
25
|
-
s.add_development_dependency 'fakefs', '~> 0.6', '< 0.14'
|
26
|
-
else
|
27
|
-
s.add_development_dependency 'fakefs', '>= 0.6', '< 2.0'
|
28
|
-
end
|
26
|
+
s.add_development_dependency 'fakefs', '>= 0.6', '< 3.0'
|
27
|
+
s.add_development_dependency 'pry', '~> 0.10'
|
29
28
|
s.add_development_dependency 'rake', '~> 13.0'
|
29
|
+
s.add_development_dependency 'rspec', '~> 3.0'
|
30
|
+
s.add_development_dependency 'rubocop', '~> 1.48.1'
|
31
|
+
s.add_development_dependency 'rubocop-performance'
|
32
|
+
s.add_development_dependency 'rubocop-rake'
|
33
|
+
s.add_development_dependency 'rubocop-rspec'
|
30
34
|
s.add_development_dependency 'simplecov'
|
31
|
-
s.add_development_dependency 'pry', '~> 0.10'
|
32
35
|
|
33
|
-
|
34
|
-
s.add_development_dependency 'yard'
|
35
|
-
s.add_development_dependency 'thin'
|
36
|
+
s.add_runtime_dependency 'beaker', '~> 5'
|
36
37
|
end
|
37
|
-
|
data/bin/beaker-vagrant
CHANGED