doc: Added an initial Sphinx documentation

I have added a auto-generated documentation. It is done with
Sphinx library. Sphinx uses reStructuredText as its markup language
and docstrings as a source for automated documentation.

According to https://www.python.org/dev/peps/pep-0257/
I used a """ for quotes in docstrings and made
"""Docstring."""-looking one-liners and correct indentation
for multiple-liners.
Based on https://github.com/kennethreitz/requests
I moved Makefile, requirements.txt and conf.py to /doc folder.
Also I decided to make fuel-qa documentation
similar to https://docs.python.org/2/tutorial/index.html
with single table of contents.
I have added empty __init__.py files to be able to produce
documentation.
I have added sys_test.log to .gitigonre because it has
been generated at the documentation build.

To make it faster and non-conflicting I added some banal
class descriptions in order to get them in auto-generated documentation.
I decided not to fight with warnings and poor docstring descriptions
I added to make documentation less conflicting and for a faster review.
Docstring improvements and detailed code description are left for later.
For the same reasons I decied not to add docstrings to all methods.
At a places where I made poor docstrings I have added a
TODO documentation.

Change-Id: I7701a9a3429abbf62b13ec5a31972298c0be5201
Related-Bug: #1321682
This commit is contained in:
Alexandr Kostrikov 2015-04-29 13:25:17 +03:00
parent 77253c17f9
commit e317c2d6d2
69 changed files with 676 additions and 8 deletions

8
.gitignore vendored
View File

@ -41,4 +41,10 @@ nosetests.xml
example_local.py
# Local settings
local_settings.py
local_settings.py
# Documentation
doc/_build/
# Logs
sys_test.log

View File

@ -3,6 +3,14 @@ Tests documentation
[Devops documentation](http://docs.mirantis.com/fuel-dev/devops.html)
Code-generated documentation
----------------------------
You need to run `make doc-html` to generate them.
Output is stored in `doc/_build/html/index.html`.
For 'make iso'
--------------

27
doc/Makefile Normal file
View File

@ -0,0 +1,27 @@
.PHONY: clean-doc doc-html
SPHINXBUILD = sphinx-build
DOC_BUILDDIR = _build
SPHINXOPTS = -d $(DOC_BUILDDIR)/doctrees .
help:
@echo 'Build directives (can be overridden by environment variables'
@echo 'or by command line parameters):'
@echo ' DOC_BUILDDIR: $(DOC_BUILDDIR)'
@echo
@echo 'Available targets:'
@echo ' doc-html - build html documentation based on source code of product'
@echo ' clean-doc - clean generated docs'
@echo
doc-html:
$(SPHINXBUILD) -b html $(SPHINXOPTS) $(DOC_BUILDDIR)/html
@echo
@echo "Build finished. The HTML pages are in $(DOC_BUILDDIR)/html."
clean-doc:
$ rm -rf $(DOC_BUILDDIR)
@echo
@echo "We are cleaned documentation output."

BIN
doc/_static/favicon.ico vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

207
doc/base_tests.rst Normal file
View File

@ -0,0 +1,207 @@
.. index:: Base tests
General Openstack/Fuel Tests
****************************
General tests
=============
Base Test Case
--------------
.. automodule:: fuelweb_test.tests.base_test_case
:members:
Admin Node Tests
----------------
.. automodule:: fuelweb_test.tests.test_admin_node
:members:
Test Bonding
------------
.. automodule:: fuelweb_test.tests.test_bonding
:members:
Test By Tempest
---------------
.. automodule:: fuelweb_test.tests.test_by_tempest
:members:
Test Ceph
---------
.. automodule:: fuelweb_test.tests.test_ceph
:members:
Test Cli
--------
.. automodule:: fuelweb_test.tests.test_cli
:members:
Test Environment Action
-----------------------
.. automodule:: fuelweb_test.tests.test_environment_action
:members:
Test High Availability
----------------------
.. automodule:: fuelweb_test.tests.test_ha
:members:
Test High Availability on one controller
----------------------------------------
.. automodule:: fuelweb_test.tests.test_ha_one_controller
:members:
Test Multiple Networks
----------------------
.. automodule:: fuelweb_test.tests.test_multiple_networks
:members:
Test Neutron
------------
.. automodule:: fuelweb_test.tests.test_neutron
:members:
Test Pull Requests
------------------
.. automodule:: fuelweb_test.tests.test_pullrequest
:members:
Test Services
-------------
.. automodule:: fuelweb_test.tests.test_services
:members:
Test Upgrade
------------
.. automodule:: fuelweb_test.tests.test_upgrade
:members:
Test Vcenter
------------
.. automodule:: fuelweb_test.tests.test_vcenter
:members:
Test Zabbix
-----------
.. automodule:: fuelweb_test.tests.test_zabbix
:members:
GD based tests
==============
Test Neutron
------------
.. automodule:: fuelweb_test.tests.gd_based_tests.test_neutron
:members:
Test Neutron Vlan Ceph Mongo
----------------------------
.. automodule:: fuelweb_test.tests.gd_based_tests.test_neutron
:members:
Plugins tests
=============
Example tests
-------------
.. automodule:: fuelweb_test.tests.plugins.plugin_example.test_fuel_plugin_example
:members:
Contrail tests
--------------
.. automodule:: fuelweb_test.tests.plugins.plugin_contrail.test_fuel_plugin_contrail
:members:
Emc tests
---------
.. automodule:: fuelweb_test.tests.plugins.plugin_emc.test_plugin_emc
:members:
Glusterfs tests
---------------
.. automodule:: fuelweb_test.tests.plugins.plugin_glusterfs.test_plugin_glusterfs
:members:
Lbaas tests
-----------
.. automodule:: fuelweb_test.tests.plugins.plugin_lbaas.test_plugin_lbaas
:members:
Reboot tests
------------
.. automodule:: fuelweb_test.tests.plugins.plugin_reboot.test_plugin_reboot_task
:members:
Zabbix tests
------------
.. automodule:: fuelweb_test.tests.plugins.plugin_zabbix.test_plugin_zabbix
:members:
Openstack patching tests
========================
Openstack patching tests
------------------------
.. automodule:: fuelweb_test.tests.tests_os_patching.test_os_patching
:members:
Patching tests
==============
Patching tests
--------------
.. automodule:: fuelweb_test.tests.tests_patching.test_patching
:members:
Strength tests
==============
Cic maintenance mode tests
--------------------------
.. automodule:: fuelweb_test.tests.tests_strength.test_cic_maintenance_mode
:members:
Failover tests
--------------
.. automodule:: fuelweb_test.tests.tests_strength.test_failover
:members:
Base failover tests
-------------------
.. automodule:: fuelweb_test.tests.tests_strength.test_failover_base
:members:
Huge environments tests
-----------------------
.. automodule:: fuelweb_test.tests.tests_strength.test_huge_environments
:members:
Image based tests
-----------------
.. automodule:: fuelweb_test.tests.tests_strength.test_image_based
:members:
Master node failover tests
--------------------------
.. automodule:: fuelweb_test.tests.tests_strength.test_master_node_failover
:members:
Neutron tests
-------------
.. automodule:: fuelweb_test.tests.tests_strength.test_neutron
:members:
OSTF repeatable tests
---------------------
.. automodule:: fuelweb_test.tests.tests_strength.test_ostf_repeatable_tests
:members:
Restart tests
-------------
.. automodule:: fuelweb_test.tests.tests_strength.test_restart
:members:

53
doc/conf.py Normal file
View File

@ -0,0 +1,53 @@
# -*- coding: utf-8 -*-
# Copyright 2015 Mirantis, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import os
import sys
sys.path.insert(0,
os.path.abspath(os.path.join(os.path.dirname(__file__), '..')))
extensions = [
'sphinx.ext.autodoc',
'sphinx.ext.doctest',
'sphinx.ext.intersphinx',
'sphinx.ext.todo',
'sphinx.ext.viewcode',
]
autodoc_default_flags = ['members', 'show-inheritance', 'inherited-members']
autodoc_member_order = 'bysource'
source_suffix = '.rst'
master_doc = 'index'
project = 'Fuel QA'
copyright = 'Copyright 2015 Mirantis, Inc.' \
'Licensed under the Apache License, Version 2.0' \
' (the "License"); you may not use this file except in' \
' compliance with the License. You may obtain a copy' \
' of the License at http://www.apache.org/licenses/LICENSE-2.0'
exclude_patterns = ['_build']
pygments_style = 'sphinx'
html_theme = 'classic'
html_static_path = ['_static']
htmlhelp_basename = 'fuel-qadoc'
html_favicon = '_static/favicon.ico'
intersphinx_mapping = {'http://docs.python.org/': None}

87
doc/helpers.rst Normal file
View File

@ -0,0 +1,87 @@
.. index:: Helpers
Helpers
=======
Checkers
--------
.. automodule:: fuelweb_test.helpers.checkers
:members:
Common
------
.. automodule:: fuelweb_test.helpers.common
:members:
Conf tempest
------------
.. automodule:: fuelweb_test.helpers.conf_tempest
:members:
Decorators
----------
.. automodule:: fuelweb_test.helpers.decorators
:members:
Eb tables
---------
.. automodule:: fuelweb_test.helpers.eb_tables
:members:
Fuel Actions
------------
.. automodule:: fuelweb_test.helpers.fuel_actions
:members:
Granular Deployment Checkers
----------------------------
.. automodule:: fuelweb_test.helpers.granular_deployment_checkers
:members:
Http
----
.. automodule:: fuelweb_test.helpers.http
:members:
Log Server
----------
.. automodule:: fuelweb_test.helpers.log_server
:members:
Multiple Networks Hacks
-----------------------
.. automodule:: fuelweb_test.helpers.multiple_networks_hacks
:members:
Ntp
---
.. automodule:: fuelweb_test.helpers.ntp
:members:
Os Actions
----------
.. automodule:: fuelweb_test.helpers.os_actions
:members:
Patching
--------
.. automodule:: fuelweb_test.helpers.patching
:members:
Regenerate Repo
---------------
.. automodule:: fuelweb_test.helpers.regenerate_repo
:members:
Security
--------
.. automodule:: fuelweb_test.helpers.security
:members:
Utils
-----
.. automodule:: fuelweb_test.helpers.utils
:members:

13
doc/index.rst Normal file
View File

@ -0,0 +1,13 @@
Documentation for the QA test code repo
***************************************
.. toctree::
:numbered:
:maxdepth: 3
models.rst
helpers.rst
base_tests.rst
puppet_tests.rst
testrail.rst

29
doc/models.rst Normal file
View File

@ -0,0 +1,29 @@
.. index:: Models
Models
======
Fuel Web Client
---------------
.. automodule:: fuelweb_test.models.fuel_web_client
:members:
Environment
-----------
.. automodule:: fuelweb_test.models.environment
:members:
Fuel Web Client
---------------
.. automodule:: fuelweb_test.models.fuel_web_client
:members:
Nailgun Client
--------------
.. automodule:: fuelweb_test.models.nailgun_client
:members:
Puppet Environment
------------------
.. automodule:: fuelweb_test.models.pp_environment
:members:

19
doc/puppet_tests.rst Normal file
View File

@ -0,0 +1,19 @@
.. index:: Puppet tests
Puppet tests
============
Puppet test generator
---------------------
.. automodule:: fuelweb_test.puppet_tests.pp_testgenerator
:members:
Puppet module
-------------
.. automodule:: fuelweb_test.puppet_tests.puppet_module
:members:
Puppet test
-----------
.. automodule:: fuelweb_test.puppet_tests.puppet_test
:members:

1
doc/requirements.txt Normal file
View File

@ -0,0 +1 @@
sphinx==1.3.1

49
doc/testrail.rst Normal file
View File

@ -0,0 +1,49 @@
.. index:: Testrail
Testrail
========
Builds
------
.. automodule:: fuelweb_test.testrail.builds
:members:
Launchpad client
----------------
.. automodule:: fuelweb_test.testrail.launchpad_client
:members:
Report
------
.. automodule:: fuelweb_test.testrail.report
:members:
Report tempest results
----------------------
.. automodule:: fuelweb_test.testrail.report_tempest_results
:members:
Settings
--------
.. automodule:: fuelweb_test.testrail.settings
:members:
Testrail
--------
.. automodule:: fuelweb_test.testrail.testrail
:members:
Testrail Client
---------------
.. automodule:: fuelweb_test.testrail.testrail_client
:members:
Upload Cases Description
------------------------
.. automodule:: fuelweb_test.testrail.upload_cases_description
:members:
Upload tempest test suite
-------------------------
.. automodule:: fuelweb_test.testrail.upload_tempest_test_suite
:members:

View File

@ -27,6 +27,7 @@ from proboscis.asserts import assert_equal
class Common(object):
"""Common.""" # TODO documentation
def __init__(self, controller_ip, user, password, tenant):
self.controller_ip = controller_ip

View File

@ -23,6 +23,7 @@ from fuelweb_test.helpers import os_actions
class TempestConfigState(object):
"""TempestConfigState.""" # TODO documentation
default_options = {'username': 'test',
'password': 'test',

View File

@ -18,6 +18,8 @@ from fuelweb_test import logwrap
class Ebtables(object):
"""Ebtables.""" # TODO documentation
def __init__(self, target_devs, vlans):
super(Ebtables, self).__init__()
self.target_devs = target_devs

View File

@ -31,6 +31,8 @@ from fuelweb_test.settings import FUEL_USE_LOCAL_NTPD
class BaseActions(object):
"""BaseActions.""" # TODO documentation
def __init__(self, admin_remote):
self.admin_remote = admin_remote
self.container = None
@ -162,6 +164,8 @@ class AdminActions(BaseActions):
class NailgunActions(BaseActions):
"""NailgunActions.""" # TODO documentation
def __init__(self, admin_remote):
super(NailgunActions, self).__init__(admin_remote)
self.container = 'nailgun'
@ -224,6 +228,8 @@ class NailgunActions(BaseActions):
class PostgresActions(BaseActions):
"""PostgresActions.""" # TODO documentation
def __init__(self, admin_remote):
super(PostgresActions, self).__init__(admin_remote)
self.container = 'postgres'
@ -379,6 +385,8 @@ class FuelPluginBuilder(object):
class CobblerActions(BaseActions):
"""CobblerActions.""" # TODO documentation
def __init__(self, admin_remote):
super(CobblerActions, self).__init__(admin_remote)
self.container = 'cobbler'
@ -396,6 +404,8 @@ class CobblerActions(BaseActions):
class DockerActions(object):
"""DockerActions.""" # TODO documentation
def __init__(self, admin_remote):
self.admin_remote = admin_remote

View File

@ -22,6 +22,7 @@ from fuelweb_test import logger
class HTTPClient(object):
"""HTTPClient.""" # TODO documentation
def __init__(self, url, keystone_url, credentials, **kwargs):
logger.info('Initiate HTTPClient with url %s', url)
@ -110,6 +111,8 @@ class HTTPClient(object):
class HTTPClientZabbix(object):
"""HTTPClientZabbix.""" # TODO documentation
def __init__(self, url):
self.url = url
self.opener = urllib2.build_opener(urllib2.HTTPHandler)

View File

@ -20,6 +20,8 @@ from fuelweb_test import logwrap
class LogServer(threading.Thread):
"""LogServer.""" # TODO documentation
@logwrap
def __init__(self, address="localhost", port=5514):
super(LogServer, self).__init__()
@ -69,6 +71,8 @@ class LogServer(threading.Thread):
class TriggeredLogServer(LogServer):
"""TriggeredLogServer.""" # TODO documentation
def __init__(self, address="localhost", port=5514):
super(TriggeredLogServer, self).__init__(address, port)
self.set_handler(self.handler)

View File

@ -23,7 +23,8 @@ from fuelweb_test import logwrap
class GroupNtpSync(object):
""" Synchronize a group of nodes """
"""Synchronize a group of nodes."""
ntps = []
def __init__(self, env=None, nailgun_nodes=[]):
@ -81,7 +82,7 @@ class GroupNtpSync(object):
class Ntp(object):
""" Common methods to work with ntpd service """
"""Common methods to work with ntpd service."""
@staticmethod
@logwrap
@ -173,6 +174,7 @@ class Ntp(object):
class NtpInitscript(Ntp):
"""NtpInitscript.""" # TODO documentation
@logwrap
def start(self):
@ -190,6 +192,7 @@ class NtpInitscript(Ntp):
class NtpPacemaker(Ntp):
"""NtpPacemaker.""" # TODO documentation
@logwrap
def start(self):

View File

@ -25,6 +25,8 @@ from fuelweb_test.helpers.decorators import retry
class OpenStackActions(common.Common):
"""OpenStackActions.""" # TODO documentation
def __init__(self, controller_ip, user='admin',
passwd='admin', tenant='admin'):
super(OpenStackActions, self).__init__(controller_ip,

View File

@ -80,8 +80,8 @@ def map_test(target):
if not target == errata['target']:
skip_patching_test(target, errata['target'])
if target == 'master':
# On master node we have only CentOS containers, so always check
# only CentOS packages available for update
# On master node we have only CentOS containers, so always check
# only CentOS packages available for update
distro = settings.OPENSTACK_RELEASE_CENTOS
else:
distro = settings.OPENSTACK_RELEASE

View File

@ -41,6 +41,7 @@ def regenerate_centos_repo(remote, path):
class CustomRepo(object):
"""CustomRepo.""" # TODO documentation
def __init__(self, remote):
self.remote = remote

View File

@ -23,6 +23,7 @@ from fuelweb_test.settings import OPENSTACK_RELEASE_UBUNTU
class SecurityChecks(object):
"""SecurityChecks.""" # TODO documentation
def __init__(self, nailgun_client, environment):
self.client = nailgun_client

View File

@ -18,6 +18,8 @@ from fuelweb_test.helpers.http import HTTPClientZabbix
class CollectorClient(object):
"""CollectorClient.""" # TODO documentation
def __init__(self, collector_ip, endpoint):
url = "http://{0}/{1}".format(collector_ip, endpoint)
self._client = HTTPClientZabbix(url=url)

View File

@ -46,6 +46,8 @@ from fuelweb_test import logger
class EnvironmentModel(object):
"""EnvironmentModel.""" # TODO documentation
def __init__(self):
self._virtual_environment = None
self.fuel_web = FuelWebClient(self.get_admin_node_ip(), self)

View File

@ -59,6 +59,7 @@ import fuelweb_test.settings as help_data
class FuelWebClient(object):
"""FuelWebClient.""" # TODO documentation
def __init__(self, admin_node_ip, environment):
self.admin_node_ip = admin_node_ip

View File

@ -21,6 +21,8 @@ from fuelweb_test.settings import OPENSTACK_RELEASE
class NailgunClient(object):
"""NailgunClient""" # TODO documentation
def __init__(self, admin_node_ip, **kwargs):
url = "http://{0}:8000".format(admin_node_ip)
logger.info('Initiate Nailgun client with url %s', url)

View File

@ -22,6 +22,7 @@ from fuelweb_test import settings
class PuppetEnvironment(EnvironmentModel):
"""Create environment for puppet modules testing."""
def __init__(self, os_image=None):
"""Constructor for create environment."""
self.os_image = os_image or settings.OS_IMAGE

View File

@ -0,0 +1,13 @@
# Copyright 2015 Mirantis, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.

View File

@ -16,6 +16,8 @@ from launchpadlib.launchpad import Launchpad
class LaunchpadBug(object):
"""LaunchpadBug.""" # TODO documentation
def __init__(self, bug_id):
self.launchpad = Launchpad.login_anonymously('just testing',
'production',

View File

@ -34,6 +34,8 @@ from testrail_client import TestRailProject
class TestResult():
"""TestResult.""" # TODO documentation
def __init__(self, name, group, status, duration, url=None,
version=None, description=None, launchpad_bug=None):
self.name = name

View File

@ -31,6 +31,8 @@ JENKINS = {
class LaunchpadSettings(object):
"""LaunchpadSettings.""" # TODO documentation
project = os.environ.get('LAUNCHPAD_PROJECT', 'fuel')
milestone = os.environ.get('LAUNCHPAD_MILESTONE', '6.1')
closed_statuses = [
@ -40,6 +42,8 @@ class LaunchpadSettings(object):
class TestRailSettings(object):
"""TestRailSettings.""" # TODO documentation
url = os.environ.get('TESTRAIL_URL', 'https://mirantis.testrail.com')
user = os.environ.get('TESTRAIL_USER', 'user@example.com')
password = os.environ.get('TESTRAIL_PASSWORD', 'password')

View File

@ -29,6 +29,8 @@ import urllib2
class APIClient:
"""APIClient.""" # TODO documentation
def __init__(self, base_url):
self.user = ''
self.password = ''
@ -99,4 +101,5 @@ class APIClient:
class APIError(Exception):
"""APIError.""" # TODO documentation
pass

View File

@ -16,6 +16,8 @@ from testrail import APIClient
class TestRailProject():
"""TestRailProject.""" # TODO documentation
def __init__(self, url, user, password, project):
self.client = APIClient(base_url=url)
self.client.user = user

View File

@ -33,6 +33,8 @@ import time
@test(groups=["gd", "gd_deploy_neutron_gre"])
class NeutronGre(TestBasic):
"""NeutronGre.""" # TODO documentation
@classmethod
def get_pre_test(cls, tasks, task_name):
return [task['test_pre'] for task in tasks

View File

@ -32,6 +32,8 @@ import time
@test(groups=["gd", "gd_deploy_neutron_vlan_ceph_mongo"])
class NeutronVlanCephMongo(TestBasic):
"""NeutronVlanCephMongo.""" # TODO documentation
@classmethod
def get_pre_test(cls, tasks, task_name):
return [task['test_pre'] for task in tasks

View File

@ -33,6 +33,8 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["plugins"])
class ContrailPlugin(TestBasic):
"""ContrailPlugin.""" # TODO documentation
_pack_copy_path = '/var/www/nailgun/plugins/contrail-1.0'
_add_ub_packag = \
'/var/www/nailgun/plugins/contrail-1.0/' \

View File

@ -27,6 +27,8 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["plugins"])
class EMCPlugin(TestBasic):
"""EMCPlugin.""" # TODO documentation
@classmethod
def check_emc_cinder_config(cls, remote, path):
command = 'cat {0}'.format(path)

View File

@ -27,6 +27,7 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["fuel_plugins"])
class ExamplePlugin(TestBasic):
"""ExamplePlugin.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_ha_controller_neutron_example"])

