Merge "Add support_status to policy type and profile type"

This commit is contained in:
Jenkins 2017-01-10 01:55:03 +00:00 committed by Gerrit Code Review
commit 969661095d
4 changed files with 18 additions and 0 deletions

View File

@ -29,3 +29,5 @@ class PolicyType(resource.Resource):
name = resource.Body('name', alternate_id=True)
#: The schema of the policy type.
schema = resource.Body('schema')
#: The support status of the policy type
support_status = resource.Body('support_status')

View File

@ -29,3 +29,5 @@ class ProfileType(resource.Resource):
name = resource.Body('name', alternate_id=True)
#: The schema of the profile type.
schema = resource.Body('schema')
#: The support status of the profile type
support_status = resource.Body('support_status')

View File

@ -19,6 +19,12 @@ FAKE = {
'name': 'FAKE_POLICY_TYPE',
'schema': {
'foo': 'bar'
},
'support_status': {
'1.0': [{
'status': 'supported',
'since': '2016.10'
}]
}
}
@ -39,3 +45,4 @@ class TestPolicyType(testtools.TestCase):
self.assertEqual(FAKE['name'], sot._get_id(sot))
self.assertEqual(FAKE['name'], sot.name)
self.assertEqual(FAKE['schema'], sot.schema)
self.assertEqual(FAKE['support_status'], sot.support_status)

View File

@ -19,6 +19,12 @@ FAKE = {
'name': 'FAKE_PROFILE_TYPE',
'schema': {
'foo': 'bar'
},
'support_status': {
'1.0': [{
'status': 'supported',
'since': '2016.10',
}]
}
}
@ -39,3 +45,4 @@ class TestProfileType(testtools.TestCase):
self.assertEqual(FAKE['name'], sot._get_id(sot))
self.assertEqual(FAKE['name'], sot.name)
self.assertEqual(FAKE['schema'], sot.schema)
self.assertEqual(FAKE['support_status'], sot.support_status)