aboutsummaryrefslogtreecommitdiffstats
path: root/yardstick/tests/unit/common/test_openstack_utils.py
AgeCommit message (Collapse)AuthorFilesLines
2018-06-28Merge "Cleanup OpenStack utils test cases"Rodolfo Alonso Hernandez1-32/+35
2018-06-26Extended Context class with get_physical_nodes functionalityChornyi, TarasX1-0/+6
JIRA: YARDSTICK-1255 Change-Id: I446d715dc6cf716a4fcbc1b809c1b1d6303071e0 Signed-off-by: Chornyi, TarasX <tarasx.chornyi@intel.com>
2018-06-11Cleanup OpenStack utils test casesRodolfo Alonso Hernandez1-32/+35
Remove logging console output during test execution. JIRA: YARDSTICK-1230 Change-Id: I1b61f0f18bfb6e5a63c9027537cfb736261c4926 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-05-31Replace glance delete image with shade client.Shobhi Jain1-0/+27
Remove get_image_id function. Function delete_image now uses shade client. JIRA: YARDSTICK-892 Change-Id: I6e8510dfa49aa14786ed7ac3382b85c4e699fb9e Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-05-29Replace glance create image with shade client.Shobhi Jain1-0/+36
Function create_image now uses shade client. JIRA: YARDSTICK-892 Change-Id: Ia41d9ce702a1f24031080f8a365c1b2bd9ac9faa Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-05-08Replace cinder detach volume with shade client.Shobhi Jain1-0/+27
Function detach volume now uses shade client. JIRA: YARDSTICK-891 Change-Id: Ie437ccf1172cb82dc869963f0d62e31a5ab23ebb Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-05-08Replace cinder delete volume with shade client.Shobhi Jain1-0/+27
Function delete volume now uses shade client. JIRA: YARDSTICK-891 Change-Id: I016e1d3bf5972879cad176b56c7282e35413945e Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-05-08Replace cinder create volume with shade client.Shobhi Jain1-0/+44
Adds get_volume function. Function create volume now uses shade client. JIRA: YARDSTICK-891 Change-Id: I0b2fae5f2cf52eaf2e4a0062c858d49bc4ce9ccd Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-05-08Replace cinder get_volume_id with shade client.Shobhi Jain1-0/+22
Function get_volume_id now uses shade client. JIRA: YARDSTICK-891 Change-Id: I45ae40982a64f677dbbdeb6c9510a0ec9ac973f1 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-05-04Merge "Add "os_cloud_config" as a new context flag parameter"Emma Foley1-1/+26
2018-05-03Replace nova get flavor with shade client.Shobhi Jain1-0/+22
Rename get_flavor_by_name with get_flavor. Function get_flavor now uses shade client. JIRA: YARDSTICK-1088 Change-Id: Ic82127e475baf39643be0a254b177f3058b85748 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-05-03Replace nova get server with shade client.Shobhi Jain1-0/+22
Rename get_server_by_name with get_server. Function get_server now uses shade client. JIRA: YARDSTICK-1088 Change-Id: I69c59145cefdb565f3ece27baaaf932905e1b757 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-05-03Add "os_cloud_config" as a new context flag parameterRodolfo Alonso Hernandez1-1/+26
This new parameter will contain the OpenStack cloud specific configuration used by Shade client. This new flag is used only in Heat context. By default, this new parameter (dict) will contain this content: 'os_cloud_config': {'verify': False} This field will be used by HeatStack [1] to create a Shade cloud. Shade retrieves, if not defined, the OpenStack configuration from "os_client_config". This configuration is used to generate the cloud configuration, which is the description of the OpenStackCloud returned. The default parameter defined, "verify", refers to the related bug. By default, in case of using SSL certificate it will not be verified. [1] https://github.com/opnfv/yardstick/blob/b338d3091bb0beb89d4ad9f7c144f43a31a19a74/yardstick/orchestrator/heat.py#L47 JIRA: YARDSTICK-1139 Change-Id: I875a7018401b84e51dab775b8194174645d27e06 Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
2018-04-30Replace nova attach volume to server with shade client.Shobhi Jain1-0/+22
Function attach_volume_to_server now uses shade client instead of nova client. JIRA: YARDSTICK-1088 Change-Id: Id00df672c2c195b5c338cbbc30ddf2742a4e4d29 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-04-23Replace nova delete keypair with shade client.Shobhi Jain1-0/+27
Function delete_keypair now uses shade client. JIRA: YARDSTICK-1088 Change-Id: I46b895748c5c44b0bf7d5b035395676ebff48d7f Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-04-23Replace nova client create keypair with shade.Shobhi Jain1-0/+25
Function create_keypair now uses shade client instead of nova client. JIRA: YARDSTICK-1088 Change-Id: I060580504d6969c5ba859ed4494082feb998d37d Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-04-23Replace nova delete instance with shade client.Shobhi Jain1-0/+27
Function delete_instance now uses shade client. JIRA: YARDSTICK-1088 Change-Id: I5772a74c6dc2d103edd410042a8eaf721d1bcc5c Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-04-23Replace nova create instance with shade client.Shobhi Jain1-0/+29
Remove redundant functions: *get_instances *get_instance_status *get_instance_by_name Function create_instance_and_wait_for_active now uses shade client. JIRA: YARDSTICK-1088 Change-Id: I766da333dabbb1b83a7b4ede4bf73567ec70eb8c Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-04-16Update neutron delete_neutron_net function.Shobhi Jain1-4/+3
Update the changes done in patch [1]. JIRA: YARDSTICK-890 [1] https://gerrit.opnfv.org/gerrit/#/c/52361/ Change-Id: Iccbf16d0a2e72919d5092366241ff41686f01a58 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-04-16Replace neutron create security group full with shade.Shobhi Jain1-0/+56
Function create_security_group_full now uses shade client. Remove openstack util's private 'get_security_groups', 'get_security_group_id' & 'create_security_group' functions as 'create_security_group_full' now uses 'get_security_group' & 'create_security_group' function defined in shade client library. JIRA: YARDSTICK-890 Change-Id: Ibd5b9ca9b7ce99b3e40c5dcc545f2af672ce2203 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-04-12Bugfix: Can't get image list in APIchenjiankun1-0/+18
JIRA: YARDSTICK-1110 To match OpenStack Pike release, we upgrade novaclient from 7.1.1 to 9.1.1. And the client interface has changed, it no longer has nova_client.images attribute. So I use shade instead. Later will change all same issue. Change-Id: Ie4f54069d4346e44e2ad925439930504b945cbad Signed-off-by: chenjiankun <chenjiankun1@huawei.com>
2018-03-27Replace neutron create security group rule with shade.Shobhi Jain1-0/+25
Rename create_secgroup_rule with create_security_group_rule. Function create_security_group_rule now uses shade client. JIRA: YARDSTICK-890 Change-Id: Ie0ebac67a281e55dc95c0e3e33ba43de80aba9ec Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-03-27Replace neutron floating ip deletion with shade.Shobhi Jain1-0/+29
Function delete_floating_ip now uses shade client. JIRA: YARDSTICK-890 Change-Id: I960630926b664266afbe7be00bb1352243b41be0 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-03-20Replace neutron floating ip creation with shade.Shobhi Jain1-22/+24
Function create_floating_ip now uses shade client instead of neutron client. JIRA: YARDSTICK-890 Change-Id: I3defd691dad998cebf98442b52f0555b176f1af4 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-03-20Replace neutron router interface deletion with shade.Shobhi Jain1-0/+23
Function remove_interface_router now uses shade client instead of neutron client. JIRA: YARDSTICK-890 Change-Id: I6bd36e35a339cce64dfa8b69c1e7b56cd70af956 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-03-20Replace neutron router creation with shade.Shobhi Jain1-0/+24
Function create_neutron_router now uses shade client instead of neutron client. JIRA: YARDSTICK-890 Change-Id: I819d26f4edb3af5e50f777e8ddbadf4d24820b7f Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-03-12Replace neutron router deletion with shade.Shobhi Jain1-0/+28
Function delete_neutron_router now uses shade client instead of neutron client. JIRA: YARDSTICK-890 Change-Id: I5b557b640396f343b85b5f5eff415384decc083c Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-03-12Replace neutron subnet creation with shade.Shobhi Jain1-0/+25
Function 'create_neutron_subnet' now uses shade client instead of neutron client. JIRA: YARDSTICK-890 Change-Id: I8eb5295cecd73742bfb5a7d0764af6f45ef0685e Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-03-12Replace neutron network creation with shade.Shobhi Jain1-0/+25
Function create_neutron_net now uses shade client instead of neutron client. JIRA: YARDSTICK-890 Change-Id: I456078e98550901c1f736640c9f9bd0d5f9c3df6 Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-03-02Replace assertEqual(None, xx) with assertIsNone(xx)Emma Foley1-1/+1
Change-Id: Ie956d8064a8fbcbd3d56c5a79c4c613d35184af4 JIRA: YARDSTICK-942 Signed-off-by: Emma Foley <emma.l.foley@intel.com>
2018-02-19Replace neutron network deletion with shade.Shobhi Jain1-0/+29
Function delete_neutron_net now uses shade client instead of neutron client. JIRA: YARDSTICK-890 Change-Id: I99b6f3ecd37d6e3b783f7eb3da9f971398fc3bdd Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-02-09Replace neutron get network id with shade.Shobhi Jain1-9/+19
Function get_network_id now uses shade client instead of shade client. Removed redundant function: get_port_id. JIRA: YARDSTICK-890 Change-Id: I6081477fee39fa78131187e65daf3d7d3a9e439f Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
2018-01-11Move tests: unit/commonEmma Foley1-0/+46
* Fix pylint errors * Add TODOs Some errors are ignored locally, as they were a symptom of other problems. These issues have been flagged with a TODO, and should be fixed later. JIRA: YARDSTICK-837 Change-Id: I2847c380556985fae2c92bb8a7da9c47e91e1338 Signed-off-by: Emma Foley <emma.l.foley@intel.com>