From f7b50c48efbb2d34a95b187dfaf5ca70f77c67bc Mon Sep 17 00:00:00 2001 From: Atsushi SAKAI <sakaia@jp.fujitsu.com> Date: Thu, 3 Dec 2015 16:51:30 +0900 Subject: [PATCH] Add docker to image_schema on glance v2 cli Add docker to v2 image_schema Add docker to v2 unit tests This is related to following glance api extension. https://review.openstack.org/#/c/249282/ Co-Authored-By: Kairat Kushaev <kkushaev@mirantis.com> Closes-Bug: #1519402 Change-Id: Ia015f027788b49c1b0002fb3e3a93ac825854596 --- glanceclient/tests/unit/v2/fixtures.py | 3 ++- glanceclient/tests/unit/v2/test_shell_v2.py | 3 ++- glanceclient/v2/image_schema.py | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/glanceclient/tests/unit/v2/fixtures.py b/glanceclient/tests/unit/v2/fixtures.py index ebf2f72f..bc8793d3 100644 --- a/glanceclient/tests/unit/v2/fixtures.py +++ b/glanceclient/tests/unit/v2/fixtures.py @@ -112,7 +112,8 @@ schema_fixture = { "aki", "bare", "ovf", - "ova" + "ova", + "docker" ], "type": [ "null", diff --git a/glanceclient/tests/unit/v2/test_shell_v2.py b/glanceclient/tests/unit/v2/test_shell_v2.py index 4ccef275..1ae17b82 100644 --- a/glanceclient/tests/unit/v2/test_shell_v2.py +++ b/glanceclient/tests/unit/v2/test_shell_v2.py @@ -40,7 +40,8 @@ def schema_args(schema_getter, omit=None): my_schema_getter = lambda: { 'properties': { 'container_format': { - 'enum': [None, 'ami', 'ari', 'aki', 'bare', 'ovf', 'ova'], + 'enum': [None, 'ami', 'ari', 'aki', 'bare', 'ovf', 'ova', + 'docker'], 'type': 'string', 'description': 'Format of the container'}, 'disk_format': { diff --git a/glanceclient/v2/image_schema.py b/glanceclient/v2/image_schema.py index 29c1b2f0..ad669bab 100644 --- a/glanceclient/v2/image_schema.py +++ b/glanceclient/v2/image_schema.py @@ -44,7 +44,8 @@ _BASE_SCHEMA = { "aki", "bare", "ovf", - "ova" + "ova", + "docker" ], "type": "string", "description": "Format of the container"