Add description args for device profile create

Change-Id: If80884a827d636fcb6c0365773eac46c1ddfa1c9
This commit is contained in:
songwenping
2021-08-09 17:06:07 +08:00
parent e0372b72af
commit 9deb08e041
2 changed files with 5 additions and 1 deletions

View File

@@ -25,6 +25,8 @@ class DeviceProfile(resource.Resource):
#: The timestamp when this device_profile was created.
created_at = resource.Body('created_at')
#: The description of the device profile
description = resource.Body('description')
#: The groups of the device profile
groups = resource.Body('groups')
#: The name of the device profile

View File

@@ -27,7 +27,8 @@ FAKE = {
"resources:CUSTOM_MEMORY": "200",
"trait:CUSTOM_TRAIT_ALWAYS": "required",
}
]
],
'description': 'description_test'
}
@@ -51,3 +52,4 @@ class TestDeviceProfile(base.TestCase):
self.assertEqual(FAKE['uuid'], sot.uuid)
self.assertEqual(FAKE['name'], sot.name)
self.assertEqual(FAKE['groups'], sot.groups)
self.assertEqual(FAKE['description'], sot.description)