beaker 4.40.2 → 5.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (217) hide show
  1. checksums.yaml +4 -4
  2. data/.github/dependabot.yml +9 -0
  3. data/.github/workflows/release.yml +2 -2
  4. data/.github/workflows/test.yml +26 -13
  5. data/.rubocop.yml +23 -10
  6. data/.rubocop_todo.yml +34 -10
  7. data/CHANGELOG.md +17 -28
  8. data/Gemfile +12 -7
  9. data/Rakefile +99 -111
  10. data/acceptance/config/acceptance-options.rb +1 -1
  11. data/acceptance/config/base/acceptance-options.rb +2 -2
  12. data/acceptance/config/hypervisor/acceptance-options.rb +2 -2
  13. data/acceptance/config/subcommands/acceptance-options.rb +2 -2
  14. data/acceptance/fixtures/module/Rakefile +1 -1
  15. data/acceptance/fixtures/module/spec/acceptance/demo_spec.rb +8 -12
  16. data/acceptance/fixtures/module/spec/classes/init_spec.rb +0 -1
  17. data/acceptance/fixtures/module/spec/spec_helper_acceptance.rb +3 -5
  18. data/acceptance/lib/helpers/test_helper.rb +6 -5
  19. data/acceptance/pre_suite/subcommands/05_install_ruby.rb +2 -3
  20. data/acceptance/pre_suite/subcommands/08_install_beaker.rb +1 -2
  21. data/acceptance/tests/base/dsl/helpers/configuration_test.rb +4 -4
  22. data/acceptance/tests/base/dsl/helpers/hocon_helpers_test.rb +1 -2
  23. data/acceptance/tests/base/dsl/helpers/host_helpers/add_system32_hosts_entry_test.rb +0 -3
  24. data/acceptance/tests/base/dsl/helpers/host_helpers/archive_file_from_test.rb +3 -1
  25. data/acceptance/tests/base/dsl/helpers/host_helpers/backup_the_file_test.rb +9 -9
  26. data/acceptance/tests/base/dsl/helpers/host_helpers/check_for_package_test.rb +0 -4
  27. data/acceptance/tests/base/dsl/helpers/host_helpers/create_remote_file_test.rb +19 -26
  28. data/acceptance/tests/base/dsl/helpers/host_helpers/curl_on_test.rb +2 -2
  29. data/acceptance/tests/base/dsl/helpers/host_helpers/curl_with_retries_test.rb +0 -1
  30. data/acceptance/tests/base/dsl/helpers/host_helpers/on_test.rb +18 -13
  31. data/acceptance/tests/base/dsl/helpers/host_helpers/retry_on_test.rb +3 -3
  32. data/acceptance/tests/base/dsl/helpers/host_helpers/rsync_to_test.rb +22 -27
  33. data/acceptance/tests/base/dsl/helpers/host_helpers/run_cron_on_test.rb +12 -16
  34. data/acceptance/tests/base/dsl/helpers/host_helpers/run_script_on_test.rb +3 -4
  35. data/acceptance/tests/base/dsl/helpers/host_helpers/run_script_test.rb +3 -3
  36. data/acceptance/tests/base/dsl/helpers/host_helpers/scp_from_test.rb +4 -4
  37. data/acceptance/tests/base/dsl/helpers/host_helpers/scp_to_test.rb +3 -4
  38. data/acceptance/tests/base/dsl/helpers/host_helpers/shell_test.rb +5 -5
  39. data/acceptance/tests/base/dsl/helpers/host_helpers/upgrade_package_test.rb +3 -5
  40. data/acceptance/tests/base/dsl/platform_tag_confiner_test.rb +14 -17
  41. data/acceptance/tests/base/dsl/structure_test.rb +5 -11
  42. data/acceptance/tests/base/host/file_test.rb +2 -2
  43. data/acceptance/tests/base/host/group_test.rb +0 -1
  44. data/acceptance/tests/base/host/host_test.rb +66 -63
  45. data/acceptance/tests/base/host/packages.rb +1 -2
  46. data/acceptance/tests/base/host/packages_unix.rb +0 -55
  47. data/acceptance/tests/base/host/user_test.rb +0 -1
  48. data/acceptance/tests/base/host_prebuilt_steps/ssh_environment_test.rb +1 -2
  49. data/acceptance/tests/base/test_suite/export.rb +6 -9
  50. data/acceptance/tests/install/from_file.rb +2 -4
  51. data/acceptance/tests/load_path_bootstrap.rb +1 -1
  52. data/acceptance/tests/subcommands/destroy.rb +19 -21
  53. data/acceptance/tests/subcommands/exec.rb +0 -1
  54. data/acceptance/tests/subcommands/init.rb +2 -3
  55. data/acceptance/tests/subcommands/provision.rb +0 -1
  56. data/beaker.gemspec +4 -7
  57. data/docs/concepts/argument_processing_and_precedence.md +1 -10
  58. data/docs/how_to/debug_beaker_tests.md +12 -12
  59. data/docs/how_to/hosts/eos.md +2 -12
  60. data/docs/how_to/install_puppet.md +0 -18
  61. data/docs/how_to/the_beaker_dsl.md +0 -2
  62. data/lib/beaker/cli.rb +59 -68
  63. data/lib/beaker/command.rb +20 -28
  64. data/lib/beaker/command_factory.rb +3 -2
  65. data/lib/beaker/dsl/assertions.rb +6 -18
  66. data/lib/beaker/dsl/helpers/hocon_helpers.rb +3 -7
  67. data/lib/beaker/dsl/helpers/host_helpers.rb +62 -123
  68. data/lib/beaker/dsl/helpers/test_helpers.rb +3 -5
  69. data/lib/beaker/dsl/helpers/web_helpers.rb +19 -39
  70. data/lib/beaker/dsl/helpers.rb +2 -4
  71. data/lib/beaker/dsl/outcomes.rb +13 -15
  72. data/lib/beaker/dsl/patterns.rb +1 -3
  73. data/lib/beaker/dsl/roles.rb +17 -20
  74. data/lib/beaker/dsl/structure.rb +53 -65
  75. data/lib/beaker/dsl/test_tagging.rb +7 -10
  76. data/lib/beaker/dsl/wrappers.rb +15 -16
  77. data/lib/beaker/dsl.rb +2 -3
  78. data/lib/beaker/host/aix/exec.rb +1 -1
  79. data/lib/beaker/host/aix/file.rb +0 -1
  80. data/lib/beaker/host/aix/group.rb +1 -1
  81. data/lib/beaker/host/aix/user.rb +1 -1
  82. data/lib/beaker/host/aix.rb +3 -4
  83. data/lib/beaker/host/cisco.rb +27 -39
  84. data/lib/beaker/host/eos.rb +4 -30
  85. data/lib/beaker/host/freebsd/exec.rb +1 -1
  86. data/lib/beaker/host/freebsd/pkg.rb +3 -3
  87. data/lib/beaker/host/freebsd.rb +9 -12
  88. data/lib/beaker/host/mac/exec.rb +4 -4
  89. data/lib/beaker/host/mac/group.rb +7 -7
  90. data/lib/beaker/host/mac/pkg.rb +3 -106
  91. data/lib/beaker/host/mac/user.rb +2 -2
  92. data/lib/beaker/host/mac.rb +8 -9
  93. data/lib/beaker/host/pswindows/exec.rb +66 -70
  94. data/lib/beaker/host/pswindows/file.rb +3 -5
  95. data/lib/beaker/host/pswindows/group.rb +3 -3
  96. data/lib/beaker/host/pswindows/pkg.rb +12 -12
  97. data/lib/beaker/host/pswindows/user.rb +3 -3
  98. data/lib/beaker/host/pswindows.rb +4 -3
  99. data/lib/beaker/host/unix/exec.rb +80 -82
  100. data/lib/beaker/host/unix/file.rb +38 -43
  101. data/lib/beaker/host/unix/group.rb +1 -1
  102. data/lib/beaker/host/unix/pkg.rb +154 -417
  103. data/lib/beaker/host/unix/user.rb +2 -2
  104. data/lib/beaker/host/unix.rb +8 -11
  105. data/lib/beaker/host/windows/exec.rb +17 -17
  106. data/lib/beaker/host/windows/file.rb +3 -3
  107. data/lib/beaker/host/windows/group.rb +3 -3
  108. data/lib/beaker/host/windows/pkg.rb +3 -54
  109. data/lib/beaker/host/windows/user.rb +3 -3
  110. data/lib/beaker/host/windows.rb +12 -12
  111. data/lib/beaker/host.rb +76 -133
  112. data/lib/beaker/host_prebuilt_steps.rb +93 -198
  113. data/lib/beaker/hypervisor/noop.rb +2 -4
  114. data/lib/beaker/hypervisor.rb +44 -61
  115. data/lib/beaker/local_connection.rb +2 -4
  116. data/lib/beaker/logger.rb +68 -76
  117. data/lib/beaker/logger_junit.rb +21 -25
  118. data/lib/beaker/network_manager.rb +39 -42
  119. data/lib/beaker/options/command_line_parser.rb +12 -23
  120. data/lib/beaker/options/hosts_file_parser.rb +16 -24
  121. data/lib/beaker/options/options_file_parser.rb +3 -6
  122. data/lib/beaker/options/options_hash.rb +2 -7
  123. data/lib/beaker/options/parser.rb +86 -102
  124. data/lib/beaker/options/presets.rb +114 -123
  125. data/lib/beaker/options/subcommand_options_file_parser.rb +3 -6
  126. data/lib/beaker/options/validator.rb +26 -31
  127. data/lib/beaker/perf.rb +22 -27
  128. data/lib/beaker/platform.rb +38 -46
  129. data/lib/beaker/result.rb +7 -6
  130. data/lib/beaker/shared/error_handler.rb +8 -10
  131. data/lib/beaker/shared/fog_credentials.rb +5 -9
  132. data/lib/beaker/shared/host_manager.rb +36 -41
  133. data/lib/beaker/shared/options_resolver.rb +3 -7
  134. data/lib/beaker/shared/repetition.rb +2 -4
  135. data/lib/beaker/shared/semvar.rb +37 -41
  136. data/lib/beaker/shared/timed.rb +0 -3
  137. data/lib/beaker/shared.rb +1 -1
  138. data/lib/beaker/ssh_connection.rb +38 -47
  139. data/lib/beaker/subcommand.rb +17 -24
  140. data/lib/beaker/subcommands/subcommand_util.rb +4 -4
  141. data/lib/beaker/tasks/quick_start.rb +4 -9
  142. data/lib/beaker/tasks/rake_task.rb +25 -27
  143. data/lib/beaker/tasks/test.rb +4 -4
  144. data/lib/beaker/test_case.rb +16 -28
  145. data/lib/beaker/test_suite.rb +35 -39
  146. data/lib/beaker/test_suite_result.rb +45 -47
  147. data/lib/beaker/version.rb +1 -1
  148. data/lib/beaker.rb +6 -7
  149. data/spec/beaker/cli_spec.rb +121 -142
  150. data/spec/beaker/command_spec.rb +55 -59
  151. data/spec/beaker/dsl/assertions_spec.rb +36 -36
  152. data/spec/beaker/dsl/helpers/host_helpers_spec.rb +110 -131
  153. data/spec/beaker/dsl/helpers/test_helpers_spec.rb +9 -10
  154. data/spec/beaker/dsl/helpers/web_helpers_spec.rb +22 -31
  155. data/spec/beaker/dsl/outcomes_spec.rb +14 -14
  156. data/spec/beaker/dsl/roles_spec.rb +125 -130
  157. data/spec/beaker/dsl/structure_spec.rb +172 -161
  158. data/spec/beaker/dsl/test_tagging_spec.rb +89 -90
  159. data/spec/beaker/dsl/wrappers_spec.rb +32 -33
  160. data/spec/beaker/host/aix_spec.rb +14 -14
  161. data/spec/beaker/host/cisco_spec.rb +84 -94
  162. data/spec/beaker/host/eos_spec.rb +15 -36
  163. data/spec/beaker/host/freebsd/exec_spec.rb +3 -6
  164. data/spec/beaker/host/freebsd/pkg_spec.rb +24 -27
  165. data/spec/beaker/host/mac/exec_spec.rb +2 -3
  166. data/spec/beaker/host/mac/group_spec.rb +48 -57
  167. data/spec/beaker/host/mac/user_spec.rb +54 -63
  168. data/spec/beaker/host/pswindows/exec_spec.rb +30 -32
  169. data/spec/beaker/host/pswindows/file_spec.rb +16 -16
  170. data/spec/beaker/host/pswindows/user_spec.rb +17 -23
  171. data/spec/beaker/host/pswindows_spec.rb +13 -13
  172. data/spec/beaker/host/unix/exec_spec.rb +75 -80
  173. data/spec/beaker/host/unix/file_spec.rb +66 -73
  174. data/spec/beaker/host/unix/pkg_spec.rb +155 -401
  175. data/spec/beaker/host/unix_spec.rb +11 -207
  176. data/spec/beaker/host/windows/exec_spec.rb +30 -32
  177. data/spec/beaker/host/windows/file_spec.rb +18 -19
  178. data/spec/beaker/host/windows/group_spec.rb +10 -12
  179. data/spec/beaker/host/windows/pkg_spec.rb +6 -9
  180. data/spec/beaker/host/windows/user_spec.rb +17 -23
  181. data/spec/beaker/host/windows_spec.rb +39 -39
  182. data/spec/beaker/host_prebuilt_steps_spec.rb +172 -326
  183. data/spec/beaker/host_spec.rb +204 -284
  184. data/spec/beaker/hypervisor/hypervisor_spec.rb +36 -61
  185. data/spec/beaker/localhost_connection_spec.rb +10 -11
  186. data/spec/beaker/logger_junit_spec.rb +19 -30
  187. data/spec/beaker/logger_spec.rb +153 -136
  188. data/spec/beaker/network_manager_spec.rb +23 -23
  189. data/spec/beaker/options/command_line_parser_spec.rb +20 -23
  190. data/spec/beaker/options/hosts_file_parser_spec.rb +30 -32
  191. data/spec/beaker/options/options_file_parser_spec.rb +4 -7
  192. data/spec/beaker/options/options_hash_spec.rb +4 -6
  193. data/spec/beaker/options/parser_spec.rb +167 -167
  194. data/spec/beaker/options/presets_spec.rb +7 -9
  195. data/spec/beaker/options/subcommand_options_parser_spec.rb +13 -14
  196. data/spec/beaker/options/validator_spec.rb +10 -11
  197. data/spec/beaker/perf_spec.rb +18 -21
  198. data/spec/beaker/platform_spec.rb +25 -36
  199. data/spec/beaker/shared/error_handler_spec.rb +7 -16
  200. data/spec/beaker/shared/fog_credentials_spec.rb +29 -29
  201. data/spec/beaker/shared/host_manager_spec.rb +50 -84
  202. data/spec/beaker/shared/options_resolver_spec.rb +9 -12
  203. data/spec/beaker/shared/repetition_spec.rb +17 -24
  204. data/spec/beaker/shared/semvar_spec.rb +21 -26
  205. data/spec/beaker/ssh_connection_spec.rb +76 -83
  206. data/spec/beaker/subcommand/subcommand_util_spec.rb +31 -33
  207. data/spec/beaker/subcommand_spec.rb +75 -77
  208. data/spec/beaker/test_case_spec.rb +25 -50
  209. data/spec/beaker/test_suite_spec.rb +147 -154
  210. data/spec/helpers.rb +48 -53
  211. data/spec/matchers.rb +8 -7
  212. data/spec/mocks.rb +1 -6
  213. data/spec/spec_helper.rb +0 -1
  214. metadata +7 -24
  215. data/acceptance/tests/base/dsl/helpers/host_helpers/deploy_package_repo_test.rb +0 -142
  216. data/acceptance/tests/base/external_resources_test.rb +0 -31
  217. data/spec/beaker/host/mac_spec.rb +0 -113
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f20284823ba7135cb7d216cb4c5680fc96846ed43eb9103f015e183070049041
4
- data.tar.gz: a4b459893307c1a792a53c7794ca5bb86d8997b87f928103511b96fe84e328cf
3
+ metadata.gz: a779fedc9b7695d5a76a9731765e8ed5c5b8f9f1945563c2108cd0d0e01f564a
4
+ data.tar.gz: d5613d1aa5a289aff25f948229f5d8c89bec28fa25ec6ae310f446e95dd44363
5
5
  SHA512:
