aboutsummaryrefslogtreecommitdiffstats
path: root/yardstick/tests/unit/benchmark/scenarios/lib
AgeCommit message (Collapse)AuthorFilesLines
2018-07-31Change assert statements to raises in CheckValueMiikka Koistinen1-18/+46
* Instead of using assert statements, raise a custom exception. * Modify the unit tests so that they do not test unused parameters for equality. * Fix pylint and pep8 errors. JIRA: YARDSTICK-966 Change-Id: I41e13a5a22086827792eaf9de8da2e4ed6dd42de Signed-off-by: Miikka Koistinen <miikka.koistinen@nokia.com>
2018-05-31Replace glance delete image with shade client.Shobhi Jain1-14/+37
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-21/+41
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-11/+42
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-12/+37
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-81/+39
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-03Replace nova get flavor with shade client.Shobhi Jain1-10/+42
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-27/+42
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-04-30Replace nova attach volume to server with shade client.Shobhi Jain1-11/+41
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-12/+36
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-13/+43
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-12/+39
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-19/+44
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-9/+14
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-19/+48
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-03-27Replace neutron floating ip deletion with shade.Shobhi Jain1-12/+40
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-17/+16
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-13/+41
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-15/+42
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-12/+39
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-17/+43
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-15/+42
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-05assertTrue(mock.called) -> mock.assert_calledEmma Foley26-54/+54
When checking whether a mocked method has been called, mock.assert_called or mock.assert_called_once should be used, and not unittest.assertTrue(mock.called) This change does this update. It can be verified with: grep -irn "self.assertTrue(.*called)" --exclude-dir=.tox And the replacement was done with: sed -i 's/self.assertTrue(\(.*\).called)/\1.assert_called_once()/g' <list_of_files> Change-Id: I4f26e0c736bf33e0b2413c8e8c33dbdb91f090e2 JIRA: YARDSTICK-865 Signed-off-by: Emma Foley <emma.l.foley@intel.com>
2018-03-02Remove main() and __main__ from tests.Emma Foley31-247/+0
Removes the unnecessary main() functions from tests. Also removes shebang (#!) where it appears at the top of files. JIRA: YARDSTICK-861 Change-Id: I79180d1eb9c5bce640142dd62ce28c7437c1b210 Signed-off-by: Emma Foley <emma.l.foley@intel.com>
2018-02-19Replace neutron network deletion with shade.Shobhi Jain1-20/+34
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-12Move tests: unit/benchmarkEmma Foley34-0/+1529
* 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. Change-Id: I30eb4b0aafe0575d0cddbc946108291f21a98ed8 Jira: YARDSTICK-837 Signed-off-by: Emma Foley <emma.l.foley@intel.com> Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>