diff options
author | Brian Waldon <bcwaldon@gmail.com> | 2012-02-08 08:13:23 -0800 |
---|---|---|
committer | Brian Waldon <bcwaldon@gmail.com> | 2012-02-08 08:16:19 -0800 |
commit | 2a872a606b2ed8e32de335c8a8a0d8b178ddba0c (patch) | |
tree | 223e08aba5353fc0cb33bcaeeedf8cce9f0d69e3 /nova | |
parent | 27ac9d5f0ca4279753ee2984769094f2b4191619 (diff) | |
download | nova-2a872a606b2ed8e32de335c8a8a0d8b178ddba0c.tar.gz nova-2a872a606b2ed8e32de335c8a8a0d8b178ddba0c.tar.xz nova-2a872a606b2ed8e32de335c8a8a0d8b178ddba0c.zip |
Add an alias to the ServerStartStop extension
Fixes bug 928954
Change-Id: I0c7e230e9b68139056c60c5477d3902c252ef413
Diffstat (limited to 'nova')
-rw-r--r-- | nova/api/openstack/compute/contrib/server_start_stop.py | 1 | ||||
-rw-r--r-- | nova/tests/api/openstack/compute/test_extensions.py | 7 |
2 files changed, 8 insertions, 0 deletions
diff --git a/nova/api/openstack/compute/contrib/server_start_stop.py b/nova/api/openstack/compute/contrib/server_start_stop.py index e5317f051..5f26c7dac 100644 --- a/nova/api/openstack/compute/contrib/server_start_stop.py +++ b/nova/api/openstack/compute/contrib/server_start_stop.py @@ -67,6 +67,7 @@ class Server_start_stop(extensions.ExtensionDescriptor): """Start/Stop instance compute API support""" name = "ServerStartStop" + alias = "os-server-start-stop" namespace = "http://docs.openstack.org/compute/ext/servers/api/v1.1" updated = "2012-01-23:00:00+00:00" diff --git a/nova/tests/api/openstack/compute/test_extensions.py b/nova/tests/api/openstack/compute/test_extensions.py index adeb847a4..7341cd483 100644 --- a/nova/tests/api/openstack/compute/test_extensions.py +++ b/nova/tests/api/openstack/compute/test_extensions.py @@ -217,6 +217,13 @@ class ExtensionControllerTest(ExtensionTestCase): }, ) + for ext in data['extensions']: + url = '/fake/extensions/%s' % ext['alias'] + request = webob.Request.blank(url) + response = request.get_response(app) + output = json.loads(response.body) + self.assertEqual(output['extension']['alias'], ext['alias']) + def test_get_extension_json(self): app = compute.APIRouter() request = webob.Request.blank("/fake/extensions/FOXNSOX") |