From 9884e0cd388ec64846ff30d8beb21ddf8ab3522a Mon Sep 17 00:00:00 2001 From: Christopher Oliver Date: Wed, 27 Jul 2011 10:44:48 -0400 Subject: [PATCH 1/2] [aws|compute] Fixed failing instance tests. --- lib/fog/compute/requests/aws/describe_instances.rb | 2 +- tests/compute/requests/aws/instance_tests.rb | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/fog/compute/requests/aws/describe_instances.rb b/lib/fog/compute/requests/aws/describe_instances.rb index 48adfe8db..b88e7a8a7 100644 --- a/lib/fog/compute/requests/aws/describe_instances.rb +++ b/lib/fog/compute/requests/aws/describe_instances.rb @@ -187,7 +187,7 @@ module Fog 'ownerId' => instance['ownerId'], 'reservationId' => instance['reservationId'] } - reservation_set[instance['reservationId']]['instancesSet'] << instance.reject{|key,value| !['amiLaunchIndex', 'architecture', 'blockDeviceMapping', 'clientToken', 'dnsName', 'imageId', 'instanceId', 'instanceState', 'instanceType', 'ipAddress', 'kernelId', 'keyName', 'launchTime', 'monitoring', 'placement', 'privateDnsName', 'privateIpAddress', 'productCodes', 'ramdiskId', 'reason', 'rootDeviceType', 'stateReason', 'tagSet'].include?(key)} + reservation_set[instance['reservationId']]['instancesSet'] << instance.reject{|key,value| !['amiLaunchIndex', 'architecture', 'blockDeviceMapping', 'clientToken', 'dnsName', 'imageId', 'instanceId', 'instanceState', 'instanceType', 'ipAddress', 'kernelId', 'keyName', 'launchTime', 'monitoring', 'placement', 'platform', 'privateDnsName', 'privateIpAddress', 'productCodes', 'ramdiskId', 'reason', 'rootDeviceType', 'stateReason', 'tagSet'].include?(key)} end end diff --git a/tests/compute/requests/aws/instance_tests.rb b/tests/compute/requests/aws/instance_tests.rb index 81b71ac41..872890102 100644 --- a/tests/compute/requests/aws/instance_tests.rb +++ b/tests/compute/requests/aws/instance_tests.rb @@ -44,6 +44,7 @@ Shindo.tests('Fog::Compute[:aws] | instance requests', ['aws']) do 'architecture' => String, 'dnsName' => Fog::Nullable::String, 'ipAddress' => Fog::Nullable::String, + 'platform' => Fog::Nullable::String, 'privateDnsName' => Fog::Nullable::String, 'privateIpAddress' => Fog::Nullable::String, 'stateReason' => Hash, From 90d59507161526fad9358eec4a6f0dd450b2ca50 Mon Sep 17 00:00:00 2001 From: Christopher Oliver Date: Wed, 18 Jan 2012 16:47:13 -0500 Subject: [PATCH 2/2] [AWS] Compute: The security group parser was not parsing groupid properly. --- lib/fog/aws/parsers/compute/describe_security_groups.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/fog/aws/parsers/compute/describe_security_groups.rb b/lib/fog/aws/parsers/compute/describe_security_groups.rb index f157f36b0..d54240e19 100644 --- a/lib/fog/aws/parsers/compute/describe_security_groups.rb +++ b/lib/fog/aws/parsers/compute/describe_security_groups.rb @@ -40,9 +40,9 @@ module Fog end when 'groups' @in_groups = false - when 'groupDescription', 'ownerId', 'groupId', 'vpcId' + when 'groupDescription', 'ownerId', 'vpcId' @security_group[name] = value - when 'groupName' + when 'groupId','groupName' if @in_groups @group[name] = value else