puppet-midonet/spec/functions/host_id_spec.rb
Alex Ruiz Estradera 3e1b84a356 Fix the midonet role
Change-Id: Ib17b95f5a6a7137c91eb92a2472513d45ea15f86
2016-08-24 08:11:19 +00:00

19 lines
428 B
Ruby

require 'spec_helper'
output = <<-EOF
#Mon Aug 22 16:42:19 UTC 2016
host_uuid=41b4d082-daf8-40bb-8812-504a0e9e5dac
EOF
describe 'host_id' do
it 'should work without errors' do
allow(File).to receive(:read).and_return('test')
allow(File).to receive(:read).with('/etc/midonet_host_id.properties').and_return(output)
is_expected.to run.with_params().and_return('41b4d082-daf8-40bb-8812-504a0e9e5dac')
end
end