1
0
Fork 0
mirror of https://github.com/fog/fog.git synced 2022-11-09 13:51:43 -05:00
fog--fog/tests/openstack/requests/compute/tenant_tests.rb

20 lines
519 B
Ruby
Raw Normal View History

Shindo.tests('Fog::Compute[:openstack] | tenant requests', ['openstack']) do
@tenant_format = {
'id' => String,
'name' => String,
'enabled' => Fog::Boolean,
'description' => Fog::Nullable::String
}
tests('success') do
tests('#list_tenants').formats({'tenants_links' => Array, 'tenants' => [@tenant_format]}) do
Fog::Compute[:openstack].list_tenants.body
end
tests('#set_tenant("admin")').succeeds do
Fog::Compute[:openstack].set_tenant("admin")
end
end
end