4a576293c1
This change updates additional parser functions we have to use teh puppet 4.x function api. This includes some basic unit tests to ensure they continue to function as expected. Change-Id: Iebeb82b2890216bed139219441718fffc4004391 Related-Bug: #1799786
20 lines
512 B
Ruby
20 lines
512 B
Ruby
require 'spec_helper'
|
|
|
|
describe 'docker_volumes_to_storage_maps' do
|
|
it {
|
|
should run.with_params(["/src/vol1:/tgt/vol1", "/src/vol2:/tgt/vol2:ro"], "my-prefix")
|
|
.and_return({
|
|
"my-prefix-src-vol1" => {
|
|
"source-dir" => "/src/vol1",
|
|
"target-dir" => "/tgt/vol1",
|
|
"options" => "rw",
|
|
},
|
|
"my-prefix-src-vol2" => {
|
|
"source-dir" => "/src/vol2",
|
|
"target-dir" => "/tgt/vol2",
|
|
"options" => "ro",
|
|
}
|
|
})
|
|
}
|
|
end
|