aboutsummaryrefslogtreecommitdiffstats
path: root/testcases/Controllers
AgeCommit message (Collapse)AuthorFilesLines
2016-10-20Add Copyright headersCédric Ollivier1-1/+8
It follows OPNFV Contribution Guidelines [1]. [1] https://wiki.opnfv.org/display/DEV/Contribution+Guidelines Change-Id: I0f603468510e5bb500e2be0f7815eefde3581b03 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-10-19Move unit tests in unit_testsCédric Ollivier1-341/+0
It also renames files and removes exec rights to be conformed with nose. Change-Id: Ib93973a7d4b543360372fb1092a58896f687ec84 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-10-18Add OpenDaylightTesting unit testsCédric Ollivier2-17/+363
It adds unit tests checking OpenDaylightTesting. Several minor issues have also been fixed in this module when writing these unit tests: - the exceptions raised by main are caught when the testcases are launched from cmdline, - a warning message indicates that the temporarily files cannot be removed. JIRA: FUNCTEST-512 Change-Id: I873f0bbf4c3b7f416ca5515580e8aeab90773fdc Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-10-18Remove exits in OpenStack client utilsCédric Ollivier1-12/+15
It prevents openstack_utils from exiting when the mandatory env vars are unset. Every testcase is now in charge of handling the exception MissingEnvVar. JIRA: FUNCTEST-438 Change-Id: I0e321b544a470c1f2f2fa62b3e061fe5f938e112 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-10-17Conform ODL to TestCasesBaseCédric Ollivier1-51/+53
Now ODLTestCases inherits from TestCasesBase what induces several modifications of function definitions. It also renames functest_run to run and run to main and they now return the code status defined in TestCasesBase instead of True and False (run_tests.py has been adapted as well). It checks if errno is equal to EEXIST when makedir raises an OSError exception. JIRA: FUNCTEST-353 Change-Id: I88240a9ce8e491dab4c7e6c604f3ecc62cf9edce Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-10-13Stop copying obsolete filesCédric Ollivier1-12/+7
It completes the previous review [1] which removes several robot files. [1] https://gerrit.opnfv.org/gerrit/#/c/23069/ Change-Id: I64c43e6833af1ac468933e09d48fecef812da697 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-10-12Delete obsolete robot filesCédric Ollivier3-126/+0
The robot files which delete neutron resources are now hosted by ODL test [1]. They can now be safely removed. https://git.opendaylight.org/gerrit/#/c/46749/ Change-Id: I2fb730ec3f5fbc380b5699e5fbfbb45a6524d2fe Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-09-14Merge "Push FAIL to DB for onos-sfc"Jose Lausuch1-101/+50
2016-09-14Push FAIL to DB for onos-sfcwuwenbin21-101/+50
Change-Id: Ifae2cba32d9a0df44ae46e642129931692f65a7c Signed-off-by: wuwenbin2 <wuwenbin2@huawei.com>
2016-09-09Merge "Optimize onos-sfc"Jose Lausuch2-244/+245
2016-09-09Optimize onos-sfcwuwenbin22-244/+245
1.Delete print and format in onos-sfc 2.Split class into serveral methods in Sfc.py 3.Update Fail process 4.Use vars of HTTP status code Change-Id: Ifb2fc5c570e2c2aa2cfb173eadb32c688a84969e Signed-off-by: wuwenbin2 <wuwenbin2@huawei.com>
2016-09-08make use of functest_utils.get_parameter_from_yamlSerenaFeng2-52/+44
JIRA: FUNCTEST-463 Change-Id: I1d54a65c5bfa2542f2fd3a2e408967641e6e4ac9 Signed-off-by: SerenaFeng <feng.xiaowei@zte.com.cn>
2016-09-07remove imported FUNCTEST_REPO objectSerenaFeng2-6/+7
According to openstack style guidelines in http://docs.openstack.org/developer/hacking/ **** Do not import objects, only modules (*) **** so direct FUNCTEST_REPO import should be avoided from functest.utils.functest_utils import FUNCTEST_REPO as FUNCTEST_REPO JIRA: FUNCTEST-459 Change-Id: Iac0d07a54957cd7419391de183660ac1ce0efd49 Signed-off-by: SerenaFeng <feng.xiaowei@zte.com.cn>
2016-09-01Switch print to logging.infoCédric Ollivier4-31/+43
It follows the recommendations described in the next review [1]. [1] https://gerrit.opnfv.org/gerrit/#/c/19795/ Change-Id: Ie7ce28451122c554f135caad068844c0303deaeb Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-09-01stop hardcoded FUNCTEST_REPO path everywhereSerenaFeng2-11/+9
functest repo is used by almost every testcase, each place we get it like: REPOS_DIR = os.getenv('repos_dir') FUNCTEST_REPO = ("%s/functest" % REPOS_DIR) provide a common interface in functest_util.py JIRA: FUNCTEST-453 Change-Id: Ie0635dacc761ed2d05b7e606530368844f32ebaf Signed-off-by: SerenaFeng <feng.xiaowei@zte.com.cn>
2016-08-31Remove all logers as utils method args.Cédric Ollivier3-3/+1
As it modifies method params, it could break the testcases. JIRA: FUNCTEST-428 Change-Id: I4263d9bd812f1803e513464e3c321cc4a7281958 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-24Stop calling exec_test.sh in the middle of python scriptsCédric Ollivier3-3/+42
Now run_tests.py calls directly OpenDaylightTesting.functest_run(). It mainly reads env vars as exec_test.sh does. Change-Id: Ibb44a7ca67e9218d34d13b8dd539e772902fe5b8 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-23Add logger to push_results_to_db argsCédric Ollivier1-1/+1
It conforms to the current implementation of functest_utils Change-Id: I50fa05fbf81a7c76cf4a6e3ef906fffe8aec15bf Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-22Fix typos in OpenDaylightTestingCédric Ollivier1-2/+2
Change-Id: Ia70c1db358b727a910a38b679de0e3c6febdb0cd Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-22Avoid opening tmp files twiceCédric Ollivier1-2/+6
It avoids opening stdout.txt twice and removes it at the end. Change-Id: I7e006b52f49dd32543676259e0a1be2473670487 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-22Add logs (info)Cédric Ollivier1-2/+3
It adds logs (info) when status is ok and fixes an exception printing too. It removes one useless log (debug). Change-Id: Ia59c3985ae749b80d0e0c07f331220bd33cd8007 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-22Improve errors and status codes managementCédric Ollivier1-11/+12
Run returns the number of errors which is irrelevant to catch as they are published to DB. Useless generated files are desactivated too. Change-Id: I2baf6d5242c5f4095302a47ff90272fb95103457 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-22Catch exception if output.xml failedCédric Ollivier1-15/+19
It protects against a direct call to push_to_db without a previous run even if it can not happen in the current implementation. Change-Id: Ifa00aed60912fa8b96b80d581067548ac6727fb5 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-19Add reporting to DB in OpenDaylightTestingCédric Ollivier2-140/+56
It now relies on Robotframework API instead of parsing output.xml. The type of critical and elapsedime fields are now bool and int respectively. start_date and stop_date has been fixed too. JIRA: FUNCTEST-367 Change-Id: I59f3ad2109345395ccf01a714301a14f9323f088 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-19Modify data sent to testAPICédric Ollivier1-19/+12
It mainly removes prefixes, '#' and '@' and changes details to tests. It deletes useless comments too. Change-Id: I7807a7429a90e7c7c15f8662008a5a768f96be98 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-18Remove useless odlreport2db argsCédric Ollivier1-30/+6
It removes useless odlreport2db args as functest_utils parses env vars too and erases this previous values. All mandatory env vars are still checked in exec_test.sh. Change-Id: I3dd299dcad1758b994cf9d53ef65a5b83dc46b97 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-17Reorder importsCédric Ollivier1-1/+3
It conforms to OpenStack Style Guidelines [1] [1] http://docs.openstack.org/developer/hacking/ Change-Id: I995ff7fa3be995ca59e59c070b93394cd7200066 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-08-16Fix joid test bug that creation of vm failswuwb19891-0/+16
Change-Id: I54d56cb2266ae627e4518f06b14705b672e6f74e Signed-off-by: wuwb1989 <wuwenbin2@huawei.com>
2016-07-30Add onos_sfc scenariowuwenbin22-7/+22
JIRA:ONOSFW-172 Change-Id: I019edf79f8d343f794aa7af151d8e30c18e2c5f6 Signed-off-by: wuwenbin2 <wuwenbin2@huawei.com>
2016-07-20Bugfix: ODL report to DB failsjose.lausuch1-6/+10
JIRA: FUNCTEST-370 Change-Id: I48c8927f3490b86fcf1c95656324429b70201653 Signed-off-by: jose.lausuch <jose.lausuch@ericsson.com>
2016-07-20Remove logger as input parameter of functions in openstack_utilsjose.lausuch1-67/+76
JIRA: FUNCTEST-376 Also some fixes to get rid of flake8 violations in onos-sfc Change-Id: I52c2fd30a6b81af20ea779db2d73b9386524f7ce Signed-off-by: jose.lausuch <jose.lausuch@ericsson.com>
2016-07-19Extend timeout to check vm in onos-sfc testcasewuwenbin21-2/+2
Change-Id: I68ae154391d8098cab3d3cb05cebe6f1922ca701 Signed-off-by: wuwenbin2 <wuwenbin2@huawei.com>
2016-07-15Add functest logger in ODL scriptjose.lausuch1-9/+20
JIRA: FUNCTEST-367 Change-Id: I3a752ca78d274ca8c16f6179534d36f12facc202 Signed-off-by: jose.lausuch <jose.lausuch@ericsson.com>
2016-07-15Push sfc result into DBwuwenbin22-4/+51
Change-Id: I8ab9b5b9322fa3a6905c629e559aa78d9817958f Signed-off-by: wuwenbin2 <wuwenbin2@huawei.com>
2016-07-15Disable ODL test.jose.lausuch3-3/+3
It triggers a lot of errors. See log in the JIRA ticket: JIRA: FUNCTEST-371 Change-Id: Ia039d36773158850f7746ae6d3a2a65fb350e382 Signed-off-by: jose.lausuch <jose.lausuch@ericsson.com>
2016-07-13Propose a new python file to launch ODL testingCédric Ollivier3-103/+116
OpenDaylightTesting.py safely replaces start_tests.sh. It also adds the report of the basic test of RESTConf which was previously ignored. JIRA: FUNCTEST-367 Change-Id: I8ba288271455fd9f31cf87aa65bf45cfb53cd8d6 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-07-13Enhance ips, ports and creds managementCédric Ollivier1-8/+19
It follows the next ODL patch [1] which splits Keystone and Neutron IPs in Robotframework files. It also adds ODL creds, ODL ports and tenant name as inputs. Classical default values are also used now. [1] https://git.opendaylight.org/gerrit/#/c/41554/ Change-Id: I867f1d4c003c4b96a5d4c3e2f982b5a0e3139217 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-07-13Add sfc support for all installers.wuwenbin23-82/+75
JIRA:FUNCTEST-366 Verified in fuel and joid locally. Change-Id: Ife0fd55361e22b9f2003e592b42558860431747a Signed-off-by: wuwenbin2 <wuwenbin2@huawei.com>
2016-07-12Merge changes from topics 'fix_unix_rights_py', 'stop_creating_ODL_dir'Morgan Richomme2-0/+0
* changes: Chmod 755 all py files which can be executed Stop creating the useless ODL results dir
2016-07-12Chmod 755 all sh files which can be executedCédric Ollivier1-0/+0
All files where shebang is defined can now be executed by everyone. It results from [1]. [1] find . -name "*.sh" |xargs grep \#\! |cut -d\: -f 1 |xargs chmod 755 Change-Id: I8bf1f52e55532d5e82f8188121028e9dd5074294 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-07-12Chmod 755 all py files which can be executedCédric Ollivier2-0/+0
All files where __main__ is checked can now be executed by everyone. It results from [1]. [1] find . -name "*.py" |xargs grep __main__ |cut -d\: -f 1 |xargs chmod 755 Change-Id: I9ad153cfdde0447213e35dac102e668d9e754cf9 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-07-11bug fix: use PASS/FAIL in Onos instead of passed/failedMorgan Richomme1-2/+2
Change-Id: I6a293d49476a428b82c472dafa47793c494c2c92 Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
2016-07-08Fix onos sfc's block.wuwenbin22-11/+28
Add ping check before login. Change-Id: If93809ddf727246db453208c79a8e4ecaa288c51 Signed-off-by: wuwenbin2 <wuwenbin2@huawei.com>
2016-07-08Conform start_tests.sh to last ODL patchesCédric Ollivier1-11/+1
It mainly removes all hacks vs __init__.robot which can be deleted since the patches [1] and [2] has been merged. [1] https://git.opendaylight.org/gerrit/#/c/41461/ [2] https://git.opendaylight.org/gerrit/#/c/41463/ Change-Id: I0692681794737c06609e06f88af64edc6fe98efe Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-07-05Change methods to call openstack utilswuwenbin21-48/+23
Change-Id: I3ac1fba007ae91dc8963139caa0d6ac2a48d2ba8 Signed-off-by: wuwenbin2 <wuwenbin2@huawei.com>
2016-07-05Merge "Add interface to run sfc functests."Morgan Richomme1-6/+70
2016-07-04Delete robotframework files hosted by ODLCédric Ollivier3-153/+0
All the modifications done on 010__networks.robot, 020__subnets.robot and 030__ports.robot have been backported to ODL [1]. These files can be safely removed as both repos are now synchronized. [1] https://git.opendaylight.org/gerrit/#/c/40948/ Change-Id: I3e027e41042a25924b9edd0034eddbd895a248fb Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-07-04Add interface to run sfc functests.wuwb19891-6/+70
Varified only in fuel. Prerequisite: no floating ip exists. Change-Id: If6ef4c395992ba1544559b47c5c97f7cd5ce004c Signed-off-by: wuwb1989 <wuwenbin2@huawei.com>
2016-07-03Merge "ONOS sfc scripts"Jose Lausuch3-0/+1043
2016-07-01ONOS sfc scriptsAntonySilvester3-0/+1043
Change-Id: Id314d64cffc3e25b7c3f47e9ff158f79360417e0 Signed-off-by: AntonySilvester <antonysilvester@gmail.com>