6
- metadata.gz: '00409a147c67f50a438215422b247fa691918dd58d48951f984f1e25223b368e29bccda577aee39a71befaee233c5ce1a28afa87b297f537fa4590bc5b833a16'
7
- data.tar.gz: 56a82b85aa6da9f4344cee95ffe92ab3e9a7d6d9a24f7dda5bdf61c7b552541420045646f644e47ecce0b239e6e99b81a1202dcd1336fc0bcbee9fe80b85c3bd
6
+ metadata.gz: 33dae1fd1af4921f1fd3f00e18413a1a823749444fbed1c1fae0ed967cf055988a31692ceba29d5535bba8b1283f0b6ec0535cf21b589ecfc9f55c0d6498f51b
7
+ data.tar.gz: 8ccefb72d40022e47506fdd6ab8307318fbcd3eb736f89f965368de923e65b52e14a3faac8ea4afcb7aad3d3c80e059a9ce665578d18f32c01ff073675b75387
@@ -1,8 +1,17 @@
1
1
  version: 2
2
2
  updates:
3
+ # raise PRs for gem updates
3
4
  - package-ecosystem: bundler
4
5
  directory: "/"
5
6
  schedule:
6
7
  interval: daily
7
8
  time: "13:00"
8
9
  open-pull-requests-limit: 10