View File

@ -30,6 +30,8 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["plugins"])
class GlusterfsPlugin(TestBasic):
"""GlusterfsPlugin.""" # TODO documentation
@classmethod
def check_glusterfs_conf(cls, remote, path, gfs_endpoint):
cmd = ' cat {0}'.format(path)

View File

@ -31,6 +31,8 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(enabled=False, groups=["plugins"])
class LbaasPlugin(TestBasic):
"""LbaasPlugin.""" # TODO documentation
@classmethod
def check_neutron_agents_statuses(cls, os_conn):
agents_list = os_conn.list_agents()

View File

@ -27,9 +27,8 @@ from fuelweb_test.helpers.fuel_actions import FuelPluginBuilder
@test(groups=["fuel_plugins"])
class RebootPlugin(TestBasic):
"""
Test class for testing reboot task in plugins
"""
"""Test class for testing reboot task in plugins."""
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_cluster_with_reboot_plugin"])
def deploy_cluster_with_reboot_plugin(self):

View File

@ -30,6 +30,7 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["plugins"])
class ZabbixPlugin(TestBasic):
"""ZabbixPlugin.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_zabbix_ha"])

View File

@ -31,6 +31,8 @@ from fuelweb_test import logger
@test(groups=["thread_1"])
class TestAdminNode(TestBasic):
"""TestAdminNode.""" # TODO documentation
@test(depends_on=[SetupEnvironment.setup_master],
groups=["test_cobbler_alive"])
@log_snapshot_on_error

View File

@ -26,6 +26,8 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["bonding_ha_one_controller", "bonding"])
class BondingHAOneController(TestBasic):
"""BondingHAOneController.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_bonding_active_backup"])
@log_snapshot_on_error
@ -207,6 +209,8 @@ class BondingHAOneController(TestBasic):
@test(groups=["bonding_ha", "bonding"])
class BondingHA(TestBasic):
"""Tests for HA bonding."""
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_bonding_ha_active_backup"])
@log_snapshot_on_error

