summaryrefslogtreecommitdiffstats
path: root/nova/tests
diff options
context:
space:
mode:
authorChris Yeoh <cyeoh@au1.ibm.com>2013-06-13 14:48:02 +0930
committerChris Yeoh <cyeoh@au1.ibm.com>2013-06-13 15:00:04 +0930
commitd3dbc09ae0b020d42e776dd7d3aa920b13c02837 (patch)
tree0457ad155c169eab42606dc0cebf1133df27124c /nova/tests
parent71ece4a73c86995685fcbc8de2237f4fd70d0f53 (diff)
downloadnova-d3dbc09ae0b020d42e776dd7d3aa920b13c02837.tar.gz
nova-d3dbc09ae0b020d42e776dd7d3aa920b13c02837.tar.xz
nova-d3dbc09ae0b020d42e776dd7d3aa920b13c02837.zip
Port certificates API to v3 Part 2
This patch contains the changes required to adapt the certificates extension and the corresponding unittests to the v3 framework Partially implements blueprint nova-v3-api Change-Id: If4fe7e8524ba0181b50722281f594e0a80cd49ed
Diffstat (limited to 'nova/tests')
-rw-r--r--nova/tests/api/openstack/compute/plugins/v3/test_certificates.py6
-rw-r--r--nova/tests/fake_policy.py1
2 files changed, 4 insertions, 3 deletions
diff --git a/nova/tests/api/openstack/compute/plugins/v3/test_certificates.py b/nova/tests/api/openstack/compute/plugins/v3/test_certificates.py
index df5a7e9a1..222087872 100644
--- a/nova/tests/api/openstack/compute/plugins/v3/test_certificates.py
+++ b/nova/tests/api/openstack/compute/plugins/v3/test_certificates.py
@@ -15,7 +15,7 @@
from lxml import etree
-from nova.api.openstack.compute.contrib import certificates
+from nova.api.openstack.compute.plugins.v3 import certificates
from nova import context
from nova.openstack.common import rpc
from nova import test
@@ -44,7 +44,7 @@ class CertificatesTest(test.TestCase):
def test_certificates_show_root(self):
self.stubs.Set(rpc, 'call', fake_get_root_cert)
- req = fakes.HTTPRequest.blank('/v2/fake/os-certificates/root')
+ req = fakes.HTTPRequestV3.blank('/os-certificates/root')
res_dict = self.controller.show(req, 'root')
cert = fake_get_root_cert(self.context)
@@ -53,7 +53,7 @@ class CertificatesTest(test.TestCase):
def test_certificates_create_certificate(self):
self.stubs.Set(rpc, 'call', fake_create_cert)
- req = fakes.HTTPRequest.blank('/v2/fake/os-certificates/')
+ req = fakes.HTTPRequestV3.blank('/os-certificates/')
res_dict = self.controller.create(req)
pk, cert = fake_create_cert(self.context)
diff --git a/nova/tests/fake_policy.py b/nova/tests/fake_policy.py
index ed8cc7424..70f84499a 100644
--- a/nova/tests/fake_policy.py
+++ b/nova/tests/fake_policy.py
@@ -112,6 +112,7 @@ policy_data = """
"compute_extension:baremetal_nodes": "",
"compute_extension:cells": "",
"compute_extension:certificates": "",
+ "compute_extension:v3:os-certificates": "",
"compute_extension:cloudpipe": "",
"compute_extension:cloudpipe_update": "",
"compute_extension:config_drive": "",