10
+
11
+ # Maintain dependencies for GitHub Actions
12
+ - package-ecosystem: github-actions
13
+ directory: "/"
14
+ schedule:
15
+ interval: daily
16
+ time: "13:00"
17
+ open-pull-requests-limit: 10
@@ -10,13 +10,13 @@ jobs:
10
10
  runs-on: ubuntu-latest
11
11
  if: github.repository_owner == 'voxpupuli'
12
12
  steps:
13
- - uses: actions/checkout@v2
13
+ - uses: actions/checkout@v3
14
14
  - name: Install Ruby 3.0
15
15
  uses: ruby/setup-ruby@v1
16
16
  with:
17
17
  ruby-version: '3.0'
18
18
  env:
19
- BUNDLE_WITHOUT: release
19
+ BUNDLE_WITHOUT: release:development:rubocop
20
20
  - name: Build gem
21
21
  run: gem build *.gemspec
22
22
  - name: Publish gem to rubygems.org
@@ -1,42 +1,44 @@
1
1
  name: Test
2
2
 
3
3
  on:
4
- - pull_request
5
- - push
6
-
7
- env:
8
- BUNDLE_WITHOUT: release
4
+ pull_request: {}
5
+ push:
6
+ branches:
7
+ - master
9
8
 
10
9
  jobs:
