added test asserts and review comments

This commit is contained in:
usmankb 2020-04-29 18:02:02 +05:30
commit f4888da334
3 changed files with 25 additions and 2 deletions

View file

@ -2901,7 +2901,7 @@ class VPCBackend(object):
#validates if vpc is present or not.
self.get_vpc(vpc_id)
if type == "interface" or "Interface ":
if type and type.lower() == "interface":
network_interface_ids = []
for subnet_id in subnet_ids:
@ -2920,6 +2920,8 @@ class VPCBackend(object):
route_table_id,
service_destination_cidr
)
if dns_entries:
dns_entries = [dns_entries]
vpc_end_point = VPCEndPoint(
vpc_endpoint_id,
@ -2930,7 +2932,7 @@ class VPCBackend(object):
route_table_ids,
subnet_ids,
network_interface_ids,
[dns_entries],
dns_entries,
client_token,
security_group,
tag_specifications,

View file

@ -439,12 +439,14 @@ CREATE_VPC_END_POINT = """ <CreateVpcEndpointResponse xmlns="http://monitoring.a
{% endfor %}
</subnetIdSet>
<dnsEntrySet>
{% if vpc_end_point.dns_entries %}
{% for entry in vpc_end_point.dns_entries %}
<item>
<hostedZoneId>{{ entry["hosted_zone_id"] }}</hostedZoneId>
<dnsName>{{ entry["dns_name"] }}</dnsName>
</item>
{% endfor %}
{% endif %}
</dnsEntrySet>
<creationTimestamp>{{ vpc_end_point.created_at }}</creationTimestamp>
</vpcEndpoint>