View File

@ -147,6 +147,7 @@ def _prepare_and_run(*testr_args):
@test(groups=["tempest"])
class TestByTempest(base_test_case.TestBasic):
"""TestByTempest.""" # TODO documentation
def revert_snapshot(self):
""" Prepare snapshot specified in environment"""

View File

@ -34,6 +34,7 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["thread_1", "ceph"])
class CephCompact(TestBasic):
"""CephCompact.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["ceph_ha_one_controller_compact",
@ -90,6 +91,7 @@ class CephCompact(TestBasic):
@test(groups=["thread_3", "ceph"])
class CephCompactWithCinder(TestBasic):
"""CephCompactWithCinder.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_release],
groups=["ceph_ha_one_controller_with_cinder"])
@ -165,6 +167,7 @@ class CephCompactWithCinder(TestBasic):
@test(groups=["thread_3", "ceph", "classic_provisioning"])
class CephHA(TestBasic):
"""CephHA.""" # TODO documentation1
@test(depends_on=[SetupEnvironment.prepare_release],
groups=["ceph_ha"])
@ -358,6 +361,7 @@ class CephHA(TestBasic):
@test(groups=["thread_4", "ceph"])
class CephRadosGW(TestBasic):
"""CephRadosGW.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_release],
groups=["ceph_rados_gw", "bvt_2"])
@ -428,6 +432,7 @@ class CephRadosGW(TestBasic):
@test(groups=["thread_1", "ceph_migration"])
class VmBackedWithCephMigrationBasic(TestBasic):
"""VmBackedWithCephMigrationBasic.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["ceph_migration"])
@ -644,6 +649,7 @@ class VmBackedWithCephMigrationBasic(TestBasic):
@test(groups=["thread_1", "ceph_partitions"])
class CheckCephPartitionsAfterReboot(TestBasic):
"""CheckCephPartitionsAfterReboot.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["ceph_partitions"])

View File

@ -25,6 +25,7 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["command_line"])
class CommandLine(TestBasic):
"""CommandLine.""" # TODO documentation
@test(depends_on=[SetupEnvironment.setup_with_custom_manifests],
groups=["hiera_deploy"])

View File

@ -27,6 +27,7 @@ from fuelweb_test.tests import base_test_case
@test(groups=["cluster_actions"])
class EnvironmentAction(base_test_case.TestBasic):
"""EnvironmentAction.""" # TODO documentation
@test(depends_on=[base_test_case.SetupEnvironment.prepare_slaves_3],
groups=["smoke", "deploy_flat_stop_reset_on_deploying",
@ -219,6 +220,7 @@ class EnvironmentAction(base_test_case.TestBasic):
@test(groups=["cluster_actions"])
class EnvironmentActionOnHA(base_test_case.TestBasic):
"""EnvironmentActionOnHA.""" # TODO documentation
@test(depends_on=[base_test_case.SetupEnvironment.prepare_slaves_5],
groups=["smoke", "deploy_stop_reset_on_ha"])

View File

@ -30,6 +30,7 @@ from fuelweb_test import logger
@test(groups=["thread_3", "ha", "bvt_1"])
class TestHaVLAN(TestBasic):
"""TestHaVLAN.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_ha_vlan", "ha_nova_vlan"])
@ -120,6 +121,7 @@ class TestHaVLAN(TestBasic):
@test(groups=["thread_4", "ha"])
class TestHaFlat(TestBasic):
"""TestHaFlat.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_ha_flat", "ha_nova_flat"])
@ -257,6 +259,7 @@ class TestHaFlat(TestBasic):
@test(groups=["thread_4", "ha", "classic_provisioning"])
class TestHaFlatAddCompute(TestBasic):
"""TestHaFlatAddCompute.""" # TODO documentation
@test(depends_on_groups=['deploy_ha_flat'],
groups=["ha_flat_add_compute"])
@ -297,6 +300,7 @@ class TestHaFlatAddCompute(TestBasic):
@test(groups=["thread_4", "ha"])
class TestHaFlatScalability(TestBasic):
"""TestHaFlatScalability.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["ha_flat_scalability", "ha_nova_flat_scalability"])
@ -424,6 +428,7 @@ class TestHaFlatScalability(TestBasic):
@test(groups=["known_issues", "ha"])
class BackupRestoreHa(TestBasic):
"""BackupRestoreHa.""" # TODO documentation
@test(depends_on=[TestHaFlat.deploy_ha_flat],
groups=["known_issues", "backup_restore_ha_flat"])

