Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update modulesync and fix test #4

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .fixtures.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
fixtures:
repositories:
stdlib:
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,12 @@

name: CI

on: pull_request
on:
pull_request: {}
push:
branches:
- main
- master

concurrency:
group: ${{ github.ref_name }}
Expand Down
2 changes: 1 addition & 1 deletion .msync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
# Managed by modulesync - DO NOT EDIT
# https://voxpupuli.org/docs/updating-files-managed-with-modulesync/

modulesync_config_version: '7.2.0'
modulesync_config_version: '7.3.0'
10 changes: 5 additions & 5 deletions manifests/files.pp
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,15 @@
#
define swap_file::files (
Enum['absent','present'] $ensure = 'present',
Stdlib::Unixpath $swapfile = '/mnt/swap.1',
Stdlib::Absolutepath $swapfile = '/mnt/swap.1',
$swapfilesize = $facts['memory']['system']['total'],
Boolean $add_mount = true,
$options = 'defaults',
String $options = 'defaults',
$timeout = 300,
$cmd = 'dd',
$resize_existing = false,
String $cmd = 'dd',
Boolean $resize_existing = false,
$resize_margin = '50MB',
$resize_verbose = false,
Boolean $resize_verbose = false,
) {
# Parameter validation
$swapfilesize_mb = to_bytes($swapfilesize) / 1048576
Expand Down
15 changes: 4 additions & 11 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -40,19 +40,12 @@
# @author - Peter Souter
#
class swap_file (
Hash $files = {},
Variant[Boolean,Enum['true','false']] $files_hiera_merge = false,
Hash $files = {},
Boolean $files_hiera_merge = false,
) {
# variable handling
if $files_hiera_merge =~ Boolean {
$files_hiera_merge_bool = $files_hiera_merge
} else {
$files_hiera_merge_bool = str2bool($files_hiera_merge)
}

# functionality
if $files_hiera_merge_bool == true {
$files_real = lookup('swap_file::files', Hash, 'deep', {})
if $files_hiera_merge {
$files_real = hiera_hash('swap_file::files', {})
} else {
$files_real = $files
}
Expand Down
6 changes: 3 additions & 3 deletions manifests/resize.pp
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@
# @author - Peter Souter
#
define swap_file::resize (
$swapfile_path,
Stdlib::Absolutepath $swapfile_path,
$expected_swapfile_size,
$actual_swapfile_size,
$margin = '50MB',
$verbose = false,
$margin = '50MB',
Boolean $verbose = false,
) {
$margin_bytes = to_bytes($margin)
$existing_swapfile_bytes = to_bytes("${actual_swapfile_size}kb")
Expand Down
22 changes: 15 additions & 7 deletions metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,31 @@
{
"operatingsystem": "RedHat",
"operatingsystemrelease": [
"5",
"6",
"7"
"7",
"8",
"9"
]
},
{
"operatingsystem": "CentOS",
"operatingsystemrelease": [
"7",
"8",
"9"
]
},
{
"operatingsystem": "Debian",
"operatingsystemrelease": [
"6",
"7"
"11",
"12"
]
},
{
"operatingsystem": "Ubuntu",
"operatingsystemrelease": [
"12.04",
"14.04"
"20.04",
"22.04"
]
}
],
Expand Down
11 changes: 0 additions & 11 deletions spec/acceptance/nodesets/Vagrantfile-vagrant_custom

This file was deleted.

11 changes: 0 additions & 11 deletions spec/acceptance/nodesets/centos-7-x64-vagrant_libvirt.yml

This file was deleted.

11 changes: 0 additions & 11 deletions spec/acceptance/nodesets/ubuntu-server-12042-x64.yml

This file was deleted.

88 changes: 49 additions & 39 deletions spec/acceptance/swap_file_class_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,49 +2,59 @@

require 'spec_helper_acceptance'

describe 'swap_file class', unless: UNSUPPORTED_PLATFORMS.include?(fact('osfamily')) do
context 'swap_file' do
context 'ensure => present' do
it 'works with no errors' do
pp = <<-EOS
class { 'swap_file':
files => {
'swapfile' => {
ensure => 'present',
},
'use fallocate' => {
swapfile => '/tmp/swapfile.fallocate',
cmd => 'fallocate',
},
'remove swap file' => {
ensure => 'absent',
swapfile => '/tmp/swapfile.old',
},
},
}
EOS

# Run it twice and test for idempotency
apply_manifest(pp, catch_failures: true)
apply_manifest(pp, catch_changes: true)
end

it 'contains the default swapfile' do
shell('/sbin/swapon -s | grep /mnt/swap.1', acceptable_exit_codes: [0])
end
describe 'swap_file class' do
after(:all) do
pp = <<-EOS
class { 'swap_file':
files => {
'swapfile' => {
ensure => 'absent',
},
'use fallocate' => {
swapfile => '/tmp/swapfile.fallocate',
cmd => 'fallocate',
ensure => absent,
},
'remove swap file' => {
ensure => 'absent',
swapfile => '/tmp/swapfile.old',
},
},
}
EOS

it 'contains the default fstab setting' do
shell('cat /etc/fstab | grep /mnt/swap.1', acceptable_exit_codes: [0])
shell('cat /etc/fstab | grep defaults', acceptable_exit_codes: [0])
end
apply_manifest(pp, catch_failures: true)
end

it 'contains the default swapfile' do
shell('/sbin/swapon -s | grep /tmp/swapfile.fallocate', acceptable_exit_codes: [0])
context 'with multiple files config' do
it_behaves_like 'an idempotent resource' do
let(:manifest) do
<<-PUPPET
class { 'swap_file':
files => {
'swapfile' => {
ensure => 'present',
},
'use fallocate' => {
swapfile => '/tmp/swapfile.fallocate',
cmd => 'fallocate',
swapfilesize => '100MB'
},
'remove swap file' => {
ensure => 'absent',
swapfile => '/tmp/swapfile.old',
swapfilesize => '100MB'
},
},
}
PUPPET
end
end

it 'contains the default fstab setting' do
shell('cat /etc/fstab | grep /tmp/swapfile.fallocate', acceptable_exit_codes: [0])
end
describe file('/etc/fstab'), shell('/sbin/swapon -s') do
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think you can combine the shell part in here.

Actually, our code doesn't use this a lot but it's recommended to avoid describe $resource() and use:

it 'sets up fstab' do
  expect(file('/etc/fstab')).to be_file
    .and(have_attributes(content: include('/mnt/swap.1')))
end

Copy link
Author

@Valantin Valantin Apr 10, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and if I want to check the output of a shell script?

I've tried your example and it fails

-:content => (include "/mnt/swap.1"),
 +:content => "# /etc/fstab: static file system information.\n#\n# <file sys>\t<mount point>\t<type>\t<options>\t<dump>\t<pass>\n\n# device during installation: /dev/loop0p1\nUUID=e40706ce-053f-451f-b6fe-0979430677a4\t/\text4\trw,discard,errors=remount-ro\t0\t1\n#VAGRANT-BEGIN\n# The contents below are automatically generated by Vagrant. Do not modify.\n#VAGRANT-END\n",

its(:content) { is_expected.to match %r{/mnt/swap.1} }

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - CentOS 9

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f5517a2b408> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +""

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - CentOS 8

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f1d74faef68> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +""

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - Ubuntu 22.04

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f29235e6ea8> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - Debian 12

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f9c90437c70> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - Ubuntu 22.04

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f823e0d5aa8> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - Debian 11

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f2d20d47b38> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - CentOS 8

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f64e7cb33f8> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +""

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - CentOS 7

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007fcc6408dd50> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +""

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - Debian 12

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007fb4b089c6c0> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - Debian 11

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007fe6a6b68ca0> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - Ubuntu 20.04

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f9fdbb64f68> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - CentOS 7

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f9ecaec5ac0> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +""

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - Ubuntu 20.04

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f1f402691a0> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 55 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - CentOS 9

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007fd4de1fb408> content is expected to match /\/mnt\/swap.1/ Failure/Error: its(:content) { is_expected.to match %r{/mnt/swap.1} } expected "" to match /\/mnt\/swap.1/ Diff: @@ -1 +1 @@ -/\/mnt\/swap.1/ +""
its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} }

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - CentOS 9

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f5517a2b408> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +""

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - CentOS 8

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f1d74faef68> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +""

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - Ubuntu 22.04

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f29235e6ea8> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - Debian 12

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f9c90437c70> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - Ubuntu 22.04

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f823e0d5aa8> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - Debian 11

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f2d20d47b38> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - CentOS 8

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f64e7cb33f8> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +""

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - CentOS 7

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007fcc6408dd50> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +""

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - Debian 12

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007fb4b089c6c0> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - Debian 11

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007fe6a6b68ca0> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - Ubuntu 20.04

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f9fdbb64f68> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - CentOS 7

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f9ecaec5ac0> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +""

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 7 - Ubuntu 20.04

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007f1f402691a0> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "# UNCONFIGURED FSTAB FOR BASE SYSTEM\n" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +# UNCONFIGURED FSTAB FOR BASE SYSTEM

Check failure on line 56 in spec/acceptance/swap_file_class_spec.rb

View workflow job for this annotation

GitHub Actions / Puppet / Puppet 8 - CentOS 9

swap_file class with multiple files config File "/etc/fstab" #<Beaker::Result:0x00007fd4de1fb408> content is expected to match /\/tmp\/swapfile.fallocate/ Failure/Error: its(:content) { is_expected.to match %r{/tmp/swapfile.fallocate} } expected "" to match /\/tmp\/swapfile.fallocate/ Diff: @@ -1 +1 @@ -/\/tmp\/swapfile.fallocate/ +""
its(:content) { is_expected.not_to match %r{/tmp/swapfile.old} }
end
end
end
28 changes: 0 additions & 28 deletions spec/acceptance/swap_file_files_fallocate_command.rb

This file was deleted.

34 changes: 0 additions & 34 deletions spec/acceptance/swap_file_files_multiple_spec.rb

This file was deleted.

38 changes: 0 additions & 38 deletions spec/acceptance/swap_file_files_parameters_spec.rb

This file was deleted.

Loading
Loading