diff options
-rw-r--r-- | doc/source/ext/resources.py | 6 | ||||
-rw-r--r-- | heat/engine/resource.py | 2 | ||||
-rw-r--r-- | heat/tests/engine/test_resource_type.py | 4 | ||||
-rw-r--r-- | heat/tests/test_resource.py | 4 |
4 files changed, 11 insertions, 5 deletions
diff --git a/doc/source/ext/resources.py b/doc/source/ext/resources.py index f09901bce..d23c08ca3 100644 --- a/doc/source/ext/resources.py +++ b/doc/source/ext/resources.py @@ -75,6 +75,12 @@ class ResourcePages(compat.Directive): self.resource_class.properties_schema) self.attrs_schemata = attributes.schemata( self.resource_class.attributes_schema) + # NOTE(prazumovsky): Adding base_attributes_schema dict to + # Resource class should means adding new attributes from this + # dict to documentation of each resource, else there is no + # chance to learn about base attributes. + self.attrs_schemata.update( + self.resource_class.base_attributes_schema) self.update_policy_schemata = properties.schemata( self.resource_class.update_policy_schema) diff --git a/heat/engine/resource.py b/heat/engine/resource.py index c905a4d56..64f4f8d5e 100644 --- a/heat/engine/resource.py +++ b/heat/engine/resource.py @@ -130,7 +130,7 @@ class Resource(object): # resources base_attributes_schema = { SHOW: attributes.Schema( - _("Dictionary with resource attributes."), + _("Detailed information about resource."), type=attributes.Schema.MAP ) } diff --git a/heat/tests/engine/test_resource_type.py b/heat/tests/engine/test_resource_type.py index 4765cfb58..bcd610278 100644 --- a/heat/tests/engine/test_resource_type.py +++ b/heat/tests/engine/test_resource_type.py @@ -87,7 +87,7 @@ class ResourceTypeTest(common.HeatTestCase): 'foo': {'description': 'A generic attribute'}, 'Foo': {'description': 'Another generic attribute'}, 'show': { - 'description': 'Dictionary with resource attributes.', + 'description': 'Detailed information about resource.', 'type': 'map'}, }, 'support_status': { @@ -113,7 +113,7 @@ class ResourceTypeTest(common.HeatTestCase): 'attr2': {'description': 'Another generic attribute', 'type': 'map'}, 'show': { - 'description': 'Dictionary with resource attributes.', + 'description': 'Detailed information about resource.', 'type': 'map'}, }, 'support_status': { diff --git a/heat/tests/test_resource.py b/heat/tests/test_resource.py index a56cdf8ed..c8bb76b58 100644 --- a/heat/tests/test_resource.py +++ b/heat/tests/test_resource.py @@ -1156,7 +1156,7 @@ class ResourceTest(common.HeatTestCase): 'Value': '{"Fn::GetAtt": ["TestResource", "output2"]}' }, 'show': { - 'Description': u'Dictionary with resource attributes.', + 'Description': u'Detailed information about resource.', 'Value': '{"Fn::GetAtt": ["TestResource", "show"]}' } } @@ -1239,7 +1239,7 @@ class ResourceTest(common.HeatTestCase): 'value': '{"get_attr": ["TestResource", "output2"]}' }, 'show': { - 'description': u'Dictionary with resource attributes.', + 'description': u'Detailed information about resource.', 'value': '{"get_attr": ["TestResource", "show"]}' } } |