View File

@ -35,6 +35,8 @@ from fuelweb_test.tests.test_ha_one_controller_base\
@test(groups=["thread_2"])
class OneNodeDeploy(TestBasic):
"""OneNodeDeploy.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_release],
groups=["deploy_one_node", 'master'])
@log_snapshot_on_error
@ -78,6 +80,8 @@ class OneNodeDeploy(TestBasic):
@test(groups=["thread_2"])
class HAOneControllerFlat(HAOneControllerFlatBase):
"""HAOneControllerFlat.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["smoke", "deploy_ha_one_controller_flat",
"ha_one_controller_nova_flat", "classic_provisioning",
@ -288,6 +292,8 @@ class HAOneControllerFlat(HAOneControllerFlatBase):
@test(groups=["thread_2"])
class HAOneControllerVlan(TestBasic):
"""HAOneControllerVlan.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_ha_one_controller_vlan",
"ha_one_controller_nova_vlan"])
@ -395,6 +401,8 @@ class HAOneControllerVlan(TestBasic):
@test(groups=["thread_2", "multirole"])
class MultiroleControllerCinder(TestBasic):
"""MultiroleControllerCinder.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_multirole_controller_cinder"])
@log_snapshot_on_error
@ -444,6 +452,8 @@ class MultiroleControllerCinder(TestBasic):
@test(groups=["thread_2", "multirole"])
class MultiroleComputeCinder(TestBasic):
"""MultiroleComputeCinder.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_multirole_compute_cinder"])
@log_snapshot_on_error
@ -487,6 +497,8 @@ class MultiroleComputeCinder(TestBasic):
@test(groups=["thread_2"])
class FloatingIPs(TestBasic):
"""FloatingIPs.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_floating_ips"])
@log_snapshot_on_error
@ -547,6 +559,8 @@ class FloatingIPs(TestBasic):
@test(groups=["ha_one_controller"])
class HAOneControllerCinder(TestBasic):
"""HAOneControllerCinder.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_ha_one_controller_cinder",
"ha_one_controller_nova_cinder"])
@ -601,6 +615,8 @@ class HAOneControllerCinder(TestBasic):
@test(groups=["thread_1"])
class NodeMultipleInterfaces(TestBasic):
"""NodeMultipleInterfaces.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_node_multiple_interfaces"])
@log_snapshot_on_error
@ -657,6 +673,8 @@ class NodeMultipleInterfaces(TestBasic):
@test(groups=["thread_1"])
class NodeDiskSizes(TestBasic):
"""NodeDiskSizes.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["check_nodes_notifications"])
@log_snapshot_on_error
@ -752,6 +770,8 @@ class NodeDiskSizes(TestBasic):
@test(groups=["thread_1"])
class MultinicBootstrap(TestBasic):
"""MultinicBootstrap.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_release],
groups=["multinic_bootstrap_booting"])
@log_snapshot_on_error
@ -789,6 +809,8 @@ class MultinicBootstrap(TestBasic):
@test(groups=["thread_2", "test"])
class DeleteEnvironment(TestBasic):
"""DeleteEnvironment.""" # TODO documentation
@test(depends_on=[HAOneControllerFlat.deploy_ha_one_controller_flat],
groups=["delete_environment"])
@log_snapshot_on_error
@ -824,6 +846,8 @@ class DeleteEnvironment(TestBasic):
@test(groups=["thread_1"])
class UntaggedNetworksNegative(TestBasic):
"""UntaggedNetworksNegative.""" # TODO documentation
@test(
depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["untagged_networks_negative"],
@ -887,6 +911,8 @@ class UntaggedNetworksNegative(TestBasic):
@test(groups=["known_issues"])
class BackupRestoreHAOneController(TestBasic):
"""BackupRestoreHAOneController""" # TODO documentation
@test(depends_on=[HAOneControllerFlat.deploy_ha_one_controller_flat],
groups=["ha_one_controller_backup_restore"])
@log_snapshot_on_error
@ -947,6 +973,8 @@ class BackupRestoreHAOneController(TestBasic):
@test(groups=["thread_non_func_1_usb"])
class HAOneControllerFlatUSB(HAOneControllerFlatBase):
"""HAOneControllerFlatUSB.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3])
@log_snapshot_on_error
def deploy_ha_one_controller_flat_usb(self):

View File

@ -27,6 +27,8 @@ from fuelweb_test.tests.base_test_case import SetupEnvironment
@test(groups=["multiple_cluster_networks", "thread_7"])
class TestMultipleClusterNets(TestBasic):
"""TestMultipleClusterNets.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["multiple_cluster_networks", "multiple_cluster_net_setup"])
@log_snapshot_on_error

