summaryrefslogtreecommitdiffstats
path: root/run_unit_tests.sh
AgeCommit message (Collapse)AuthorFilesLines
2017-05-19Set default value for CONFIG_FUNCTEST_YAMLCédric Ollivier1-1/+0
It calculates via the full path of env.py. Change-Id: Ief958833f5116cdb116d0153d85a0ae03063ec5c Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-05-17Clean test-requirements.txtCédric Ollivier1-1/+4
Now only the mandatory requirements related to unit testing are listed in test-requirements.txt. Change-Id: I2f17a9e18e90d779ddc80b1ace9ac770a76c3385 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-04-30Restrict coverage output to all functest packagesCédric Ollivier1-12/+1
The next packages/modules are not yet covered: - functest/cli/setup.py - functest/core/pytest_suite_runner.py - functest/opnfv_tests/mano - functest/opnfv_tests/openstack/examples - functest/opnfv_tests/openstack/snaps - functest/opnfv_tests/openstack/vping - functest/opnfv_tests/sdn/onos - functest/opnfv_tests/vnf/aaa - functest/opnfv_tests/vnf/ims - functest/opnfv_tests/vnf/router - functest/utils/openstack Change-Id: Id62749796864537615f0ca8b162ce77b6c1a3309 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-04-14Remove deprecated feature modulesCédric Ollivier1-1/+0
All features running bash programs are now simply defined in testcases.yaml. All deprecated modules and unit tests are removed. Change-Id: I7047b6f7a1e43cb8ed5ba2d569d5dcecae68fb86 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-04-08Add unit tests for parserCédric Ollivier1-0/+1
It also fixes the corresponding case name in testcases.yaml. Change-Id: I2b93323a18bb192d9ad35823dc48b236cb6841b1 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-04-04Add unit tests for featureCédric Ollivier1-1/+1
They partially cover feature but already highlight bugs. Several tests are skipped to allow merging. Their decorators could be removed as soon as feature is fixed. I think bad-continuation is false positive so it's disabled (pep8 and flake8 return ok). JIRA: FUNCTEST-779 Change-Id: I89b9e2ec0388eea2471d941b2c653deca7fbddf6 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-04-04Add unit tests for barometerCédric Ollivier1-0/+1
2 tests are skipped to allow merging [1] [1] https://jira.opnfv.org/browse/FUNCTEST-777 Change-Id: Ida376a03266489e252f7ef8de1ff40f1474c500a Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-03-27Rename testcase_base to testcaseCédric Ollivier1-1/+1
It simply removes the useless suffix. Change-Id: Ib9a682b57d8f33518359d817a593bb3786577390 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-03-10Merge "Unit tests added for openstack/tempest"Morgan Richomme1-1/+1
2017-03-09Optimize releng cloning when running unit testsMorgan Richomme1-3/+1
not need to clone full releng depth 1 is enough do not go out of workspace anymore..never... Change-Id: I1d2dbc30bec6c168ef7ddf3327cb00fff4056aa1 Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
2017-03-08Bugfix: modify test_prepare_env to make verify job successfulLinda Wang1-3/+5
Functest verify job failed due to that test_prepare_env.py mistook one function of ft_utils.execute_command_raise. Change-Id: Ib3b8ca807308bf5c6d250e7debb4c9e1e106e3d1 Signed-off-by: Linda Wang <wangwulin@huawei.com>
2017-03-01Unit tests added for openstack/tempestashishk19941-1/+1
_parse_verification_id method is removed as it is not used anywhere Change-Id: Ia2bc75ffbc2527b04cbe2428e2a3822803bde215 Signed-off-by: ashishk1994 <ashishk.iiit@gmail.com>
2017-02-22Unit tests for vnf/ims.ashishk19941-0/+1
Change-Id: I12b17ee7ed03987473825e0705074f0430b820bb Signed-off-by: ashishk1994 <ashishk.iiit@gmail.com>
2017-02-07Releng environment in unit testing.ashishk19941-1/+8
Most of modules in ci, openstack are dependent on opnfv_module. This patch will install the releng modules in unit test environment. Credits: https://gerrit.opnfv.org/gerrit/#/c/26501/2/run_unit_tests.sh Change-Id: Ibc5edeaf8439b8a5e874ee842c119480ed2e517b Signed-off-by: ashishk1994 <ashishk.iiit@gmail.com>
2017-02-03Unit tests for openstack/rally.ashishk19941-0/+1
Few bug fix in rally code along with unit tests. Change-Id: Id39a5089ca6fce8aac5ba89eb61d31b02a5e9a98 Signed-off-by: ashishk1994 <ashishk.iiit@gmail.com>
2017-01-19Leverage logging config and refactor the loggerhelenyao1-0/+1
JIRA: FUNCTEST-690 The detailed benefits are listed in the JIRA description. 1. Refactored the functest_logger to make use of configuration file 2. Avoided configuring the logging every time a logger is initialized 3. Applied separate logging configuration fo unit test by removing saving log to file Change-Id: I6e27eaba727ae6d704f0301f15359dc3ea7b2f97 Signed-off-by: helenyao <yaohelan@huawei.com>
2017-01-04Remove clean_results_dirCédric Ollivier1-22/+0
clean_results_dir is now useless [1] [1] https://gerrit.opnfv.org/gerrit/#/c/26661/ Change-Id: I7ec02798696d4cbc4930bf2d8aa9cb35ce99b7aa Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-01-04Use mock_open() to prevent stdout.txtCédric Ollivier1-7/+0
/home/opnfv is no longer required. Change-Id: Iefb8faf3a7d548f3ae7d4076005d7b0bb93e63e1 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-01-04Patch logging.FileHandlerCédric Ollivier1-3/+0
It avoids creating a dummy functest.log for unit testing. Change-Id: Ib163d5d58284822b1904444fb60b08e92ee0ab9b Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-01-04Merge "Added unit tests for utils/functest_utils.py."Morgan Richomme1-0/+1
2017-01-04Added Unit Tests for cli.ashishk19941-0/+1
JIRA: FUNCTEST-590 Change-Id: I5e28145cae742598927e8edbe65091fedb533a4d Signed-off-by: ashishk1994 <ashishk.iiit@gmail.com>
2017-01-02Added unit tests for utils/functest_utils.py.ashishk19941-0/+1
JIRA: FUNCTEST-683 Change-Id: I181d98847b2ca94ce84a670239b8a958bfae44cd Signed-off-by: ashishk1994 <ashishk.iiit@gmail.com>
2016-12-27bugfix: clean results directory errorSerenaFeng1-8/+9
change 'rm -rf /home/opnfv/functest' to 'rm -rf /home/opnfv/functest/results' and extract the clean logic to a common method clean_results_dir Change-Id: I8aa0b09b58d9c14e53c2d4f2bb39376239e41168 Signed-off-by: SerenaFeng <feng.xiaowei@zte.com.cn>
2016-12-14Authenticate clients with keystoneauth1.sessionhelenyao1-0/+1
JIRA: FUNCTEST-529 1. use keystoneauth1.session to initialize the client for each service The keystoneauth1.session.Session class was introduced into keystoneauth1 as an attempt to bring a unified interface to the various OpenStack clients that share common authentication and request parameters between a variety of services. 2. update ODL case to leverage session to get the endpoint info Change-Id: Ic8c01b9b7ed86d3bdd9f5125504bc47f46a37700 Signed-off-by: helenyao <yaohelan@huawei.com>
2016-12-07Get rid of easy_install in unit testhelenyao1-7/+3
JIRA: FUNCTEST-638 Pip is a better alternative to Easy Install for installing Python packages. There is no need to install easy_install. Change-Id: I3dee17a800d11907c7f0942bff251a93675978bb Signed-off-by: helenyao <yaohelan@huawei.com>
2016-12-05test-requirements.txt is added for unit test.helenyao1-1/+3
JIRA: FUNCTEST-639 Some requirement packages are only needed by unit test and there is no need to include them in requirement.txt. This is the main reason to create a test-requirements.txt to hold all packages required by unit test. Change-Id: Iefa9f54b57666d30044ec174adfeb22d63b6b139 Signed-off-by: helenyao <yaohelan@huawei.com>
2016-12-02Rename TestCasesBase into TestcaseBasehelenyao1-1/+1
JIRA: FUNCTEST-628 1. rename the TestCasesBase into TestcaseBase 2. updated the module name to testcase_base.py Change-Id: Ic6b5d8209098c136613a2419c3790668fdbd493e Signed-off-by: helenyao <yaohelan@huawei.com>
2016-11-28Merge "Lifted requirements.pip one level up to meet the basic structure of ↵Morgan Richomme1-1/+1
OpenStack project."
2016-11-25Lifted requirements.pip one level up to meet the basic structure of ↵helenyao1-1/+1
OpenStack project. JIRA: FUNCTEST-609 1. Lifted the requirements.pip 2. Renamed it to requirements.txt 3. Updated the areas that are affected Change-Id: If294f07fb5450f3ae6133fd46dc169b9bab451de Signed-off-by: helenyao <yaohelan@huawei.com>
2016-11-25file/dir renaming for consistencyMorgan Richomme1-1/+1
JIRA: FUNCTEST-579 Change-Id: Iaa545db70bfb76770df0a3d17871e29ce518ff2d Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
2016-11-24Extracted all global parameters into functest_constants.pyhelenyao1-0/+1
JIRA: FUNCTEST-533 1. Extracted all global variables into functest_constants.py and updated all affected areas accordingly 2. Used os.path.join to replace '/' to come up with the path for better cross-platform support and improve the path accuracy 3. Removed unused variables 4. Updated the hardcoded path in Dockerfile by using variable reference 5. Removed "/" ending from all path variables 6. Updated the unit test Change-Id: Ib30a81d1f0c83fbaef042d63c187c27bd18301bb Signed-off-by: helenyao <yaohelan@huawei.com>
2016-11-18Adapt Domino to Test AbstractionMorgan Richomme1-1/+1
JIRA: FUNCTEST-547 Change-Id: Iaeb1bb3e6f4529343eacc2f5ceda6d61ca6d96f7 Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
2016-11-09Repo structure modificationMorgan Richomme1-24/+1
- create functest subdirectory - rename unit tests - adapt path in exec and config files JIRA: FUNCTEST-525 Change-Id: Ifd5c6edfb5bda1b09f82848e2269ad5fbeb84d0a Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
2016-11-04bug fix on log file creation for unit testsMorgan Richomme1-8/+5
JIRA: FUNCTEST-326 Change-Id: Iae797d00c0bda07fce098f4a054dfc8f5bba069b Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
2016-11-04Add exit return code for unit testsMorgan Richomme1-5/+80
Note that this patch should trigger some refactoring 1: repo structure, uggly hack due to the fact that the code is at the root of the repo. The name can be change when cloning leading to python path issues 2: logger is called with harcoded file in functest_logger.py uggly hack to create the file is not already present Basically hacks were necessary to be able to run the unit tests locally and from jenkins JIRA: FUNCTEST-336 Change-Id: Ib88256a167c003805d480f57c218c37d8d5962d8 Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>
2016-10-20Fix nosetests call in run_unit_tests.shCédric Ollivier1-1/+2
It adds the missing whitespace and only lists the packages for which unit tests have been developped. It also adds python-neutronclient as requirement. Change-Id: Id14b0698cb3636333751d61ff954500a665e1551 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2016-10-19Add unittests dirMorgan Richomme1-0/+25
JIRA: FUNCTEST-336 Change-Id: Icd958552fafb4e8dc58f9008586bcaf33862ccd4 Signed-off-by: Morgan Richomme <morgan.richomme@orange.com>