

@mock_ec2
def test_vpc_tagging():
    conn = boto.connect_vpc()
    vpc = conn.create_vpc('10.0.0.0/16')
    vpc.add_tag('a key', 'some value')
    tag = conn.get_all_tags()[0]
    tag.name.should.equal('a key')
    tag.value.should.equal('some value')
    vpc = conn.get_all_vpcs()[0]
    vpc.tags.should.have.length_of(1)
    vpc.tags['a key'].should.equal('some value')

dataset/ETHPy150Open spulec/moto/tests/test_ec2/test_vpcs.py test_vpc_tagging/original