Skip to content

Commit 9d2cbbf

Browse files
committed
rubocop
1 parent 5ceaeee commit 9d2cbbf

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

lib/facter/volume_group_map.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212
[
1313
vg,
1414
Facter::Core::Execution.exec("vgs -o pv_name #{vg} --noheading --nosuffix")
15-
.split("\n")
16-
.map { |x| x.strip }
17-
.join(',')
15+
.split("\n")
16+
.map(&:strip)
17+
.join(','),
1818
]
1919
end
2020
end

spec/unit/facter/logical_volumes_spec.rb

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
Facter::Core::Execution.expects('which').with('lvs').returns('/sbin/lvs')
3737
end
3838

39+
# rubocop:disable RSpec/ExampleLength
3940
it 'is able to resolve VGs' do
4041
lvs_output = <<-OUTPUT
4142
E7qan8-4NGf-jq2P-l11v-6fFe-MPHK-T6IGzl root centos/root /dev/centos/root /dev/mapper/centos-root -wi-ao---- linear public active 18.46g writeable centos
@@ -56,7 +57,7 @@
5657
'active' => 'active',
5758
'size' => '800.00m',
5859
'permissions' => 'writeable',
59-
'vg_name' => 'tasks',
60+
'vg_name' => 'tasks'
6061
},
6162
'lame_tasks' => {
6263
'uuid' => 'gmNS3G-cAhA-vRj0-2Uf0-21yO-QVdy-LNXfBv',
@@ -69,7 +70,7 @@
6970
'active' => 'active',
7071
'size' => '400.00m',
7172
'permissions' => 'writeable',
72-
'vg_name' => 'tasks',
73+
'vg_name' => 'tasks'
7374
},
7475
'root' => {
7576
'uuid' => 'E7qan8-4NGf-jq2P-l11v-6fFe-MPHK-T6IGzl',
@@ -82,7 +83,7 @@
8283
'active' => 'active',
8384
'size' => '18.46g',
8485
'permissions' => 'writeable',
85-
'vg_name' => 'centos',
86+
'vg_name' => 'centos'
8687
},
8788
'swap' => {
8889
'uuid' => 'buUXDX-GDUh-rN2t-y80n-vtCt-xhhu-XSZ5kA',
@@ -95,9 +96,10 @@
9596
'active' => 'active',
9697
'size' => '1.00g',
9798
'permissions' => 'writeable',
98-
'vg_name' => 'centos',
99+
'vg_name' => 'centos'
99100
})
100101
end
102+
# rubocop:enable RSpec/ExampleLength
101103
end
102104
end
103105
end

0 commit comments

Comments
 (0)