mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
1f9837c865
- also adds get_current_session request
22 lines
824 B
Ruby
22 lines
824 B
Ruby
require File.expand_path(File.join(File.dirname(__FILE__), 'helper'))
|
|
|
|
VCR.use_cassette(File.basename(__FILE__)) do
|
|
|
|
Shindo.tests("Compute::VcloudDirector | organizations", ['vclouddirector', 'all']) do
|
|
organizations = vcloud_director.organizations
|
|
tests("#There is at least one organization").returns(true) { organizations.size >= 1 }
|
|
|
|
org = organizations.first
|
|
|
|
tests("Compute::VcloudDirector | organization") do
|
|
tests("#name").returns(String) { org.name.class }
|
|
tests("#type").returns("application/vnd.vmware.vcloud.org+xml") { org.type }
|
|
end
|
|
|
|
tests("Compute::VcloudDirector | organization", ['get']) do
|
|
tests("#get_by_name").returns(org.name) { organizations.get_by_name(org.name).name }
|
|
tests("#get").returns(org.id) { organizations.get(org.id).id }
|
|
end
|
|
end
|
|
|
|
end
|