Skip to content

Commit ed08924

Browse files
author
Dylan Ratcliffe
committed
Changed syntax to support Ruby 2.1
1 parent 82e1ee2 commit ed08924

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

spec/unit/facter/logical_volumes_spec.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,13 @@
3535
end
3636

3737
it 'should be able to resolve VGs' do
38-
lvs_output = <<~OUTPUT
38+
lvs_output = <<-OUTPUT
3939
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
4040
buUXDX-GDUh-rN2t-y80n-vtCt-xhhu-XSZ5kA swap centos/swap /dev/centos/swap /dev/mapper/centos-swap -wi-ao---- linear public active 1.00g writeable
4141
uedsry-OTVv-wGW4-vaFf-c7IY-oH6Z-ig6IXB cool_tasks tasks/cool_tasks /dev/tasks/cool_tasks /dev/mapper/tasks-cool_tasks -wi-a----- linear public active 800.00m writeable
4242
gmNS3G-cAhA-vRj0-2Uf0-21yO-QVdy-LNXfBv lame_tasks tasks/lame_tasks /dev/tasks/lame_tasks /dev/mapper/tasks-lame_tasks -wi-a----- linear public active 400.00m writeable
4343
OUTPUT
44+
lvs_output.lstrip!
4445
Facter::Core::Execution.expects(:exec).at_least(1).returns(lvs_output)
4546
Facter.value(:logical_volumes).should include({
4647
"cool_tasks" => {

spec/unit/facter/physical_volumes_spec.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,12 @@
3535
end
3636

3737
it 'should be able to resolve PVs' do
38-
pvs_output = <<~OUTPUT
38+
pvs_output = <<-OUTPUT
3939
dPziSO-573Z-9WuH-q22X-cuyM-gHQx-ZeGbfK 2.00g /dev/sda 1.00m 2.00g 844.00m 1.17g a-- 511 300 1 1 0 0
4040
09ksGm-Pt28-AR9H-NlgQ-QxtG-5uEH-Qzy1RR 2.00g /dev/sdc 1.00m 2.00g 2.00g 0 a-- 511 0 1 1 0 0
4141
PpSFVZ-SS3P-n3a6-ctPF-sb9H-6M85-i0TqBv 19.51g /dev/sdd2 1.00m 19.51g 44.00m 19.46g a-- 4994 4983 1 1 0 0
4242
OUTPUT
43+
pvs_output.lstrip!
4344
Facter::Core::Execution.expects(:exec).at_least(1).returns(pvs_output)
4445
Facter.value(:physical_volumes).should include({
4546
"/dev/sda" => {

spec/unit/facter/volume_groups_spec.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,11 @@
3535
end
3636

3737
it 'should be able to resolve vgs' do
38-
vgs_output = <<~OUTPUT
38+
vgs_output = <<-OUTPUT
3939
ZcFkEG-217a-nnc6-PvWx-oXou-7THt-XR6eci centos wz--n- writeable normal 19.51g 44.00m
4040
tMqdQC-ukEx-bEft-bLk8-WoM1-jX0a-0p1rri tasks wz--n- writeable normal 3.99g 2.82g
4141
OUTPUT
42+
vgs_output.lstrip!
4243
Facter::Core::Execution.expects(:exec).at_least(1).returns(vgs_output)
4344
Facter.value(:volume_groups).should include({
4445
"centos" => {

0 commit comments

Comments
 (0)