Skip to content

Commit 4095af1

Browse files
committed
Add 'project_id' field to cluster's action resource
Change-Id: If5b14270fd339c199261e803d953e8dda6ef3151
1 parent 69d79c9 commit 4095af1

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

openstack/cluster/v1/action.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ class Action(resource.Resource):
3939
cause = resource.Body('cause')
4040
#: The owning engine that is currently running the action.
4141
owner_id = resource.Body('owner')
42+
#: The ID of the project this profile belongs to.
43+
project_id = resource.Body('project')
4244
#: Interval in seconds between two consecutive executions.
4345
interval = resource.Body('interval')
4446
#: The time the action was started.

openstack/tests/unit/cluster/v1/test_action.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
'action': 'NODE_CREATE',
2626
'cause': 'RPC Request',
2727
'owner': None,
28+
'project': '42d9e9663331431f97b75e25136307ff',
2829
'interval': -1,
2930
'start_time': 1453414055.48672,
3031
'end_time': 1453414055.48672,
@@ -62,6 +63,7 @@ def test_instantiate(self):
6263
self.assertEqual(FAKE['action'], sot.action)
6364
self.assertEqual(FAKE['cause'], sot.cause)
6465
self.assertEqual(FAKE['owner'], sot.owner_id)
66+
self.assertEqual(FAKE['project'], sot.project_id)
6567
self.assertEqual(FAKE['interval'], sot.interval)
6668
self.assertEqual(FAKE['start_time'], sot.start_at)
6769
self.assertEqual(FAKE['end_time'], sot.end_at)

0 commit comments

Comments
 (0)