Method: Awspec::Generator::Spec::NetworkInterface#generate_linespecs
- Defined in:
- lib/awspec/generator/spec/network_interface.rb
#generate_linespecs(interface) ⇒ Object
47 48 49 50 51 52 53 54 55 56 |
# File 'lib/awspec/generator/spec/network_interface.rb', line 47 def generate_linespecs(interface) linespecs = [] interface.private_ip_addresses.each do |ip_address| line = "it { should have_private_ip_address('#{ip_address.private_ip_address}')" line += '.primary' if ip_address.primary line += ' }' linespecs.push(line) end linespecs end |