Tempest: Format vmware_nsx_tempest README

Format vmware_nsx_tempest README.rst to make it looks better.

Change-Id: I00f07a412ca3c23457034557aa17757184eb37ef
This commit is contained in:
Tong Liu 2016-05-13 00:21:42 +00:00
parent 35c8ce3eee
commit 40a1c37919

View File

@ -2,12 +2,12 @@ Welcome!
======== ========
vmware_nsx_tempest is a plugin module to openstack tempest project. vmware_nsx_tempest is a plugin module to openstack tempest project.
If you are not familiar with tempest, please refer to: If you are not familiar with tempest, please refer to::
http://docs.openstack.org/developer/tempest http://docs.openstack.org/developer/tempest
It is implemented with tempest external plugin. It is implemented with tempest external plugin.
The official design sepcification is at: The official design sepcification is at::
https://review.openstack.org/#/c/184992/ https://review.openstack.org/#/c/184992/
@ -26,48 +26,57 @@ editable vmware-nsx repo under tempest VENV environemnt.
Installation: Installation:
------------- -------------
On your own development folder, for example /opt/devtest/: #. On your own development folder, for example /opt/devtest/,
install your own tempest development env at /opt/devtest/os-tempest/::
# install your own tempest development env at /opt/devtest/os-tempest/ $ cd /opt/devtest
cd /opt/devtest $ git clone https://github.com/openstack/tempest os-tempest
git clone https://github.com/openstack/tempest os-tempest
cd os-tempest
python tools/install_venv.py
# install vmware-nsx master branch at /opt/devtest/vmware-nsx #. Install virtualenv with the following command::
cd /opt/devtest
git clone https://github.com/openstack/vmware-nsx
Install vmware_nsx_tempest to your tempest development environment: $ cd /opt/devtest/os-tempest
$ ./run_tempest.sh -u not_exist_tests
cd /opt/devtest/os-tempest #. Install vmware-nsx master branch at /opt/devtest/vmware-nsx::
source .venv/bin/activate
pip install -e /opt/devtest/vmware-nsx/
run command: $ cd /opt/devtest
pip show vmware-nsx $ git clone https://github.com/openstack/vmware-nsx
and you should observe the following statements:
Location: /opt/devtest/vmware-nsx
and under section of Entry-points:
[tempest.test_plugins]
vmware-nsx-tempest-plugin = vmware_nsx_tempest.plugin:VMwareNsxTempestPlugin
Validate installed vmware_nsx_tempest succesfully do: #. Install vmware_nsx_tempest in your tempest development environment::
cd /opt/devtest/os-tempest $ cd /opt/devtest/os-tempest
tools/with_venv.sh testr list-tests vmware_nsx_tempest.*l2_gateway $ source .venv/bin/activate
$ pip install -e /opt/devtest/vmware-nsx/
Your installation failed, if no tests are shown. Run command::
$ pip show vmware-nsx
You should observe the following statements::
Location: /opt/devtest/vmware-nsx
and under section of Entry-points::
[tempest.test_plugins]
vmware-nsx-tempest-plugin = vmware_nsx_tempest.plugin:VMwareNsxTempestPlugin
#. Validate installed vmware_nsx_tempest succesfully do::
$ cd /opt/devtest/os-tempest
$ tools/with_venv.sh testr list-tests vmware_nsx_tempest.*l2_gateway
Your installation failed, if no tests are shown.
Execution: Execution:
---------- ----------
vmware_nsx_tempest tests are tempest tests, you need to vmware_nsx_tempest tests are tempest tests, you need to
run from tempest directory. For example, to run only l2-gateway tests: run from tempest directory. For example, to run only l2-gateway tests::
cd /opt/devtest/os-tempest $ cd /opt/devtest/os-tempest
./run_tempest.sh -t vmware_nsx_tempest.*test_l2_gateway $ ./run_tempest.sh -t vmware_nsx_tempest.*test_l2_gateway
./run_tempest.sh -d vmware_nsx_tempest.tests.nsxv.api.test_l2_gateway_connection.L2GatewayConnectionTest.test_csuld_single_device_interface_vlan $ ./run_tempest.sh -d vmware_nsx_tempest.tests.nsxv.api.test_l2_gateway_connection.L2GatewayConnectionTest.test_csuld_single_device_interface_vlan
TechNote on vmware_nsx_tempest: TechNote on vmware_nsx_tempest:
------------------------------- -------------------------------
@ -78,7 +87,7 @@ It is defined by tempest.test_plugins.
Modules within vmware_nsx_tempest can not see resources defined Modules within vmware_nsx_tempest can not see resources defined
by vmware_nsx. Commands like following are not acceptable, unless by vmware_nsx. Commands like following are not acceptable, unless
vmware_nsx is installed in your tempest environment. vmware_nsx is installed in your tempest environment::
from vmware_nsx._i18n import _LE from vmware_nsx._i18n import _LE
import vmware_nsx.shell.admin.plugins.common.utils as admin_utils import vmware_nsx.shell.admin.plugins.common.utils as admin_utils
@ -89,7 +98,7 @@ tempest repo itself does not enforce LOG complying to _i18n.
So for tempest tests for vmware-nsx, that is vmware_nsx_tempest, So for tempest tests for vmware-nsx, that is vmware_nsx_tempest,
use LOG.debug() command. use LOG.debug() command.
However, if you need to log other than debug level, please do: However, if you need to log other than debug level, please do::
from vmware_nsx_tempest._i18n import _LI from vmware_nsx_tempest._i18n import _LI
from vmware_nsx_tempest._i18n import _LE from vmware_nsx_tempest._i18n import _LE