11
10
  rubocop:
11
+ env:
12
+ BUNDLE_WITHOUT: release
12
13
  runs-on: ubuntu-latest
13
14
  steps:
14
15
  - uses: actions/checkout@v3
15
16
  - name: Install Ruby ${{ matrix.ruby }}
16
17
  uses: ruby/setup-ruby@v1
17
18
  with:
18
- ruby-version: "3.1"
19
+ ruby-version: "3.2"
19
20
  bundler-cache: true
20
21
  - name: Run Rubocop
21
- run: bundle exec rubocop --format github
22
+ run: bundle exec rake rubocop
22
23
 
23
24
  test:
24
- runs-on: ubuntu-latest
25
+ # CentOS 7 testing is broken on Ubuntu 22.04
26
+ runs-on: ubuntu-20.04
25
27
  strategy:
26
28
  fail-fast: false
27
29
  matrix:
28
30
  include:
29
- - ruby: "2.4"
30
- - ruby: "2.5"
31
- - ruby: "2.6"
32
31
  - ruby: "2.7"
33
32
  - ruby: "3.0"
34
33
  - ruby: "3.1"
34
+ - ruby: "3.2"
35
35
  coverage: "yes"
36
36
  env:
37
37
  COVERAGE: ${{ matrix.coverage }}
