Tay Frost 15b3ede3cc Add test for case where ebs volume has no tags.
This commit adds a test for a case where an EBS volume has no tags. When
an EBS volume has no tags, calls to the aws ec2 endpoints `create_volume`
and `describe_volumes` do not include the `Tags` key in the
`response.Volumes[]` object.

However, moto does include the `Tags` key in this case. This discrepancy
in behaviour can result in code passing a moto test but failing in
production.

Sample snippets that trigger this condition:

```
def create_volume_and_then_get_tags_from_response():
    client = boto3.client('ec2', region_name='us-east-1')
    volume_response = client.create_volume(
        Size=10,
        AvailabilityZone='us-east-1a'
    )
    keys = volume_response['Keys']
```

```
def create_volume_and_then_get_tags_from_describe_volumes():
    client = boto3.client('ec2', region_name='us-east-1')
    volume_response = client.create_volume(
        Size=10,
        AvailabilityZone='us-east-1a'
    )
    volume_describe_response = client.describe_volumes()
    keys = volume_describe_response['Volumes'][0]['Keys']
```

Both sample snippets will succeed in a moto test, but fail with a
`KeyError` when using the aws api.
2019-03-07 17:25:18 -05:00
..
2017-02-23 21:37:43 -05:00
2017-02-23 21:37:43 -05:00
2017-09-14 14:59:13 +05:30
2017-02-23 21:37:43 -05:00
2017-05-26 12:47:28 -07:00
2017-10-25 19:29:56 +01:00
2017-02-23 21:37:43 -05:00
2017-02-23 22:28:09 -05:00
2017-02-23 21:37:43 -05:00
2017-02-23 21:37:43 -05:00