Skip to content

Commit 49c3aa7

Browse files
committed
Add spec to verify PowerVS credentials
1 parent 82a1537 commit 49c3aa7

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
describe ManageIQ::Providers::IbmCloud::PowerVirtualServers::CloudManager do
2+
it ".ems_type" do
3+
expect(described_class.ems_type).to eq("ibm_cloud_power_virtual_servers")
4+
end
5+
6+
let(:ems) do
7+
uid_ems = Rails.application.secrets.ibm_cloud_power[:cloud_instance_id]
8+
auth_key = Rails.application.secrets.ibm_cloud_power[:api_key]
9+
10+
FactoryBot.create(:ems_ibm_cloud_power_virtual_servers_cloud, :uid_ems => uid_ems).tap do |ems|
11+
ems.authentications << FactoryBot.create(:authentication, :auth_key => auth_key)
12+
end
13+
end
14+
15+
it "verify credentials" do
16+
VCR.use_cassette(described_class.name.underscore) do
17+
ems.verify_credentials
18+
end
19+
end
20+
end

0 commit comments

Comments
 (0)