summaryrefslogtreecommitdiffstats
path: root/vio
diff options
context:
space:
mode:
authorEthan Lynn <ethanlynnl@vmware.com>2018-06-13 11:19:08 +0800
committerEthan Lynn <ethanlynnl@vmware.com>2018-06-13 11:19:08 +0800
commit157d04a2c21145ff0b167d1e86847eb43e2432e4 (patch)
treeec66dc6b6895a53c02097e086ba87df478e47e34 /vio
parentc958a4ab2fb579e44766f67d4a7cef9e4596cf3c (diff)
Add test_get_hpa_hugepage_any
Add test_get_hpa_hugepage_any Change-Id: I91e92f1a4e855912bb144c0316187a6c7dae71c7 Issue-ID: MULTICLOUD-199 Signed-off-by: Ethan Lynn <ethanlynnl@vmware.com>
Diffstat (limited to 'vio')
-rw-r--r--vio/vio/tests/test_aai_client.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/vio/vio/tests/test_aai_client.py b/vio/vio/tests/test_aai_client.py
index 7837e2d..364caca 100644
--- a/vio/vio/tests/test_aai_client.py
+++ b/vio/vio/tests/test_aai_client.py
@@ -323,3 +323,11 @@ class TestAAIClient(unittest.TestCase):
ret = self.view._get_hugepages_capabilities(extra)
self.assertIn(
"8", ret["hpa-feature-attributes"][0]["hpa-attribute-value"])
+
+ @mock.patch.object(restcall, "call_req")
+ def test_get_hpa_hugepage_any(self, mock_call):
+ extra = {
+ "hw:mem_page_size": "any",
+ }
+ ret = self.view._get_hugepages_capabilities(extra)
+ self.assertEqual(0, len(ret["hpa-feature-attributes"]))