38
+ BUNDLE_WITHOUT: release:rubocop
39
+ BEAKER_HYPERVISOR: docker
38
40
  steps:
39
- - uses: actions/checkout@v2
41
+ - uses: actions/checkout@v3
40
42
  - name: Install Ruby ${{ matrix.ruby }}
41
43
  uses: ruby/setup-ruby@v1
42
44
  with:
@@ -44,5 +46,16 @@ jobs:
44
46
  bundler-cache: true
45
47
  - name: Build gem
46
48
  run: gem build *.gemspec
47
- - name: Run tests
49
+ - name: Run unit tests
48
50
  run: bundle exec rake spec
51
+ - name: Run acceptance tests
52
+ run: bundle exec rake acceptance
53
+
54
+ tests:
55
+ needs:
56
+ - rubocop
57
+ - test
58
+ runs-on: ubuntu-latest
59
+ name: Test suite
60
+ steps:
61
+ - run: echo Test suite completed
data/.rubocop.yml CHANGED
@@ -7,25 +7,32 @@ require:
7
7
  - rubocop-rspec
8
8
 
9
9
  AllCops:
10
+ TargetRubyVersion: 2.7
10
11
  NewCops: enable
11
12
 
12
- Layout/ArgumentAlignment:
13
+ Gemspec/RequireMFA:
13
14
  Enabled: false
14
15
 
16
+ Gemspec/DevelopmentDependencies:
17
+ Enabled: false
18
+
19
+ Style/TrailingCommaInHashLiteral:
20
+ Enabled: True
21
+ EnforcedStyleForMultiline: consistent_comma
22
+
23
+ Style/TrailingCommaInArrayLiteral:
24
+ Enabled: True
25
+ EnforcedStyleForMultiline: consistent_comma
26
+
27
+ Style/TrailingCommaInArguments:
28
+ Enabled: True
29
+ EnforcedStyleForMultiline: comma
30
+
15
31
  Layout/LineLength:
16
32
  Exclude:
17
33
  - acceptance/**/*.rb
18
34
  - spec/**/*.rb
