aboutsummaryrefslogtreecommitdiffstats
path: root/functest/opnfv_tests/sdn/odl
AgeCommit message (Collapse)AuthorFilesLines
2021-11-15Update linters and fix all new issuesCédric Ollivier1-7/+6
It mostly add encoding in open calls and leverage f-strings. Change-Id: Ifead18fc724a452c1067dcf91dc577032edc9c59 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2021-08-18Update to Alpine 3.14Cédric Ollivier1-2/+2
It also fixes lots of new pylint warnings. Change-Id: I3376aee5649596c53bc2941ad4d8e0674a2967fe Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-07-27Switch to Python 3.7 and Alpine 3.10Cédric Ollivier1-1/+1
It also allows building docs as doc8 is broken due to latest OpenStack's upper-constraints. pylint is updated to 2.3.1 (lastest py3.7 version) It disables perm as umask is currently false on lf-virtual1. Change-Id: If09d4796d48b7d0591e7926621d3bbf5ca1b6c24 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-08-25Remove INSTALLER_TYPE logics in odlCédric Ollivier1-6/+0
JIRA: APEX-621 JIRA: COMPASS-606 Change-Id: I76dde66aefc67f80b40496f705f2864ea9355dcf Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-07-20Stop Fuel logics in odlCédric Ollivier1-4/+1
Fuel is setting the right env vars [1]. [1] https://gerrit.opnfv.org/gerrit/#/c/59929/ Change-Id: Ieb0ae1887859e0b7d3f77dfb5100a633b6479a37 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-07-18Remove logics about Daisy in odlCédric Ollivier1-3/+0
Daisy is now setting the right env vars [1]. [1] https://gerrit.opnfv.org/gerrit/#/c/59839/1 Change-Id: If23c0ac0b5ab2f4f4b9515e27d845cb9c4d07ded Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-07-15Define env vars for ODL inputsCédric Ollivier1-4/+4
It's linked to "Add default param for ODL password" [1]. [1] https://gerrit.opnfv.org/gerrit/#/c/59811/ Change-Id: Ib88d9371a2b6febb5c1af69ffda9b3c5024999e9 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-07-12Protect vs former interface formatCédric Ollivier1-2/+4
Compass still set publicURL [1] [1] https://build.opnfv.org/ci/view/functest/job/functest-compass-baremetal-daily-fraser/lastFailedBuild/consoleFull Change-Id: I88c6ca336a7017f97f4c07719156e567d1afb9df Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-06-19Fix pylint errorsCédric Ollivier1-1/+1
They are highlighted by the last pylint version. Change-Id: I473212a413013492716993fb536903b13bff66ed Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-06-17Mock os.makedirs() in test_odl.pyCédric Ollivier1-3/+2
os.makedirs() is called before calling robot.run. Change-Id: Id651428343510683cd616d8101d22a73ccbf3dad Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-05-12Update ODL testcase to OpenStack ShadeCédric Ollivier1-5/+7
Change-Id: I7832b5ed274e181449f9db9fb03a2d27038520ae Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-04-11Leverage on SDN_CONTROLLER_IP if fuelCédric Ollivier1-7/+1
It conforms with [1]. [1] https://jira.opnfv.org/browse/FUEL-352 Change-Id: Idae142de8de09203509c73c35c2e7fea5a5d880b Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-04-09[fuel] Unite OpenDaylight portsMichael Polenchuk1-1/+1
ODL Oxygen has only 1 connector by default, so unite web and rest ports together. Change-Id: Idd5bdd5da3dcc85fa25b82ab2d19107b2d005974 Signed-off-by: Michael Polenchuk <mpolenchuk@mirantis.com>
2018-03-14Get odl ip from env on CompassLinda Wang1-0/+1
Change-Id: I9ed2cdeef461c27381ecdfd56e5347ded61b5cb8 Signed-off-by: Linda Wang <wangwulin@huawei.com>
2018-03-02Leverage on XtestingCédric Ollivier1-1/+1
It removes all the files which have moved to Xtesting. Vnf inheritances and env management will be improved in other changes. It keeps the same tree thanks to a symlink to allow publishing artifacts. Change-Id: I551bbd3f344cdab0158a50b7b09e541576695631 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-02-26Raise exceptions when SDN_CONTROLLER_IP is NoneCédric Ollivier1-0/+1
Change-Id: Ia0d00a6b3c4c4936dc10602e838f507beea0c592 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-02-22Switch from CONST to CONFCédric Ollivier1-3/+3
It also removes constants.CONST and env.Environment which are now useless. Depends-On: I764a0a2a24447c941d1e726f3116593b29dd1c1e Depends-On: I6cfa832466dcefd737314633d807512e46267a69 Change-Id: Ife41c59d9f2e6ec4e49df38af962039f99554bc5 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-02-16Get properly env vars or their default valuesCédric Ollivier1-6/+5
It defines env.get() as an unique way to get Functest env vars or their default values. It can be considered as a wrapper above os.environ. It enforces backward compatibility via CONST which mustn't be used for that purpose. It should be noted that it also stops using CONST for getting OpenStack env vars. Change-Id: I333dc1afbc0123166a7eaff8b551370098efa341 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-02-15Stop reading SDN_CONTROLLER env var.Cédric Ollivier1-2/+0
Joid doesn't support ODL and this exception is no longer needed. It will be a simple switch from SDN_CONTROLLER to SDN_CONTROLLER_IP if Joid supports ODL again. Change-Id: I925965f9c1adf24914e4110ff3206443f4063ac8 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-02-13Improve the way of setting values in CONSTLinda Wang1-2/+2
Use setattr instead of internal method (__setattr__). It must be completed by patches fixing [1] [2] and [3]. [1] https://jira.opnfv.org/browse/FUNCTEST-930 [2] https://jira.opnfv.org/browse/FUNCTEST-931 [3] https://jira.opnfv.org/browse/FUNCTEST-932 Change-Id: I9558f33f5ed4559b6031d75951d5637c0c0ef8cb Signed-off-by: Linda Wang <wangwulin@huawei.com>
2018-02-08Get neutron endpoint via snaps in odlCédric Ollivier1-5/+6
Change-Id: Iaf0e451e7f6bd7d22459f8d3509b39773527cfea Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-01-31Fix a typo in docstringCédric Ollivier1-1/+1
Change-Id: I4826240a56141771df202b9b3b416d64d2db2cf4 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-11-30Skip modifying creds if Variables.robot is missingCédric Ollivier1-12/+15
Variable.robot is missing in functest-features [1]. As it's related to ODL csit suites, modifying it could be safely skipped as odl.py is designed for testing multiple ODL testcases. [1] https://gerrit.opnfv.org/gerrit/#/c/46225/ Change-Id: Id5f1947a073d251ef7480f418218a4c85fe078c1 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-11-27Create RobotFramework classCédric Ollivier1-88/+25
It moves the capability to run any robot script from ODL TestCase into a new class: RobotFramework. It updates ODL TestCase and the related unit tests to inherit from the new parent class. Change-Id: I73e59ee9652fb63d9d89d7c75c58cce9cf62b0d7 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-09-28Switch to OS_PROJECT_NAMECédric Ollivier1-4/+4
It simply conforms with OpenStack keystone v3. JIRA: FUNCTEST-877 Change-Id: I989a6eb4d8564948927c184a899b62ca763ef824 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-09-22Support https when testing ODLCédric Ollivier1-16/+18
It conforms with the last change on ODL tests [1]. Neutron endpoint is passed via robot args instead of Neutron ip. Keystone url (based on OS_AUTH_URL) is passed too to replace Keystone ip. [1] https://git.opendaylight.org/gerrit/#/c/63293/ Change-Id: Ie44f55304a438b1b0289ec69ac2241664be70e80 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-09-08Update ODL testcase to Keystone v3Cédric Ollivier1-1/+16
As basic neutron tests have been updated [1], ODL testcase must manage user domain and project domain names. [1] https://git.opendaylight.org/gerrit/#/c/62846/ JIRA: FUNCTEST-862 Change-Id: I61ef622f840b8d825cf45a3557bd6da14a4d3cb7 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-09-07[Fuel/MCP] Set opendaylight web/restconf portsMichael Polenchuk1-1/+2
Change-Id: I24518bdf54974debf49df6d775db1203e61922e5 Signed-off-by: Michael Polenchuk <mpolenchuk@mirantis.com>
2017-08-02Add all ODL testcases in functest-smokeCédric Ollivier1-2/+1
It clones the related git repositories in /src and adapts the former Dockerfiles too. Change-Id: Ied5016f8cd5ed49f4e29bae5aa4413fad2477637 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-07-13Correct odl port for compass installerYifei Xue1-1/+1
For the port 8181 has been used by OSA repo LXC in compass deployment. So we change the port here in functest to 8080. Change-Id: Ia262319f7513497db6e849521de6be6328ec97ba Signed-off-by: Yifei Xue <xueyifei@huawei.com>
2017-07-12Add odl configurations for odl testcase in daisy environmentAlex Yang1-0/+4
To support odl testcase in the environment deployed by daisy installer. Change-Id: I70bc668520cf28385fcff8489c773b880e7b4080 Signed-off-by: Alex Yang <yangyang1@zte.com.cn>
2017-06-30Define ODL console_scriptCédric Ollivier1-12/+15
main() is excluded from coverage as it usually parses argv. It also renames ODLTests main() to run_suites() not to exclude this method. Change-Id: I3109a65166b21d93e3e376912a32d364931a7ba5 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-06-02Use constants in odlLinda Wang1-3/+5
Change-Id: I134b0efd3dd0faec389087a4dac59de09eae087e Signed-off-by: Linda Wang <wangwulin@huawei.com>
2017-05-22Merge "Precise self.result in pytest_suite_runner.py"valentin boucher1-1/+1
2017-05-19Precise self.result in pytest_suite_runner.pyCédric Ollivier1-1/+1
It also adds the related unit tests. Change-Id: I8325bd9a55c69b229e3c48a9e64aa963e685e03d Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-05-18Use StringIO in odl.pyCédric Ollivier1-13/+5
It avoids creating and removing the temporary file to dump robot output. Change-Id: Ia5ea66e76ffb8b8327f2da938f177e8ef4c61dd4 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-05-17Add Python3 support to the ODL testcaseCédric Ollivier1-5/+5
It also adds this support to its dependencies. Change-Id: I0534f0c7b0e15a9ee89f522f314cf5200874454c Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-05-09Conform ODL with last framework updatesCédric Ollivier1-1/+8
Now ODL TestCase calculates the ratio between critical tests passed and failed and saves it in result. Non-critical test cases can fail as result doesn't take them into account [1]. It also updates default attribute values in TestCase and allows result to be float. [1] http://robotframework.org/robotframework/latest/RobotFrameworkUserGuide.html#setting-criticality Change-Id: Id4a89271b5b1a90cd3c1e2b08591ff26ffaffee0 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-05-04Define loggers as class-private membersCédric Ollivier1-15/+15
This mangling ensures that all info messages printed from core packages are shown in console. It also avoids sphinx to print them. Change-Id: I07db9f33060c195bce3b48b06a6640eb6c56c2eb Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-05-04Delete functest.utils.functest_loggerCédric Ollivier1-2/+3
It deletes functest.utils.functest_logger and the related unit tests. Then it modifies all functest modules to get all loggers via logging.getLogger(). __name__ is mainly used as getLogger arg as proposed by logging [1]. All loggers and handlers are now defined via functest/ci/logging.ini instead of a dict loaded by an external json file. Now only warn messages and info messages from ci and core packages are printed in console. [1] https://docs.python.org/2/library/logging.html Change-Id: Ic192855e0f9bf94825d8f7ec73549a0f3b8d44c5 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-04-26Switch TestCase attribute criteria to resultCédric Ollivier1-1/+1
It mainly avoids mixing input and output. Criteria is now an input set in functest/ci/testcases.yaml and then must be passed as __init__() args (which will be proposed in an additional change). Then it also renames the related TestCase method to check_result(). Change-Id: Ifc3c8e3ea6cde7e3edf7174bed4bf2bf0894e8e3 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-04-18Fix Sphinx warnings/errorsCédric Ollivier1-2/+3
It takes into account the following warnings/errors: - Inline strong start-string without end-string - Unexpected indentation Change-Id: Idb05c7b04ba98ef8f3ef65e6ec7c9bb5b7571cad Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-04-04Add case_name as constructor argCédric Ollivier1-4/+0
It allows managing multiple TestCase names with only one TestCase module. It is mainly required by odl which implements: - odl, - odl_netvirt, - fds. It also renames case to case_name in Features to conform with TestCases. JIRA: FUNCTEST-762 Change-Id: Ie254f754a0ea3077a8afda1c470528d38c79478f Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-03-28Add docstrings in odlCédric Ollivier1-0/+69
It has been rated at 10.00/10 by pylint. Change-Id: If45656080a47c2582556f841a02379b37e481fd9 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-03-27Fix pylint warnings in odlCédric Ollivier1-26/+30
It takes into account the following warnings: - invalid-name - logging-not-lazy - dangerous-default-value - broad-except (locally-disabled) - too-few-public-methods (locally-disabled) Change-Id: Iec59108cc16872090c5def0bb38c10a7aeec46fc Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-03-27Rename testcase_base to testcaseCédric Ollivier1-5/+5
It simply removes the useless suffix. Change-Id: Ib9a682b57d8f33518359d817a593bb3786577390 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-03-27Switch TestcaseBase to TestCaseCédric Ollivier1-4/+4
It partially reverts "Rename TestCasesBase into TestcaseBase" [1] and removes the useless suffix too. [1] https://gerrit.opnfv.org/gerrit/#/c/25391/ Change-Id: Iddf2ec8d6c1dafe6e4c6713c2e69969613317471 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-03-09Introduce smoke tests for FDSTomas Cechvala1-7/+9
Added: - fds repository to docker file - fds test to smoke tier in testcases - config values for fds tests A new robot var OS_AUTH_URL is defined as expected by FDS robot files. Method args switch from Keystone IP to OS_AUTH_URL which is more precised. The argument parsing is changed too. Co-Authored-By: Cédric Ollivier <cedric.ollivier@orange.com> Change-Id: Ife27ab4a83f0110cbdcf7c9d47d9b3fb4c0ec705 Signed-off-by: Tomas Cechvala <tcechval@cisco.com> Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2017-02-23Use new-style classes which inherit from objectLinda Wang1-1/+1
JIRA: FUNCTEST-707 Change-Id: Ieaa888375136eddbbe003a24b32bf09fd0f92923 Signed-off-by: Linda Wang <wangwulin@huawei.com>
2017-02-13Revert "write test results to a local file"Cédric Ollivier1-1/+1
This reverts commit ee21af78fbfc93e888acda121f08d2b216dd0159. Change-Id: If7c8d3b645073574862eb67225b1e11b0dd7a021 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>