tests/requests/compute/target_pools_tests.rb in fog-google-0.1.3 vs tests/requests/compute/target_pools_tests.rb in fog-google-0.2.0

- old
+ new

@@ -1,67 +1,65 @@ -Shindo.tests('Fog::Compute[:google] | target pools requests', ['google']) do - +Shindo.tests("Fog::Compute[:google] | target pools requests", ["google"]) do @google = Fog::Compute[:google] @insert_target_pool_format = { - 'kind' => String, - 'id' => String, - 'selfLink' => String, - 'name' => String, - 'targetLink' => String, - 'status' => String, - 'user' => String, - 'progress' => Integer, - 'region' => String, - 'insertTime' => String, - 'startTime' => String, - 'operationType' => String + "kind" => String, + "id" => String, + "selfLink" => String, + "name" => String, + "targetLink" => String, + "status" => String, + "user" => String, + "progress" => Integer, + "region" => String, + "insertTime" => String, + "startTime" => String, + "operationType" => String } @get_target_pool_format = { - 'kind' => String, - 'id' => String, - 'selfLink' => String, - 'creationTimestamp' => String, - 'name' => String, - 'region' => String, - 'healthChecks' => Array, - 'instances' => Array, + "kind" => String, + "id" => String, + "selfLink" => String, + "creationTimestamp" => String, + "name" => String, + "region" => String, + "healthChecks" => Array, + "instances" => Array } @delete_target_pool_format = { - 'kind' => String, - 'id' => String, - 'selfLink' => String, - 'name' => String, - 'targetLink' => String, - 'targetId' => String, - 'status' => String, - 'user' => String, - 'progress' => Integer, - 'insertTime' => String, - 'region' => String, - 'startTime' => String, - 'operationType' => String + "kind" => String, + "id" => String, + "selfLink" => String, + "name" => String, + "targetLink" => String, + "targetId" => String, + "status" => String, + "user" => String, + "progress" => Integer, + "insertTime" => String, + "region" => String, + "startTime" => String, + "operationType" => String } @list_target_pools_format = { - 'kind' => String, - 'id' => String, - 'items' => Array, - 'selfLink' => String + "kind" => String, + "id" => String, + "items" => Array, + "selfLink" => String } - tests('success') do - - target_pool_name = 'test-target_pool' - region_name = 'us-central1' + tests("success") do + target_pool_name = "test-target_pool" + region_name = "us-central1" # These will all fail if errors happen on insert tests("#insert_target_pool").formats(@insert_target_pool_format) do - instance = create_test_server(Fog::Compute[:google], 'us-central1-a') + instance = create_test_server(Fog::Compute[:google], "us-central1-a") health_check = create_test_http_health_check(Fog::Compute[:google]) - options = { 'instances' => [instance.self_link], 'healthChecks' => [health_check.self_link] } + options = { "instances" => [instance.self_link], "healthChecks" => [health_check.self_link] } response = @google.insert_target_pool(target_pool_name, region_name, options).body wait_operation(@google, response) response end @@ -74,9 +72,7 @@ end tests("#delete_target_pool").formats(@delete_target_pool_format) do @google.delete_target_pool(target_pool_name, region_name).body end - end - end