19
35
 
20
- Layout:
21
- Enabled: false
22
-
23
- Metrics:
24
- Enabled: false
25
-
26
- Style:
27
- Enabled: false
28
-
29
36
  Naming/AccessorMethodName:
30
37
  Enabled: false
31
38
 
@@ -60,3 +67,9 @@ RSpec/MultipleExpectations:
60
67
 
61
68
  RSpec/NestedGroups:
62
69
  Max: 4
70
+
71
+ Metrics:
72
+ Enabled: false
73
+
74
+ Style:
75
+ Enabled: false
data/.rubocop_todo.yml CHANGED
@@ -1,6 +1,6 @@
1
1
  # This configuration was generated by
2
2
  # `rubocop --auto-gen-config --no-offense-counts --no-auto-gen-timestamp`
3
- # using RuboCop version 1.12.1.
3
+ # using RuboCop version 1.48.0.
4
4
  # The point is for the user to remove these configuration records
5
5
  # one by one as the offenses are removed from the code base.
6
6
  # Note that changes in the inspected code, or installation of new
@@ -35,10 +35,10 @@ Lint/EmptyBlock:
35
35
  - 'spec/beaker/logger_junit_spec.rb'
36
36
  - 'spec/beaker/logger_spec.rb'
37
37
 
38
- Lint/MissingSuper:
38
+ # This cop supports unsafe autocorrection (--autocorrect-all).
39
+ Lint/NonAtomicFileOperation:
39
40
  Exclude:
40
- - 'lib/beaker/hypervisor/noop.rb'
41
- - 'lib/beaker/tasks/rake_task.rb'
41
+ - 'acceptance/tests/base/dsl/helpers/host_helpers/archive_file_from_test.rb'
42
42
 
43
43
  Lint/RescueException:
44
44
  Exclude:
@@ -63,7 +63,7 @@ Lint/UselessAssignment:
63
63
  - 'lib/beaker/logger_junit.rb'
64
64
 
65
65
  # Configuration parameters: ForbiddenDelimiters.
66
- # ForbiddenDelimiters: (?-mix:(^|\s)(EO[A-Z]{1}|END)(\s|$))
66
+ # ForbiddenDelimiters: (?i-mx:(^|\s)(EO[A-Z]{1}|END)(\s|$))
67
67
  Naming/HeredocDelimiterNaming:
68
68
  Exclude:
69
69
  - 'Rakefile'
@@ -96,7 +96,15 @@ RSpec/AnyInstance:
96
96
  - 'spec/beaker/host/windows/file_spec.rb'
97
97
  - 'spec/beaker/subcommand_spec.rb'
98
98
 
99
- # Configuration parameters: Prefixes.
99
+ # This cop supports unsafe autocorrection (--autocorrect-all).
100
+ RSpec/BeEq:
101
+ Exclude:
102
+ - 'spec/beaker/cli_spec.rb'
103
+ - 'spec/beaker/host/pswindows/file_spec.rb'
104
+ - 'spec/beaker/host/windows/exec_spec.rb'
105
+ - 'spec/beaker/host_spec.rb'
106
+
107
+ # Configuration parameters: Prefixes, AllowedPatterns.
100
108
  # Prefixes: when, with, without
101
109
  RSpec/ContextWording:
102
110
  Enabled: false
@@ -128,7 +136,6 @@ RSpec/InstanceVariable:
128
136
  RSpec/IteratedExpectation:
129
137
  Exclude:
130
138
  - 'spec/beaker/dsl/helpers/host_helpers_spec.rb'
131
- - 'spec/beaker/host_prebuilt_steps_spec.rb'
132
139
 
133
140
  RSpec/LeakyConstantDeclaration:
134
141
  Exclude:
@@ -151,12 +158,23 @@ RSpec/MultipleDescribes:
151
158
 
152
159
  # Configuration parameters: AllowSubject.
153
160
  RSpec/MultipleMemoizedHelpers:
154
- Max: 19
161
+ Max: 17
155
162
 
156
- # Configuration parameters: IgnoreSharedExamples.
163
+ # Configuration parameters: EnforcedStyle, IgnoreSharedExamples.
164
+ # SupportedStyles: always, named_only
157
165
  RSpec/NamedSubject:
158
166
  Enabled: false
159
167
 
