mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
4c2736d0c2
Simplify attachment of boot disk, get_as_boot_disk no longer needed Add missing Disk.get_object method Allow setting deviceName when attaching a disk Add disks mocks
12 lines
303 B
Ruby
12 lines
303 B
Ruby
# create a disk to be used in tests
|
|
def create_test_disk(connection, zone)
|
|
zone = 'us-central1-a'
|
|
disk = connection.disks.create({
|
|
:name => "fogservername",
|
|
:size_gb => "2",
|
|
:zone_name => zone,
|
|
:source_image => "debian-7-wheezy-v20131120",
|
|
})
|
|
disk.wait_for { ready? }
|
|
disk
|
|
end
|