-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix a bug in the response parser involving multiple members of a stru…
…cture all having the same xmlname. This occurs in responses like DescribeInstanceAttribute where the output structure contains an explicit member for each possible attribute but only one attribute is included in the response. The value of the one returned response was being duplicated to all of the members of the structure. Fixes #173.
- Loading branch information
Showing
3 changed files
with
34 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
tests/unit/response_parsing/xml/responses/ec2-describe-instance-attribute.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
"UserData": {}, | ||
"ResponseMetadata": { | ||
"RequestId": "4c94c806-ef28-4f4c-b1c7-3e601fe39497" | ||
}, | ||
"ProductCodes": [], | ||
"InstanceId": "i-12345678", | ||
"InstanceInitiatedShutdownBehavior": {}, | ||
"RootDeviceName": { | ||
"Value": "/dev/sda1" | ||
}, | ||
"EbsOptimized": {}, | ||
"BlockDeviceMappings": [], | ||
"KernelId": {}, | ||
"RamdiskId": {}, | ||
"DisableApiTermination": {}, | ||
"InstanceType": {} | ||
} |
9 changes: 9 additions & 0 deletions
9
tests/unit/response_parsing/xml/responses/ec2-describe-instance-attribute.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<DescribeInstanceAttributeResponse xmlns="http://ec2.amazonaws.com/doc/2013-10-01/"> | ||
<requestId>4c94c806-ef28-4f4c-b1c7-3e601fe39497</requestId> | ||
<instanceId>i-12345678</instanceId> | ||
<rootDeviceName> | ||
<value>/dev/sda1</value> | ||
</rootDeviceName> | ||
</DescribeInstanceAttributeResponse> | ||
|