168
+ # Configuration parameters: AllowedPatterns.
169
+ # AllowedPatterns: ^expect_, ^assert_
170
+ RSpec/NoExpectationExample:
171
+ Exclude:
172
+ - 'acceptance/fixtures/module/spec/acceptance/demo_spec.rb'
173
+ - 'spec/beaker/host/windows/pkg_spec.rb'
174
+ - 'spec/beaker/host_prebuilt_steps_spec.rb'
175
+ - 'spec/beaker/logger_spec.rb'
176
+ - 'spec/beaker/options/subcommand_options_parser_spec.rb'
177
+
160
178
  RSpec/RepeatedDescription:
161
179
  Exclude:
162
180
  - 'spec/beaker/cli_spec.rb'
@@ -195,7 +213,7 @@ RSpec/UnspecifiedException:
195
213
  RSpec/VerifiedDoubles:
196
214
  Enabled: false
197
215
 
198
- # Cop supports --auto-correct.
216
+ # This cop supports safe autocorrection (--autocorrect).
199
217
  Rake/Desc:
200
218
  Exclude:
201
219
  - 'Rakefile'
@@ -213,3 +231,9 @@ Security/Eval:
213
231
  Security/Open:
214
232
  Exclude:
215
233
  - 'lib/beaker/dsl/helpers/web_helpers.rb'
234
+
235
+ # This cop supports safe autocorrection (--autocorrect).
236
+ # Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, AllowedPatterns.
237
+ # URISchemes: http, https
238
+ Layout/LineLength:
239
+ Max: 226
data/CHANGELOG.md CHANGED
@@ -1,49 +1,38 @@
1
1
  # Changelog
2
2
 
3
- ## [4.40.2](https://github.com/voxpupuli/beaker/tree/4.40.2) (2023-07-26)
3
+ ## [5.0.0](https://github.com/voxpupuli/beaker/tree/5.0.0) (2023-03-24)
4
4
 