View File

@ -26,6 +26,7 @@ from fuelweb_test import logger
@test(groups=["thread_1", "neutron", "smoke_neutron", "deployment"])
class NeutronGre(TestBasic):
"""NeutronGre.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_neutron_gre", "ha_one_controller_neutron_gre"])
@ -91,6 +92,7 @@ class NeutronGre(TestBasic):
@test(groups=["thread_1", "neutron"])
class NeutronVlan(TestBasic):
"""NeutronVlan.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_neutron_vlan", "ha_one_controller_neutron_vlan"])
@ -148,6 +150,7 @@ class NeutronVlan(TestBasic):
@test(groups=["neutron", "ha", "ha_neutron", "classic_provisioning"])
class NeutronGreHa(TestBasic):
"""NeutronGreHa.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_neutron_gre_ha", "ha_neutron_gre"])
@ -222,6 +225,7 @@ class NeutronGreHa(TestBasic):
@test(groups=["thread_6", "neutron", "ha", "ha_neutron"])
class NeutronGreHaPublicNetwork(TestBasic):
"""NeutronGreHaPublicNetwork.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_neutron_gre_ha_public_network"])
@ -287,6 +291,7 @@ class NeutronGreHaPublicNetwork(TestBasic):
@test(groups=["neutron", "ha", "ha_neutron"])
class NeutronVlanHa(TestBasic):
"""NeutronVlanHa.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_neutron_vlan_ha", "ha_neutron_vlan"])
@ -364,6 +369,7 @@ class NeutronVlanHa(TestBasic):
@test(groups=["thread_6", "neutron", "ha", "ha_neutron"])
class NeutronVlanHaPublicNetwork(TestBasic):
"""NeutronVlanHaPublicNetwork.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["deploy_neutron_vlan_ha_public_network"])

