Sha256: 993ad5c942b78d22aa9556a77f1496a2291be3855e854ddb59ce1a58464b6541
Contents?: true
Size: 971 Bytes
Versions: 2
Compression:
Stored size: 971 Bytes
Contents
require "readwritesettings" require "fakeweb" require "bosh-bootstrap/network_providers/openstack" describe Bosh::Bootstrap::NetworkProviders::OpenStack do include Bosh::Bootstrap::Cli::Helpers::Settings let(:provider_client) { instance_double("Cyoi::Providers::Clients::OpenStackProviderClient") } subject { Bosh::Bootstrap::NetworkProviders::OpenStack.new(provider_client) } it "is registered" do expect(Bosh::Bootstrap::NetworkProviders.provider_class("openstack")).to eq subject.class end it "creates security groups it needs" do expected_groups = [ ["ssh", "ssh", 22], ["dns_server", "dns_server", { protocol: "udp", ports: (53..53) }], ["bosh", "bosh", [4222, 6868, 25250, 25555, 25777]] ] expected_groups.each do |security_group_name, description, ports| expect(provider_client).to receive(:create_security_group).with(security_group_name, description, ports) end subject.perform(settings) end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
bosh-bootstrap-0.14.3 | spec/unit/network_providers/openstack_spec.rb |
bosh-bootstrap-0.14.2 | spec/unit/network_providers/openstack_spec.rb |