5
- [Full Changelog](https://github.com/voxpupuli/beaker/compare/4.40.1...4.40.2)
5
+ **Breaking changes:**
6
6
 
7
- **Fixed bugs:**
8
-
9
- - Fix Minitest capitalization [\#1818](https://github.com/voxpupuli/beaker/pull/1818) ([mhashizume](https://github.com/mhashizume))
10
-
11
- ## [4.40.1](https://github.com/voxpupuli/beaker/tree/4.40.1) (2023-05-05)
12
-
13
- [Full Changelog](https://github.com/voxpupuli/beaker/compare/4.40.0...4.40.1)
14
-
15
- **Merged Changes:**
16
-
17
- - in-parallel: Allow 1.x [\#1813](https://github.com/voxpupuli/beaker/pull/1813) ([bastelfreak](https://github.com/bastelfreak))
18
-
19
- ## [4.40.0](https://github.com/voxpupuli/beaker/tree/4.40.0) (2023-04-04)
20
-
21
- [Full Changelog](https://github.com/voxpupuli/beaker/compare/4.39.0...4.40.0)
7
+ - Drop Ruby 2.4/2.5/2.6 support [\#1767](https://github.com/voxpupuli/beaker/pull/1767) ([bastelfreak](https://github.com/bastelfreak))
8
+ - Removes open_uri_redirections [\#1764](https://github.com/voxpupuli/beaker/pull/1764) ([mhashizume](https://github.com/mhashizume))
9
+ - Drop deprecated methods [\#1769](https://github.com/voxpupuli/beaker/pull/1769) ([ekohl](https://github.com/ekohl))
10
+ - Remove add-el-extras, passenger, proxy_config, disable_iptables and clean up code [\#1731](https://github.com/voxpupuli/beaker/pull/1731) ([ekohl](https://github.com/ekohl))
11
+ - Remove install_puppet_agent_* methods [\#1775](https://github.com/voxpupuli/beaker/pull/1775) ([ekohl](https://github.com/ekohl))
22
12
 
23
13
  **Implemented enhancements:**
24
14
 
25
- - \(maint\) Backport 'Removes open\_uri\_redirections' [\#1798](https://github.com/voxpupuli/beaker/pull/1798) ([joshcooper](https://github.com/joshcooper))
15
+ - Fix many RuboCop violations: [\#1768](https://github.com/voxpupuli/beaker/pull/1768), [\#1777](https://github.com/voxpupuli/beaker/pull/1777), [\#1787](https://github.com/voxpupuli/beaker/pull/1787), [\#1778](https://github.com/voxpupuli/beaker/pull/1778), [\#1790](https://github.com/voxpupuli/beaker/pull/1790), [\#1791](https://github.com/voxpupuli/beaker/pull/1791), [\#1792](https://github.com/voxpupuli/beaker/pull/1792)
16
+ - Add Ruby 3.2 support [\#1762](https://github.com/voxpupuli/beaker/pull/1762) ([ekohl](https://github.com/ekohl))
17
+ - Drop rspec-its dependency in favor of have_attributes [\#1788](https://github.com/voxpupuli/beaker/pull/1788)
26
18
 
27
- ## [4.39.0](https://github.com/voxpupuli/beaker/tree/4.39.0) (2023-02-18)
19
+ ## [4.39.0](https://github.com/voxpupuli/beaker/tree/4.39.0) (2023-02-09)
28
20
 
29
21
  [Full Changelog](https://github.com/voxpupuli/beaker/compare/4.38.1...4.39.0)
30
22
 
31
- **Implemented enhancements:**
32
-
33
- - \(maint\) StringInclude Rubocop corrections [\#1765](https://github.com/voxpupuli/beaker/pull/1765) ([mhashizume](https://github.com/mhashizume))
34
- - Add Rubocop [\#1761](https://github.com/voxpupuli/beaker/pull/1761) ([ekohl](https://github.com/ekohl))
35
-
36
23
  **Fixed bugs:**
37
24
 
38
25
  - Extend list of permitted classes for YAML safe load and allow aliases [\#1758](https://github.com/voxpupuli/beaker/pull/1758) ([nmburgan](https://github.com/nmburgan))
39
26
 
40
- **Closed issues:**
27
+ **Implemented enhancements:**
41
28
 
42
- - Ruby 3.1/Psych 4 compatibility issues [\#1753](https://github.com/voxpupuli/beaker/issues/1753)
29
+ - Add RuboCop [\#1761](https://github.com/voxpupuli/beaker/pull/1761) ([ekohl](https://github.com/ekohl))
30
+ - Update net-scp requirement from >= 1.2, < 4.0 to >= 1.2, < 5.0 [\#1757](https://github.com/voxpupuli/beaker/pull/1757)
31
+ - (maint) StringInclude Rubocop corrections [\1765](https://github.com/voxpupuli/beaker/pull/1765) ([mhashizume](https://github.com/mhashizume))
43
32
 
44
- **Merged pull requests:**
33
+ **Closed issues:**
45
34
 
46
- - Update net-scp requirement from \>= 1.2, \< 4.0 to \>= 1.2, \< 5.0 [\#1757](https://github.com/voxpupuli/beaker/pull/1757) ([dependabot[bot]](https://github.com/apps/dependabot))
35
+ - Ruby 3.1/Psych 4 compatibility issues [\#1753](https://github.com/voxpupuli/beaker/issues/1753)
47
36
 
48
37
  ## [4.38.1](https://github.com/voxpupuli/beaker/tree/4.38.1) (2022-09-21)
49
38
 
data/Gemfile CHANGED
@@ -15,23 +15,28 @@ gemspec
15
15
 
16
16
  if ENV['BEAKER_PE_PR_REPO_URL']
17
17
  lib = ENV['BEAKER_PE_PR_REPO_URL'].match(/\/([^\/]+)\.git$/)[1]
18
- author = ENV['BEAKER_PE_PR_AUTHOR']
19
- ref = ENV['BEAKER_PE_PR_COMMIT']
18
+ author = ENV.fetch('BEAKER_PE_PR_AUTHOR', nil)
19
+ ref = ENV.fetch('BEAKER_PE_PR_COMMIT', nil)
20
20
  gem lib, :git => "git@github.com:#{author}/#{lib}.git", :branch => ref
21
21
  end
22
22
 
23
+ if ENV['BEAKER_HYPERVISOR']
24
+ # vagrant_libvirt -> vagrant
25
+ gem "beaker-#{ENV['BEAKER_HYPERVISOR'].split('_').first}"
26
+ end
27
+
23
28
  group :rubocop do
24
- gem 'rubocop', '~> 1.12.0'
25
- gem 'rubocop-performance'
26
- gem 'rubocop-rake'
27
- gem 'rubocop-rspec'
29
+ gem 'rubocop', '~> 1.48.0'
30
+ gem 'rubocop-performance', '~> 1.16.0'
31
+ gem 'rubocop-rake', '~> 0.6.0'
32
+ gem 'rubocop-rspec', '~> 2.19.0'
28
33
  end
29
34
 
30
35
  group :release do
31
36
  gem 'github_changelog_generator', require: false
32
37
  end
33
38
 
34
- group :coverage, optional: ENV['COVERAGE']!='yes' do
39
+ group :coverage, optional: ENV['COVERAGE'] != 'yes' do
35
40
  gem 'codecov', :require => false
36
41
  gem 'simplecov-console', :require => false
37
42
  end