diff options
author | Ethan Lynn <ethanlynnl@vmware.com> | 2018-03-27 08:22:40 -0700 |
---|---|---|
committer | Ethan Lynn <ethanlynnl@vmware.com> | 2018-03-27 08:22:40 -0700 |
commit | a0ceb13d65e42fe262ef5021074447fd0f826117 (patch) | |
tree | 3d2a16156f5ca05e1e6e67d463a35b03a22166e7 | |
parent | 94bfa7125d72b557bfe52f919358fd198fb7ce5e (diff) |
Add test_get_v2 for TokenView
Add test_get_v2
Change-Id: I65346b67d0efdd83dfabbd8ade1d33139f103e9d
Issue-ID: MULTICLOUD-199
Signed-off-by: Ethan Lynn <ethanlynnl@vmware.com>
-rw-r--r-- | vio/vio/tests/test_proxy_identity_view.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/vio/vio/tests/test_proxy_identity_view.py b/vio/vio/tests/test_proxy_identity_view.py index d9364ab..b60725c 100644 --- a/vio/vio/tests/test_proxy_identity_view.py +++ b/vio/vio/tests/test_proxy_identity_view.py @@ -73,3 +73,10 @@ class TestTokenView(unittest.TestCase): mock_req.return_value = res resp = self.view.get(req, "vmware_nova") self.assertEqual(resp.status_code, 200) + + @mock.patch.object(extsys, "get_vim_by_id") + def test_get_v2(self, mock_getvim): + req = mock.Mock() + req.get_full_path.return_value = "identity/v2.0" + resp = self.view.get(req, "vmware_nova") + self.assertEqual(resp.status_code, 405) |