Merge "Remove redundant FnGetAtt from User resource"

This commit is contained in:
Jenkins 2014-02-26 23:57:52 +00:00 committed by Gerrit Code Review
commit ac8ef2a6ba
2 changed files with 3 additions and 5 deletions

View File

@ -142,11 +142,6 @@ class User(resource.Resource):
def FnGetRefId(self):
return unicode(self.physical_resource_name())
def FnGetAtt(self, key):
#TODO(asalkeld) Implement Arn attribute
raise exception.InvalidTemplateAttribute(
resource=self.name, key=key)
def access_allowed(self, resource_name):
policies = (self.properties[self.POLICIES] or [])
for policy in policies:

View File

@ -122,6 +122,9 @@ class UserTest(UserPolicyTestCase):
self.assertEqual(utils.PhysName('test_stack', 'CfnUser'),
rsrc.FnGetRefId())
self.assertRaises(exception.InvalidTemplateAttribute,
rsrc.FnGetAtt, 'Foo')
self.assertEqual((rsrc.CREATE, rsrc.COMPLETE), rsrc.state)
self.assertRaises(resource.UpdateReplace,
rsrc.handle_update, {}, {}, {})