aboutsummaryrefslogtreecommitdiffstats
path: root/functest/opnfv_tests/openstack/tempest/tempest.py
AgeCommit message (Collapse)AuthorFilesLines
2023-05-13Complete migration to Cirros 0.6.1Cédric Ollivier1-1/+1
Change-Id: I2fed5dc5798a3d217be032d754da9f7dbbbd30d0 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2021-11-15Update linters and fix all new issuesCédric Ollivier1-37/+34
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-70/+68
It also fixes lots of new pylint warnings. Change-Id: I3376aee5649596c53bc2941ad4d8e0674a2967fe Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2021-05-19Configure dashboard.dashboard_url if tempest_slowCédric Ollivier1-15/+14
Tempest Horizon is now also executed in tempest_slow. Change-Id: I910adc68eeb067d089b705feb794911afd1747e0 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2021-05-17Update scenario img_file in tempest.confCédric Ollivier1-3/+2
It's now an absolute filename [1]. It also updates the cirros version. [1] https://github.com/openstack/barbican-tempest-plugin/commit/3f35bff1e19e9ff20bec6d5bbebcd5bb2b10fb49 Change-Id: I6c88b2a6347094466359304d99a2e8195f7ae049 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com> (cherry picked from commit c068c042c8a9c02a7ba9c30257e897dab7705b2d)
2020-12-10Set NEW_USER ROLE in tempest_heat classic userCédric Ollivier1-0/+3
Else it fails when member is not the default role. Change-Id: I1c830705b94a116ef56d83ebcd59145cd40e59a5 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-12-08Rather use rconfig.has_option() insteadCédric Ollivier1-1/+1
It slightly increases py2 and py3 to ease next backports. Change-Id: I168044d85469e92f970e983f4bdfe627d3763e61 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-12-08Concat both dynamic and static roles in tempest.confCédric Ollivier1-13/+28
It also moves all auth logic in a specific method. Change-Id: I95ecce84ef202c8fe72719c2263d96a76070c571 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-12-04Stop setting floating_ips in tempest_conf.yamlCédric Ollivier1-0/+1
It's now handled by tempest.py Change-Id: Iaeefd70f95a3c64c7ca41b984e934c4aeadea8ab Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-11-27Protect vs false detected external networks if l2-onlyCédric Ollivier1-2/+4
Change-Id: I0e58c9df0e9971fcdae5fa7b209940569ae51a78 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-11-26Allow running tempest without tenant network resources.Cédric Ollivier1-8/+32
It fits the Airship deployment where there is neither tenant networks nor floating ips. It only updates the scenarios and must be completed by other changes for all the advanced testcases (Rally, Tempest, etc) Change-Id: I8077400536628ed2349b548efee3c3e165a0a5c3 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-07-03min_computes_nodes is also used as max valuesCédric Ollivier1-15/+2
Its max value is now 10 according to the default quota. Change-Id: Ie7bfcb224e821c15d38d0cba1d9f080548613e79 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-05-24Precise validation configs in NeutronCédric Ollivier1-0/+11
ServerActionsTestJSON.test_reboot_server_hard [1] sometimes fails in gates. We may increase timeouts if it stills fails. [1] http://artifacts.opnfv.org/functest/LIQH38CPR30X/functest-opnfv-functest-smoke-hunter-tempest_full-run-649/tempest_full/tempest-report.html Change-Id: Ia27c0faead1df5c2b33a3e1a272e5a1010a5a83e Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com> (cherry picked from commit 7ccc1b0793e32cad3912e63bbca971d5c3ecd724)
2020-04-28Move static data to tempest_conf.yamlCédric Ollivier1-1/+0
Change-Id: I99f33f2e5f27c22c597f7c4f2f864710ceb1350e Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-04-19Run sequentially tempest_heatCédric Ollivier1-0/+2
It's forced by design else it remains a few resources. It also sets fixed_subnet_name and network_for_ssh to avoid falsy discovery as it seems [1] [1] http://artifacts.opnfv.org/functest/X5GDYF3B0R2B/functest-opnfv-functest-smoke-jerma-tempest_heat-run-18/tempest_heat/tempest-report.html Change-Id: Ieb584ddc1c0b4ebb543e9d69277a20aaee0fbac0 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-04-06Add tempest_heat (heat-tempest-plugin)Cédric Ollivier1-0/+66
It asks for the Fedora-Cloud-Base image and a second user account. It should be noted that heat-tempest-plugin duplicates all configs from tempest. Minimal image is still Cirros and the first account is the admin one. Then it conforms with the TempestCommon logic. AodhAlarmTest is skipped by default because pre conditions are missing. SoftwareConfigIntegrationTest is skipped as in gates because it requires a custom image [1] [1] https://github.com/openstack/heat/blob/master/devstack/lib/heat#L444 Change-Id: I8b39dc65ef3714411cd828e17b95e124f2e90f34 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2020-03-23Doesn't redirect stderr when getting verifier idCédric Ollivier1-1/+1
The logic fails when rally produces warnings [1]. It also updates Rally OpenStack and checks if the previous error has been solved[2]. TypeError: _discover_or_create_flavor() missing 1 required positional argument: 'flv_disk' [3] [1] https://build.opnfv.org/ci/job/functest-opnfv-functest-healthcheck-latest-tempest_smoke-run/757/console [2] https://github.com/openstack/rally-openstack/commit/e62315115af20e53f6c7205494ba0008634047ed [3] https://build.opnfv.org/ci/job/functest-opnfv-functest-healthcheck-latest-tempest_smoke-run/629/console Change-Id: Ia1daaa76d7cef7f30904c1f3bd42e2f6a6ba10af Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-11-26Update scheduler_available_filtersCédric Ollivier1-7/+0
Else few tests are skipped if DifferentHostFilter is not available. Change-Id: Idfc524216dc8503e590d4fed569a43e99ea22123 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-10-26Add healthcheck Horizon testsCédric Ollivier1-0/+15
It runs TestDashboardBasicOps as proposed by tempest-horizon [1]. It's skipped if DASHBOARD_URL is unset (default). [1] https://opendev.org/openstack/tempest-horizon Change-Id: I1b6b5609412770609f412da4927641588b173ed6 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-10-24Merge "Allow checking Tests count"Cedric Ollivier1-0/+4
2019-10-23Allow checking Tests countCédric Ollivier1-0/+4
It meets CNTT requirements (verifying conformance with a reference implementation) and may protect vs synchronization issues (see gambia refstack_defcore). Change-Id: I842bc4ed91eec6bc545c489e3686d0d41dae7b44 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-10-23Allow blacklisting tests if public endpoint onlyCédric Ollivier1-3/+9
It allows reusing the blacklisting system if only public endpoints are reachable (ONAP Openlab testing). It contains a first list of tempest-based tests which force the use of admin endpoints. Change-Id: Ic1ab07dec3ae1f2a0ca50b80e08cd0ac396f2e56 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-10-08Count all hypervisors by defaultCédric Ollivier1-1/+1
If one hypervisor is down, few tempest test fails. User is free to set SKIP_DOWN_HYPERVISORS if it's down on purpose. Change-Id: I7b6a4d0d8f67755d8c1550fd1bc6fd707634f68b Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-09-30Count all active hypervisorsCédric Ollivier1-2/+1
Else tempest_slow fails if one hypervisor is down (detected in ONAP Openlab). It also improves Shaker, Rally and Vmtp which count them. Change-Id: Iee7c20e0357d9237501c5c451580d8f6409ac86b Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-09-19Remove any cores quota in tempest_scenario and shakerCédric Ollivier1-1/+3
Both can reach the default limit if lots of computes available. Co-Authored-By: Vincent Huet <vincent.huet@orange.com> Change-Id: Ifd8a1080a08f55bf4b0efe1858e79fa4aff75895 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-09-14Remove any instance quota in tempest_scenarioCédric Ollivier1-0/+12
The next testcase can reach the default limit if lots of computes available [1]. tempest.scenario.test_server_multinode.TestServerMultinode.test_schedule_to_all_nodes [1] http://artifacts.opnfv.org/functest/functest-opnfv-functest-smoke-hunter-tempest_scenario-run-325/results/tempest_scenario/test_raw_list.txt Change-Id: Ibf68e2a367199afee3f6198ebf683be6cd938d94 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-08-26Support regex in tempest blacklistJuha Kosonen1-5/+4
The expression both in the test cases as well as applicable scenarios support regex in blacklist. Change-Id: Id76297a1cfbf908bda67641bc7ba686db83d76e6 Signed-off-by: Juha Kosonen <juha.kosonen@nokia.com>
2019-07-27Switch to Python 3.7 and Alpine 3.10Cédric Ollivier1-10/+10
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>
2019-06-02Publish rally logsCédric Ollivier1-22/+2
Both Rally and Tempest publish Rally debug logs. It also moves the logics from tempest to rally. Change-Id: I5c057d830202baddd73577ade1b09ce304e3c5a5 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-05-25Set utf-8 in decode and encode callsCédric Ollivier1-11/+11
It eases backporting in iruya and hunter as a few logs can't be decoded as ascii [1]. [1] https://build.opnfv.org/ci/job/functest-opnfv-functest-vnf-iruya-juju_epc-run/56/console Change-Id: I52a6f9a25130cbf62e8ce3b9972064ab73177665 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-05-24Decode Bytes in logging callsCédric Ollivier1-5/+5
It fixes a few incorrect types in log calls [1]. [1] https://build.opnfv.org/ci/view/functest/job/functest-latest-daily/163/ Change-Id: I01790f6454694f434d31366f9c1cf9d98ff5a9cf Signed-off-by: Cédric Ollivier <ollivier.cedric@gmail.com>
2019-05-13Update to Python3Cédric Ollivier1-14/+14
Functest containers leverage on Python3 instead of python2. https://mail.python.org/pipermail/python-dev/2018-March/152348.html It also updates robotframework librairies to latest release and Vmtp to master ([1] is needed) It patches cloudify rest client to support python3. Vmtp is currently disabled because it currently supports python2 only. [1] https://github.com/openstack/vmtp/commit/a5d062881d91bf4f547d92c6e289bea30feb5d6e#diff-b4ef698db8ca845e5845c4618278f29a Change-Id: I39964a212ec2d4dbf53c9ea7c63f02e0b6a05b48 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-04-24Refactor modules to avoid duplicated codeCédric Ollivier1-12/+1
It also increases number of lines to warm about duplicated codes. Change-Id: I3914da8a90cbfe8fd024e9944c3adc8a617330d3 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-04-15Stop forcing admin_scope_domain = TrueCédric Ollivier1-1/+0
tempest fails vs devstack stable/stein and it passes successfully vs devstack stable/rocky (Functest gates) without that option. It may be added to tempest_conf.yaml if SUT requires it. Change-Id: I4730c25b25403fd130d71166a8778e06fd479935 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-03-19Do not allow testcase skipping in refstackJuha Kosonen1-0/+8
Set the result of refstack_defcore as failed if there were skipped testcases in a run. Change-Id: Id782c2dee511cefbafd5b4440f386fd66f934a47 Signed-off-by: Juha Kosonen <juha.kosonen@nokia.com>
2019-03-07Merge tempest.py and conf_utils.pyJuha Kosonen1-10/+185
Change-Id: I597abdbb5bd3de023aa7b66fa27764ca2ec27f0d Signed-off-by: Juha Kosonen <juha.kosonen@nokia.com>
2019-02-27Gather all skipped tempest test casesPanagiotis Karalis1-1/+1
This patch applies a change to the regex responsible for identifying Tempest test cases. With the current regex some skipped test cases are erroneously ignored. The condition has been updated in order to match both format of skipped testcases ('skip:' and 'skip [xxx]:') Change-Id: Ie7144b01e07cae92918eede0324f3f1f2582c4aa Signed-off-by: Panagiotis Karalis <pkaralis@intracom-telecom.com>
2019-02-14Generate xunit reports (rally and tempest)Cédric Ollivier1-10/+8
It adds xunit reports for rally-based and tempest-based testcases. It completes the reports provided by snaps (thanks to Xtesting). All rally related operations are moved to rally. It allows removing the rally dependency to tempest which was false. Change-Id: Ia7d2476f58f4f68b7c88442e50cad844037a36e9 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-02-13Publish tempest details into databaseCédric Ollivier1-1/+1
It switches from tempest.log to rally.log to conform with rally/stestr. Change-Id: I00c2a268a2bc312a22a8d70278fad618c1c25235 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-01-20Fix one typo in docstring (tempest.py)Cédric Ollivier1-1/+1
Change-Id: I46053c92660139f4004d9cec8d1cfb6817cc0e07 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-01-19Take control over Rally logicsCédric Ollivier1-4/+25
Rally selects the first external network [1] which could raise side effects if: - another testcase is creating a dummy external network in // - all external subnets are not reachable from jumphost It's now overriden by EXTERNAL_NETWORK as defined in Functest Rally creates a new shared network if one already exists [2]. As juju now allows other shared networks, it can be safely created by Functest to allow only one logic and to handle provider networks, different name servers, etc... [1] https://github.com/openstack/rally-openstack/blob/master/rally_openstack/verification/tempest/config.py#L146 [2] https://github.com/openstack/rally-openstack/blob/master/rally_openstack/verification/tempest/context.py#L85 Change-Id: Icf8c08077d4b0a9eb1c2e1b7309c62957b0a3b63 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2019-01-19Move logics out of TempestCommon.__init__()Cédric Ollivier1-22/+33
It conforms with best programming practices. It allows muting console and increasing log level (debug). Change-Id: I0e0cfef6abe3b354a43817fcb242c71da701e237 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-11-10Check if at least 1 hypervisorsCédric Ollivier1-1/+1
Vmtp is skipped if only one hypervisor. As Vtmp returns 0 when all is skipped, it protects vs issues when generating charts. Change-Id: I5ea7c31c0688ae773425d2192a4f30a22360185f Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-10-21Harden Rally generate reportCédric Ollivier1-3/+2
It converts html_file to str and raises all possible exceptions. It sometimes fails when locally generating reports. Change-Id: Idf6a12aaac4561800cd5e364f8bcc495aabbee1d Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-10-14Fix image properties parsingCédric Ollivier1-4/+4
It removes useless spaces and now conforms with oslo.conf dict. New helpers and unit tests are available. Change-Id: I20335c5e5c3840cc872e158c6072d97a3f2cb98c Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-10-06Merge "Rename IMG_PROP to IMAGE_PROPERTIES"Cedric Ollivier1-4/+5
2018-10-06Rename IMG_PROP to IMAGE_PROPERTIESCédric Ollivier1-4/+5
Any other env vars are reduced. Change-Id: Ic2c37d6efd543603a2495f9d2621b66d61710a54 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
2018-10-06Merge "Use environment variable for image properties"Cedric Ollivier1-0/+4
2018-10-05Use environment variable for image propertiesDelia Popescu1-0/+4
Use IMG_PROP environment variable to read extra image properties. Set image_extra_properties for scsi volume types without file patch, but using IMG_PROP env variable IMG_PROP is defined through releng. Image extra_properties will continue to get updates from functest config file With this change, remove unnecessary parameters from arm patch Related to:https://gerrit.opnfv.org/gerrit/#/c/63203/ JIRA:ARMBAND-402 Change-Id: I64139240751b1e109bbe24ba32f487ccd98b9a92 Signed-off-by: Delia Popescu <delia.popescu@enea.com>
2018-09-23Protect vs former OS env varsCédric Ollivier1-0/+5
rally_jobs is failing vs APEX which still sets OS_TENANT [1]. [1] https://build.opnfv.org/ci/view/functest/job/functest-apex-baremetal-daily-master/324/console Change-Id: I672bfa93b37b1b773ea7d20fdd91bea0ff14b79f Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>