Skip to content

Commit be5fc47

Browse files
author
Morgan Haskel
committed
Merge pull request redhat-openstack#141 from petems/dry_up_spec_test
Replace code with pre-existing shared_example
2 parents 7acd032 + 9280f81 commit be5fc47

1 file changed

Lines changed: 1 addition & 7 deletions

File tree

spec/acceptance/ini_setting_spec.rb

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -72,13 +72,7 @@
7272
apply_manifest(pp, :catch_changes => true)
7373
end
7474

75-
describe file("#{tmpdir}/ini_setting.ini") do
76-
it { should be_file }
77-
#XXX Solaris 10 doesn't support multi-line grep
78-
it("should contain four = five\n[one]\ntwo = three", :unless => fact('osfamily') == 'Solaris') {
79-
should contain("four = five\n[one]\ntwo = three")
80-
}
81-
end
75+
it_behaves_like 'has_content', "#{tmpdir}/ini_setting.ini", pp, "four = five\n[one]\ntwo = three"
8276
end
8377

8478
context '=> absent for key/value' do

0 commit comments

Comments
 (0)