From 5f770ffabbb8bef424a95f4e36215d3ffe1f60e9 Mon Sep 17 00:00:00 2001 From: Kieran Doonan Date: Tue, 5 Jul 2016 11:31:47 +0100 Subject: [PATCH] added more wildcard test for tags --- tests/test_ec2/test_tags.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/tests/test_ec2/test_tags.py b/tests/test_ec2/test_tags.py index adf2a697..a25d31e2 100644 --- a/tests/test_ec2/test_tags.py +++ b/tests/test_ec2/test_tags.py @@ -348,7 +348,7 @@ def test_retrieved_snapshots_must_contain_their_tags(): @mock_ec2 -def test_filter_instances_by_tags(): +def test_filter_instances_by_wildcard_tags(): conn = boto.connect_ec2(aws_access_key_id='the_key', aws_secret_access_key='the_secret') reservation = conn.run_instances('ami-1234abcd') instance_a = reservation.instances[0] @@ -359,3 +359,9 @@ def test_filter_instances_by_tags(): reservations = conn.get_all_instances(filters={'tag:Key1': 'Value*'}) reservations.should.have.length_of(2) + + reservations = conn.get_all_instances(filters={'tag-key': 'Key*'}) + reservations.should.have.length_of(2) + + reservations = conn.get_all_instances(filters={'tag-value': 'Value*'}) + reservations.should.have.length_of(2)