View File

@ -25,6 +25,8 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["test_pullrequest"])
class TestPullRequest(TestBasic):
"""TestPullRequest.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_pr_ha"])
@log_snapshot_on_error

View File

@ -33,6 +33,8 @@ from fuelweb_test.tests import base_test_case as base_test_data
@test(groups=["upgrade"])
class UpgradeFuelMaster(base_test_data.TestBasic):
"""UpgradeFuelMaster.""" # TODO documentation
@classmethod
def get_slave_kernel(cls, slave_remote):
kernel = ''.join(slave_remote.execute(
@ -357,6 +359,8 @@ class UpgradeFuelMaster(base_test_data.TestBasic):
@test(groups=["rollback"])
class RollbackFuelMaster(base_test_data.TestBasic):
"""RollbackFuelMaster.""" # TODO documentation
@test(groups=["rollback_automatic_ha"])
@log_snapshot_on_error
def rollback_automatically_ha_env(self):

View File

@ -28,6 +28,8 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["vcenter"])
class VcenterDeploy(TestBasic):
"""VcenterDeploy.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_1],
groups=["smoke", "vcenter_smoke"])
@log_snapshot_on_error

View File

@ -27,6 +27,8 @@ from fuelweb_test import logger
@test(groups=["known_issues"])
class HAOneControllerZabbix(TestBasic):
"""HAOneControllerZabbix.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_3],
groups=["deploy_ha_one_controller_zabbix"])
@log_snapshot_on_error

View File

@ -0,0 +1,13 @@
# Copyright 2015 Mirantis, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.

View File

@ -31,6 +31,8 @@ from fuelweb_test import logger
@test(groups=["os_patching"])
class TestPatch(TestBasic):
"""TestPatch.""" # TODO documentation
def __init__(self, snapshot):
super(TestPatch, self).__init__()
self.snapshot = snapshot

View File

@ -30,6 +30,7 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["patching"])
class PatchingTests(TestBasic):
"""PatchingTests.""" # TODO documentation
def __init__(self):
self.snapshot_name = settings.PATCHING_SNAPSHOT

View File

@ -33,6 +33,7 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["cic_maintenance_mode"])
class CICMaintenanceMode(TestBasic):
"""CICMaintenanceMode.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["cic_maintenance_mode_env"])

