From 45b3bcc39631729ce573210ef6201c2cc59d7cdb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matija=20=C4=8Cupi=C4=87?= Date: Fri, 16 Mar 2018 17:50:48 +0100 Subject: Add zones_list and machine_types_list to Google Cloud API client --- spec/lib/google_api/cloud_platform/client_spec.rb | 24 +++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'spec/lib/google_api') diff --git a/spec/lib/google_api/cloud_platform/client_spec.rb b/spec/lib/google_api/cloud_platform/client_spec.rb index db9d9158b29..040cbda9468 100644 --- a/spec/lib/google_api/cloud_platform/client_spec.rb +++ b/spec/lib/google_api/cloud_platform/client_spec.rb @@ -74,6 +74,30 @@ describe GoogleApi::CloudPlatform::Client do it { is_expected.to eq(billing_info) } end + describe '#projects_zones_list' do + subject { client.projects_zones_list('project') } + let(:zones) { double } + + before do + allow_any_instance_of(Google::Apis::ComputeV1::ComputeService) + .to receive(:fetch_all).and_return(zones) + end + + it { is_expected.to eq(zones) } + end + + describe '#projects_zones_machine_types_list' do + subject { client.projects_zones_machine_types_list('project', 'zone') } + let(:machine_types) { double } + + before do + allow_any_instance_of(Google::Apis::ComputeV1::ComputeService) + .to receive(:fetch_all).and_return(machine_types) + end + + it { is_expected.to eq(machine_types) } + end + describe '#projects_zones_clusters_get' do subject { client.projects_zones_clusters_get(spy, spy, spy) } let(:gke_cluster) { double } -- cgit v1.2.1