From 7fe3e03df1b0bdbe8026918caf1e10b560b338d1 Mon Sep 17 00:00:00 2001 From: "jose.lausuch" Date: Tue, 16 Jun 2015 11:47:19 +0200 Subject: Doc: adapted image size for pdf as Victor suggested JIRA: FUNCTEST-9 Change-Id: I8eda7d18c1d4e1a652089e99a8e0d9f3b24a617d Signed-off-by: jose.lausuch --- docs/functest.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs') diff --git a/docs/functest.rst b/docs/functest.rst index 515ab6986..b95988609 100644 --- a/docs/functest.rst +++ b/docs/functest.rst @@ -580,11 +580,11 @@ The results of ODL tests can be seen in the console:: ODL result page .. figure:: ./images/functestODL.png - :scale: 50 % + :width: 170mm :align: center :alt: ODL suite result page - + Known issues ------------ -- cgit 1.2.3-korg From 2f8e2e4194f335407e62f6b7a28ca28730c4f969 Mon Sep 17 00:00:00 2001 From: "jose.lausuch" Date: Wed, 17 Jun 2015 09:54:04 +0200 Subject: Doc: adapted table page 6. "The procedure to set up functional testing environment can be described as follow:" JIRA: FUNCTEST-9 Change-Id: If8f30b9e0071e8273cc2553327a4d814bfef6040 Signed-off-by: jose.lausuch --- docs/functest.rst | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'docs') diff --git a/docs/functest.rst b/docs/functest.rst index b95988609..4276594e6 100644 --- a/docs/functest.rst +++ b/docs/functest.rst @@ -298,19 +298,19 @@ For the Continuous Integration we store this file under $HOME/functest/opnfv-ope The procedure to set up functional testing environment can be described as follow: - Log on the Jumphost server - Be sure you are no root then execute:: - - [user@jumphost]$ mkdir - [user@jumphost]$ cd - [user@jumphost]$ git clone https://git.opnfv.org/functest - [user@jumphost]$ cd testcases/ - - Modify and adapt needed parameters in the config_functest.yaml. Follow the instructions below. - Retrieve OpenStack source file (configure your `OpenRC`_ file to let Rally access to your OpenStack, you can either export it from Horizon or build it manually (OpenStack credentials are required):: - - [user@jumphost]$ source Your_OpenRC_file - [user@jumphost]$ python /config_functest.py -d start +Log on the Jumphost server. Be sure you are no root then execute:: + + [user@jumphost]$ mkdir + [user@jumphost]$ cd + [user@jumphost]$ git clone https://git.opnfv.org/functest + [user@jumphost]$ cd testcases/ + +Modify and adapt needed parameters in the config_functest.yaml. Follow the instructions below. + +Retrieve OpenStack source file (configure your `OpenRC`_ file to let Rally access to your OpenStack, you can either export it from Horizon or build it manually (OpenStack credentials are required):: + + [user@jumphost]$ source Your_OpenRC_file + [user@jumphost]$ python /config_functest.py -d start At the end of the git clone, the tree of will have the following structure:: -- cgit 1.2.3-korg From 7cb7f4786b5f2cd246c05940ab4831be32152cb1 Mon Sep 17 00:00:00 2001 From: "jose.lausuch" Date: Thu, 18 Jun 2015 11:27:49 +0200 Subject: Doc: Fixed weird chars for the tree directory structure JIRA: FUNCTEST-9 Change-Id: Ic265ceaba44f956a797fe222977f215857c2fa49 Signed-off-by: jose.lausuch --- docs/functest.rst | 107 +++++++++++++++++++++++++++--------------------------- 1 file changed, 54 insertions(+), 53 deletions(-) (limited to 'docs') diff --git a/docs/functest.rst b/docs/functest.rst index 4276594e6..3e2d4f1a3 100644 --- a/docs/functest.rst +++ b/docs/functest.rst @@ -314,59 +314,60 @@ Retrieve OpenStack source file (configure your `OpenRC`_ file to let Rally acces At the end of the git clone, the tree of will have the following structure:: - ├── docs - │ ├── functest.rst - │ └── images - │ └── Ims_overview.png - ├── INFO - ├── LICENSE - └── testcases - ├── config_functest.py - ├── config_functest.yaml - ├── Controllers - │ └── ODL - │ ├── CI - │ │ ├── create_venv.sh - │ │ ├── custom_tests - │ │ │ └── neutron - │ │ ├── integration - │ │ │ ├── distributions - │ │ │ ├── features - │ │ │ ├── feature-selector - │ │ │ ├── packaging - │ │ │ ├── pom.xml - │ │ │ ├── test - │ │ │ └── vm - │ │ ├── logs - │ │ ├── requirements.pip - │ │ ├── start_tests.sh - │ │ └── test_list.txt - │ └── ODL.md - ├── functest_utils.py - ├── VIM - │ └── OpenStack - │ ├── CI - │ │ ├── libraries - │ │ │ └── run_rally.py - │ │ └── suites - │ │ ├── opnfv-authenticate.json - │ │ ├── opnfv-cinder.json - │ │ ├── opnfv-glance.json - │ │ ├── opnfv-heat.json - │ │ ├── opnfv-keystone.json - │ │ ├── opnfv-neutron.json - │ │ ├── opnfv-nova.json - │ │ ├── opnfv-quotas.json - │ │ ├── opnfv-requests.json - │ │ ├── opnfv-smoke-green.json - │ │ ├── opnfv-smoke.json - │ │ ├── opnfv-tempest.json - │ │ └── opnfv-vm.json - │ └── OpenStack.md - └── vPing - └── CI - └── libraries - └── vPing.py + |-- docs/ + | |-- functest.rst + | |-- images + | |-- Ims_overview.png + |-- INFO + |-- LICENSE + |-- testcases/ + |-- config_functest.py + |-- config_functest.yaml + |-- functest_utils.py + |-- Controllers/ + | |-- ODL/ + | |-- CI/ + | | |-- create_venv.sh + | | |-- custom_tests/ + | | | |-- neutron + | | |-- integration/ + | | | |-- distributions + | | | |-- features + | | | |-- feature-selector + | | | |-- packaging + | | | |-- pom.xml + | | | |-- test + | | | |-- vm + | | |-- logs + | | |-- requirements.pip + | | |-- start_tests.sh + | | |-- test_list.txt + | |-- ODL.md + |-- functest_utils.py + |-- VIM/ + | |-- OpenStack/ + | |-- CI/ + | | |-- libraries/ + | | | |-- run_rally.py + | | |-- suites/ + | | |-- opnfv-authenticate.json + | | |-- opnfv-cinder.json + | | |-- opnfv-glance.json + | | |-- opnfv-heat.json + | | |-- opnfv-keystone.json + | | |-- opnfv-neutron.json + | | |-- opnfv-nova.json + | | |-- opnfv-quotas.json + | | |-- opnfv-requests.json + | | |-- opnfv-smoke-green.json + | | |-- opnfv-smoke.json + | | |-- opnfv-tempest.json + | | |-- opnfv-vm.json + | |-- OpenStack.md + |-- vPing/ + |-- CI/ + |-- libraries/ + |-- vPing.py NOTE: the Rally environment will be installed under ~/.rally/ the default Tempest configuration (automatically generated by Rally based on OpenStack credentials) can be found under .rally/tempest/for-deployment-/tempest.conf -- cgit 1.2.3-korg From 840de73d294e7dccbf2ddb61816479e1b8ccf44a Mon Sep 17 00:00:00 2001 From: "jose.lausuch" Date: Tue, 30 Jun 2015 12:27:27 +0200 Subject: Doc: added required libraries and python modules JIRA: FUNCTEST-9 Change-Id: Ie86cdb9883a875ac3fd44708abe8ce3453def8c5 Signed-off-by: jose.lausuch --- docs/functest.rst | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) (limited to 'docs') diff --git a/docs/functest.rst b/docs/functest.rst index 3e2d4f1a3..3db860f51 100644 --- a/docs/functest.rst +++ b/docs/functest.rst @@ -76,6 +76,22 @@ For release 1, the tools are automatically installed, but the tests are not full .. _pharos: https://wiki.opnfv.org/pharos It is recommended to install the different tools on the jump host server as defined in the pharos_ project. + +For functest, the following libraries are needed. You can install them either with yum install or apt-get install, depending on your operating system: + * python-pip + * python-dev + * libffi-dev + * libxml2-dev + * libxslt1-dev + +You will also need some Python modules: + * sudo pip install GitPython + * sudo pip install python-novaclient + * sudo pip install python-neutronclient + * sudo pip install python-glanceclient + * sudo pip install python-keystoneclient + + The high level architecture can be described as follow:: CIMC/Lights+out management Admin Private Public Storage @@ -292,7 +308,7 @@ This script will: When integrated in CI, the only prerequisite consists in retrieving the OpenStack credentials (rc file). -This file shall be saved on the jumphost. It must be sourced by the user (who shall have sudo rights) executing the tests. +This file shall be saved on the jumphost. It must be sourced by the user (who shall have sudo rights) executing the tests. For the Continuous Integration we store this file under $HOME/functest/opnfv-openrc.sh on the jumphost server so CI can automatically execute the suite of tests @@ -538,7 +554,7 @@ OpenDaylight .. _`functest wiki (ODL section)`: https://wiki.opnfv.org/r1_odl_suite -The results of ODL tests can be seen in the console:: +The results of ODL tests can be seen in the console:: ============================================================================== Basic -- cgit 1.2.3-korg From 43a2d7196fe39effd479464f9ec6b0e9289f8639 Mon Sep 17 00:00:00 2001 From: Morgan Richomme Date: Wed, 23 Sep 2015 16:16:52 +0200 Subject: Minor corrections for SR1 JIRA: FUNCTEST-51 Change-Id: I796bf9fb87945b2777f2e9d902a89c184414d299 Signed-off-by: Morgan Richomme --- docs/functest.rst | 75 ++++++++++++++++++++++++++++++++++++------------------- 1 file changed, 49 insertions(+), 26 deletions(-) (limited to 'docs') diff --git a/docs/functest.rst b/docs/functest.rst index 3db860f51..ed436f586 100644 --- a/docs/functest.rst +++ b/docs/functest.rst @@ -71,7 +71,10 @@ In the rest of the document the OPNFV solution would be considered as the System The installation and configuration of the tools needed to perform the tests will be described in the following sections. -For release 1, the tools are automatically installed, but the tests are not fully automated due to the requirement that sourcing of OpenStack credentials is required on at least one machine where tests are launched. More details will be provided in the configuration section. +For Arno SR1, the tools are automatically installed. Manual sourcing of OpenStack credentials is no more required if you are fully integrated in the continuous integration. +A script has been added to automatically retrieve the credentials. +However, if you still install manually functest, you will need to source the rc file on the machine you are running the tests. +More details will be provided in the configuration section. .. _pharos: https://wiki.opnfv.org/pharos @@ -114,7 +117,7 @@ The high level architecture can be described as follow:: | | | | | | | | | | | | Tempest | | | | | | | | +----------+ | | | | | - | | FuncTests +-----------------------------------------+ | + | | FuncTest +-----------------------------------------+ | | | | | | | | | | +--------------------------------------------------+ | | | | | | | @@ -177,6 +180,8 @@ The goal of this test can be described as follow:: This example, using OpenStack Python clients can be considered as an "Hello World" example and may be modified for future use. +In SR1, some code has been added in order to push the results (status and duration) into a centralized test result database. + OpenDaylight ============ @@ -272,6 +277,8 @@ The goal of this test is to to check the basic OpenStack functionality on a fre Tooling installation ---------------------- +.. _fetch_os_creds.sh: https://git.opnfv.org/cgit/releng/tree/utils/fetch_os_creds.sh + 2 external tools are needed for the functional tests on Arno: * Rally * Robot @@ -307,7 +314,8 @@ This script will: * Create Glance images -When integrated in CI, the only prerequisite consists in retrieving the OpenStack credentials (rc file). +When integrated in CI, there are no additional prerequisites. +When running functest manually, the only prerequisite consists in retrieving the OpenStack credentials (rc file). This file shall be saved on the jumphost. It must be sourced by the user (who shall have sudo rights) executing the tests. For the Continuous Integration we store this file under $HOME/functest/opnfv-openrc.sh on the jumphost server so CI can automatically execute the suite of tests @@ -328,6 +336,21 @@ Retrieve OpenStack source file (configure your `OpenRC`_ file to let Rally acces [user@jumphost]$ source Your_OpenRC_file [user@jumphost]$ python /config_functest.py -d start +In SR1, a script has been created: fetch_os_creds.sh_. This script retrieves automatically the credentials of your OpenStack solution. You may run it manually:: + + [user@jumphost]$ /home/jenkins-ci/functest/fetch_os_creds.sh -d -i -a + +with + * installer_type = fuel or foreman + * installer_ip the IP of your installer + * the destination shall be the full path including the file name. + +Examples:: + + [user@jumphost]$./fetch_os_creds.sh -d ./credentials -i foreman -a 172.30.10.73 + [user@jumphost]$./fetch_os_creds.sh -d ./credentials -i fuel -a 10.20.0.2 + + At the end of the git clone, the tree of will have the following structure:: |-- docs/ @@ -509,7 +532,7 @@ The script will: * run rally with the selected scenario * generate the html result page into //opnfv-[module name].html * generate the json result page into //opnfv-[module name].json - * generate OK or KO per test based on json result file + * generate OK or NOK per test based on json result file Tempest suite ============= @@ -535,19 +558,22 @@ vPing vPing result is displayed in the console:: Functest: run vPing - 2015-06-02 21:24:55,065 - vPing - INFO - Glance image found 'functest-img' - 2015-06-02 21:24:55,066 - vPing - INFO - Creating neutron network functest-net... - 2015-06-02 21:24:57,672 - vPing - INFO - Flavor found 'm1.small' - 2015-06-02 21:24:58,670 - vPing - INFO - Creating instance 'opnfv-vping-1' with IP 192.168.120.30... - 2015-06-02 21:25:32,098 - vPing - INFO - Instance 'opnfv-vping-1' is ACTIVE. - 2015-06-02 21:25:32,540 - vPing - INFO - Creating instance 'opnfv-vping-2' with IP 192.168.120.40... - 2015-06-02 21:25:38,614 - vPing - INFO - Instance 'opnfv-vping-2' is ACTIVE. - 2015-06-02 21:25:38,614 - vPing - INFO - Waiting for ping... - 2015-06-02 21:26:42,385 - vPing - INFO - vPing detected! - 2015-06-02 21:26:42,385 - vPing - INFO - Cleaning up... - 2015-06-02 21:26:54,127 - vPing - INFO - Deleting network 'functest-net'... - 2015-06-02 21:26:55,349 - vPing - INFO - vPing OK - + 2015-09-13 22:11:49,502 - vPing- INFO - Glance image found 'functest-img' + 2015-09-13 22:11:49,502 - vPing- INFO - Creating neutron network functest-net... + 2015-09-13 22:11:50,275 - vPing- INFO - Flavor found 'm1.small' + 2015-09-13 22:11:50,318 - vPing- INFO - vPing Start Time:'2015-09-13 22:11:50' + 2015-09-13 22:11:50,470 - vPing- INFO - Creating instance 'opnfv-vping-1' with IP 192.168.120.30... + 2015-09-13 22:11:58,803 - vPing- INFO - Instance 'opnfv-vping-1' is ACTIVE. + 2015-09-13 22:11:58,981 - vPing- INFO - Creating instance 'opnfv-vping-2' with IP 192.168.120.40... + 2015-09-13 22:12:09,169 - vPing- INFO - Instance 'opnfv-vping-2' is ACTIVE. + 2015-09-13 22:12:09,169 - vPing- INFO - Waiting for ping... + 2015-09-13 22:13:11,329 - vPing- INFO - vPing detected! + 2015-09-13 22:13:11,329 - vPing- INFO - vPing duration:'81.0' + 2015-09-13 22:13:11,329 - vPing- INFO - Cleaning up... + 2015-09-13 22:13:18,727 - vPing- INFO - Deleting network 'functest-net'... + 015-09-13 22:13:19,470 - vPing- INFO - vPing OK + +A json file is produced and pushed into the test result database. OpenDaylight ============ @@ -652,11 +678,11 @@ You shall see the results as follow:: Total results of verification: - +--------------------------------------+--------------------------------------+----------+-------+----------+----------------------------+----------+ - | UUID | Deployment UUID | Set name | Tests | Failures | Created at | Status | - +--------------------------------------+--------------------------------------+----------+-------+----------+----------------------------+----------+ - | 0144c50f-ab03-45fb-9c36-242ad6440b46 | d9e1bb21-8e36-4d89-b137-0c852dbb308e | smoke | 87 | 32 | 2015-05-05 16:36:00.986003 | finished | - +--------------------------------------+--------------------------------------+----------+-------+----------+----------------------------+----------+ + +--------------------------------------+--------------------------------------+----------+-------+----------+----------------------------+----------------+----------+ + | UUID | Deployment UUID | Set name | Tests | Failures | Created at | Duration | Status | + +--------------------------------------+--------------------------------------+----------+-------+----------+----------------------------+----------------+----------+ + | 546c678a-19c4-4b2e-8f24-6f8c5ff20635 | 9c13dbbe-7a80-43db-8d6c-c4a61f257c7f | smoke | 111 | 15 | 2015-09-14 06:18:54.896224 | 0:00:51.804504 | finished | + +--------------------------------------+--------------------------------------+----------+-------+----------+----------------------------+----------------+----------+ If you run this test several times, you will see as many lines as test attempts. @@ -692,13 +718,10 @@ Known issues .. _`functest wiki (Tempest section)`: https://wiki.opnfv.org/r1_tempest .. _`ODL bug lists`: https://bugs.opendaylight.org/buglist.cgi?component=General&product=neutron&resolution=--- -Several tests are declared as failed. They can be divided in 3 main categories: - * Invalid credentials (10 errors) +Several tests are declared as failed. They can be divided in 2 main categories: * Multiple possible networks found, use a Network ID to be more specific. * Network errors -The "Invalid Credential" error is not an error. Adding "admin_domain_name=default" in the tempest.conf file generated by Rally will lead to successful tests. A `Rally patch`_ has been proposed to Rally community. - The Multiple possible netwok error occurs several times and may have different origins. It indicates that the test needs a network context to be run properly. A change in the `automatically generated tempest.conf`_ file could allow to precise the network ID. The network errors are various and dealing with all the aspects of networking: create/update/delete network/subnet/port/router. Some may be due to (possible) bug in tempest when it tries to delete networks which should not be there for the following tests. Some may be caused by the ODL bugs, several bugs related to tempest are already reported in `ODL bug lists`_. -- cgit 1.2.3-korg