View File

@ -22,6 +22,8 @@ from fuelweb_test.tests.tests_strength.test_failover_base\
@test(groups=["ha", "neutron_failover", "ha_neutron_destructive"])
class TestHaNeutronFailover(TestHaFailoverBase):
"""TestHaNeutronFailover.""" # TODO documentation
snapshot_name = "prepare_ha_neutron"
@test(depends_on=[SetupEnvironment.prepare_slaves_5],

View File

@ -39,6 +39,7 @@ from fuelweb_test.tests.base_test_case import TestBasic
class TestHaFailoverBase(TestBasic):
"""TestHaFailoverBase.""" # TODO documentation
def deploy_ha(self, network='neutron'):

View File

@ -23,6 +23,8 @@ from fuelweb_test.helpers import os_actions
@test(groups=["huge_environments"])
class HugeEnvironments(base_test_case.TestBasic):
"""HugeEnvironments.""" # TODO documentation
@test(depends_on=[base_test_case.SetupEnvironment.prepare_slaves_9],
groups=["nine_nodes_mixed"])
@log_snapshot_on_error

View File

@ -23,6 +23,7 @@ from fuelweb_test.tests.base_test_case import TestBasic
@test(groups=["repeatable_image_based", "image_based"])
class RepeatableImageBased(TestBasic):
"""RepeatableImageBased.""" # TODO documentation
@test(depends_on=[SetupEnvironment.prepare_slaves_5],
groups=["repeatable_image_based", "image_based"])

View File

@ -26,6 +26,7 @@ from fuelweb_test.tests import base_test_case
@test(groups=["thread_non_func_1_usb"])
class DeployHAOneControllerMasterNodeFail(base_test_case.TestBasic):
"""DeployHAOneControllerMasterNodeFail.""" # TODO documentation
@test(depends_on=[base_test_case.SetupEnvironment.prepare_slaves_3],
groups=["non_functional",

View File

@ -28,6 +28,7 @@ from fuelweb_test.tests import base_test_case
@test(groups=["ha_neutron_destructive", "ha"])
class TestNeutronFailover(base_test_case.TestBasic):
"""TestNeutronFailover.""" # TODO documentation
@classmethod
def get_node_with_dhcp(cls, self, os_conn, net_id):

View File

@ -22,6 +22,7 @@ from fuelweb_test.tests import base_test_case
@test(groups=["ostf_repeatable_tests"])
class OstfRepeatableTests(base_test_case.TestBasic):
"""OstfRepeatableTests.""" # TODO documentation
@test(depends_on=[base_test_case.SetupEnvironment.prepare_slaves_3],
groups=["create_delete_ip_n_times_nova_vlan"])

View File

@ -28,6 +28,7 @@ from proboscis import test
@test(groups=["thread_3", "ceph"])
class CephRestart(TestBasic):
"""CephRestart.""" # TODO documentation
@test(depends_on_groups=['ceph_ha_one_controller_with_cinder'],
groups=["ceph_ha_one_controller_with_cinder_restart"])