Repository: getmoto/moto

Issue:
ResourceGroupsTaggingAPI.Client.get_resources does not return tagged resources.
## Reproduce

### Test

```
import boto3
from moto import mock_ec2, mock_resourcegroupstaggingapi


def test():
    mock_ec2().start()
    mock_resourcegroupstaggingapi().start()


    ec2 = boto3.resource('ec2', region_name='us-west-1')
    vpc = ec2.create_vpc(CidrBlock='10.0.0.0/16')
    ec2.create_tags(Resources=[vpc.id], Tags=[{'Key': 'test', 'Value': 'test'}])

    assert list(ec2.vpcs.filter(Filters=[{'Name':'tag:test', 'Values': ['test']}]))

    resourcegroupstaggingapi = boto3.client('resourcegroupstaggingapi')
    resources = resourcegroupstaggingapi.get_resources(TagFilters=[{'Key': 'test', 'Values': ['test']}])

    assert resources['ResourceTagMappingList']

    mock_resourcegroupstaggingapi().stop()
    mock_ec2().stop()

```

### Output:

> FAILED                            [ 0%]
test.py (test)
...
E       assert []
...

## Expected

Response dictionary key 'ResourceTagMappingList'  to be a list with one item (the Vpc).

## Actual

Response dictionary key 'ResourceTagMappingList'  is a list with no items.

## Library versions

```
moto = { git = "git://github.com/spulec/moto.git", ref = "dfa7935e13e6065810d6fc4e1edbf3e86499aea5" }
boto3 = "==1.7.79"
botocore = "==1.10.79"
```


Discussion:
I don't believe we've implemented this yet. Going to set as a feature request. Thanks!

Resolving patch:
diff --git a/moto/resourcegroupstaggingapi/models.py b/moto/resourcegroupstaggingapi/models.py
--- a/moto/resourcegroupstaggingapi/models.py
+++ b/moto/resourcegroupstaggingapi/models.py
@@ -3,6 +3,7 @@
 import six
 from boto3 import Session
 
+from moto.core import ACCOUNT_ID
 from moto.core import BaseBackend
 from moto.core.exceptions import RESTError
 
@@ -367,6 +368,23 @@ def get_kms_tags(kms_key_id):
         # RedShift Subnet group
 
         # VPC
+        if (
+            not resource_type_filters
+            or "ec2" in resource_type_filters
+            or "ec2:vpc" in resource_type_filters
+        ):
+            for vpc in self.ec2_backend.vpcs.values():
+                tags = get_ec2_tags(vpc.id)
+                if not tags or not tag_filter(
+                    tags
+                ):  # Skip if no tags, or invalid filter
+                    continue
+                yield {
+                    "ResourceARN": "arn:aws:ec2:{0}:{1}:vpc/{2}".format(
+                        self.region_name, ACCOUNT_ID, vpc.id
+                    ),
+                    "Tags": tags,
+                }
         # VPC Customer Gateway
         # VPC DHCP Option Set
         # VPC Internet Gateway


Test patch:
diff --git a/tests/test_resourcegroupstaggingapi/test_resourcegroupstaggingapi.py b/tests/test_resourcegroupstaggingapi/test_resourcegroupstaggingapi.py
--- a/tests/test_resourcegroupstaggingapi/test_resourcegroupstaggingapi.py
+++ b/tests/test_resourcegroupstaggingapi/test_resourcegroupstaggingapi.py
@@ -61,6 +61,27 @@ def test_get_resources_ec2():
     resp["ResourceTagMappingList"][0]["ResourceARN"].should.contain("instance/")
 
 
+@mock_ec2
+@mock_resourcegroupstaggingapi
+def test_get_resources_ec2_vpc():
+    ec2 = boto3.resource("ec2", region_name="us-west-1")
+    vpc = ec2.create_vpc(CidrBlock="10.0.0.0/16")
+    ec2.create_tags(Resources=[vpc.id], Tags=[{"Key": "test", "Value": "test"}])
+
+    def assert_response(resp):
+        results = resp.get("ResourceTagMappingList", [])
+        results.should.have.length_of(1)
+        vpc.id.should.be.within(results[0]["ResourceARN"])
+
+    rtapi = boto3.client("resourcegroupstaggingapi", region_name="us-west-1")
+    resp = rtapi.get_resources(ResourceTypeFilters=["ec2"])
+    assert_response(resp)
+    resp = rtapi.get_resources(ResourceTypeFilters=["ec2:vpc"])
+    assert_response(resp)
+    resp = rtapi.get_resources(TagFilters=[{"Key": "test", "Values": ["test"]}])
+    assert_response(resp)
+
+
 @mock_ec2
 @mock_resourcegroupstaggingapi
 def test_get_tag_keys_ec2():