Post-split, get jenkins tests passing
Change-Id: Ic6e545008504be633bf399712cd5bbbdf8184ad8
This commit is contained in:
parent
1d0d6c36b0
commit
221f2964b2
|
@ -9,6 +9,7 @@ doc/build
|
|||
*.DS_Store
|
||||
*.pyc
|
||||
neutron.egg-info/
|
||||
*.egg-info/
|
||||
neutron/vcsversion.py
|
||||
neutron/versioninfo
|
||||
pbr*.egg/
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
[DEFAULT]
|
||||
test_command=OS_STDOUT_CAPTURE=1 OS_STDERR_CAPTURE=1 OS_LOG_CAPTURE=1 ${PYTHON:-python} -m subunit.run discover -t ./ ${OS_TEST_PATH:-./neutron/tests/unit} $LISTOPT $IDOPTION
|
||||
test_command=OS_STDOUT_CAPTURE=1 OS_STDERR_CAPTURE=1 OS_LOG_CAPTURE=1 ${PYTHON:-python} -m subunit.run discover -t ./ ${OS_TEST_PATH:-./neutron_lbaas/tests/unit} $LISTOPT $IDOPTION
|
||||
test_id_option=--load-list $IDFILE
|
||||
test_list_option=--list
|
||||
|
|
|
@ -0,0 +1,240 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Copyright (c) 2010 OpenStack Foundation.
|
||||
#
|
||||
# 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.
|
||||
|
||||
#
|
||||
# Keystone documentation build configuration file, created by
|
||||
# sphinx-quickstart on Tue May 18 13:50:15 2010.
|
||||
#
|
||||
# This file is execfile()'d with the current directory set to it's containing
|
||||
# dir.
|
||||
#
|
||||
# Note that not all possible configuration values are present in this
|
||||
# autogenerated file.
|
||||
#
|
||||
# All configuration values have a default; values that are commented out
|
||||
# serve to show the default.
|
||||
|
||||
import os
|
||||
import sys
|
||||
|
||||
# If extensions (or modules to document with autodoc) are in another directory,
|
||||
# add these directories to sys.path here. If the directory is relative to the
|
||||
# documentation root, use os.path.abspath to make it absolute, like shown here.
|
||||
BASE_DIR = os.path.dirname(os.path.abspath(__file__))
|
||||
ROOT_DIR = os.path.abspath(os.path.join(BASE_DIR, "..", ".."))
|
||||
sys.path.insert(0, ROOT_DIR)
|
||||
|
||||
# -- General configuration ---------------------------------------------------
|
||||
|
||||
# Add any Sphinx extension module names here, as strings. They can be
|
||||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
|
||||
extensions = ['sphinx.ext.autodoc',
|
||||
'sphinx.ext.coverage',
|
||||
'sphinx.ext.ifconfig',
|
||||
'sphinx.ext.pngmath',
|
||||
'sphinx.ext.graphviz',
|
||||
'sphinx.ext.todo',
|
||||
'oslosphinx']
|
||||
|
||||
todo_include_todos = True
|
||||
|
||||
# Add any paths that contain templates here, relative to this directory.
|
||||
templates_path = []
|
||||
if os.getenv('HUDSON_PUBLISH_DOCS'):
|
||||
templates_path = ['_ga', '_templates']
|
||||
else:
|
||||
templates_path = ['_templates']
|
||||
|
||||
# The suffix of source filenames.
|
||||
source_suffix = '.rst'
|
||||
|
||||
# The encoding of source files.
|
||||
#source_encoding = 'utf-8'
|
||||
|
||||
# The master toctree document.
|
||||
master_doc = 'index'
|
||||
|
||||
# General information about the project.
|
||||
project = u'Neutron LBaaS'
|
||||
copyright = u'2011-present, OpenStack Foundation.'
|
||||
|
||||
# The version info for the project you're documenting, acts as replacement for
|
||||
# |version| and |release|, also used in various other places throughout the
|
||||
# built documents.
|
||||
#
|
||||
# Version info
|
||||
from neutron_lbaas.version import version_info as neutron_lbaas_version
|
||||
release = neutron_lbaas_version.release_string()
|
||||
# The short X.Y version.
|
||||
version = neutron_lbaas_version.version_string()
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
#language = None
|
||||
|
||||
# There are two options for replacing |today|: either, you set today to some
|
||||
# non-false value, then it is used:
|
||||
#today = ''
|
||||
# Else, today_fmt is used as the format for a strftime call.
|
||||
#today_fmt = '%B %d, %Y'
|
||||
|
||||
# List of documents that shouldn't be included in the build.
|
||||
# unused_docs = []
|
||||
|
||||
# List of directories, relative to source directory, that shouldn't be searched
|
||||
# for source files.
|
||||
exclude_trees = []
|
||||
|
||||
# The reST default role (for this markup: `text`) to use for all documents.
|
||||
#default_role = None
|
||||
|
||||
# If true, '()' will be appended to :func: etc. cross-reference text.
|
||||
#add_function_parentheses = True
|
||||
|
||||
# If true, the current module name will be prepended to all description
|
||||
# unit titles (such as .. function::).
|
||||
#add_module_names = True
|
||||
|
||||
# If true, sectionauthor and moduleauthor directives will be shown in the
|
||||
# output. They are ignored by default.
|
||||
show_authors = True
|
||||
|
||||
# The name of the Pygments (syntax highlighting) style to use.
|
||||
pygments_style = 'sphinx'
|
||||
|
||||
# A list of ignored prefixes for module index sorting.
|
||||
modindex_common_prefix = ['neutron_lbaas.']
|
||||
|
||||
# -- Options for man page output --------------------------------------------
|
||||
|
||||
# Grouping the document tree for man pages.
|
||||
# List of tuples 'sourcefile', 'target', u'title', u'Authors name', 'manual'
|
||||
|
||||
#man_pages = [
|
||||
# ('man/neutron-server', 'neutron-server', u'Neutron Server',
|
||||
# [u'OpenStack'], 1)
|
||||
#]
|
||||
|
||||
|
||||
# -- Options for HTML output -------------------------------------------------
|
||||
|
||||
# The theme to use for HTML and HTML Help pages. Major themes that come with
|
||||
# Sphinx are currently 'default' and 'sphinxdoc'.
|
||||
# html_theme_path = ["."]
|
||||
# html_theme = '_theme'
|
||||
|
||||
# Theme options are theme-specific and customize the look and feel of a theme
|
||||
# further. For a list of options available for each theme, see the
|
||||
# documentation.
|
||||
#html_theme_options = {}
|
||||
|
||||
# Add any paths that contain custom themes here, relative to this directory.
|
||||
#html_theme_path = ['_theme']
|
||||
|
||||
# The name for this set of Sphinx documents. If None, it defaults to
|
||||
# "<project> v<release> documentation".
|
||||
#html_title = None
|
||||
|
||||
# A shorter title for the navigation bar. Default is the same as html_title.
|
||||
#html_short_title = None
|
||||
|
||||
# The name of an image file (relative to this directory) to place at the top
|
||||
# of the sidebar.
|
||||
#html_logo = None
|
||||
|
||||
# The name of an image file (within the static path) to use as favicon of the
|
||||
# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
|
||||
# pixels large.
|
||||
#html_favicon = None
|
||||
|
||||
# Add any paths that contain custom static files (such as style sheets) here,
|
||||
# relative to this directory. They are copied after the builtin static files,
|
||||
# so a file named "default.css" will overwrite the builtin "default.css".
|
||||
# html_static_path = ['_static']
|
||||
|
||||
# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
|
||||
# using the given strftime format.
|
||||
#html_last_updated_fmt = '%b %d, %Y'
|
||||
git_cmd = "git log --pretty=format:'%ad, commit %h' --date=local -n1"
|
||||
html_last_updated_fmt = os.popen(git_cmd).read()
|
||||
|
||||
# If true, SmartyPants will be used to convert quotes and dashes to
|
||||
# typographically correct entities.
|
||||
#html_use_smartypants = True
|
||||
|
||||
# Custom sidebar templates, maps document names to template names.
|
||||
#html_sidebars = {}
|
||||
|
||||
# Additional templates that should be rendered to pages, maps page names to
|
||||
# template names.
|
||||
#html_additional_pages = {}
|
||||
|
||||
# If false, no module index is generated.
|
||||
#html_use_modindex = True
|
||||
|
||||
# If false, no index is generated.
|
||||
#html_use_index = True
|
||||
|
||||
# If true, the index is split into individual pages for each letter.
|
||||
#html_split_index = False
|
||||
|
||||
# If true, links to the reST sources are added to the pages.
|
||||
#html_show_sourcelink = True
|
||||
|
||||
# If true, an OpenSearch description file will be output, and all pages will
|
||||
# contain a <link> tag referring to it. The value of this option must be the
|
||||
# base URL from which the finished HTML is served.
|
||||
#html_use_opensearch = ''
|
||||
|
||||
# If nonempty, this is the file name suffix for HTML files (e.g. ".xhtml").
|
||||
#html_file_suffix = ''
|
||||
|
||||
# Output file base name for HTML help builder.
|
||||
#htmlhelp_basename = 'neutrondoc'
|
||||
|
||||
|
||||
# -- Options for LaTeX output ------------------------------------------------
|
||||
|
||||
# The paper size ('letter' or 'a4').
|
||||
#latex_paper_size = 'letter'
|
||||
|
||||
# The font size ('10pt', '11pt' or '12pt').
|
||||
#latex_font_size = '10pt'
|
||||
|
||||
# Grouping the document tree into LaTeX files. List of tuples
|
||||
# (source start file, target name, title, author,
|
||||
# documentclass [howto/manual]).
|
||||
#latex_documents = [
|
||||
# ('index', 'Neutron.tex', u'Neutron Documentation',
|
||||
# u'Neutron development team', 'manual'),
|
||||
#]
|
||||
|
||||
# The name of an image file (relative to this directory) to place at the top of
|
||||
# the title page.
|
||||
#latex_logo = None
|
||||
|
||||
# For "manual" documents, if this is true, then toplevel headings are parts,
|
||||
# not chapters.
|
||||
#latex_use_parts = False
|
||||
|
||||
# Additional stuff for the LaTeX preamble.
|
||||
#latex_preamble = ''
|
||||
|
||||
# Documents to append as an appendix to all manuals.
|
||||
#latex_appendices = []
|
||||
|
||||
# If false, no module index is generated.
|
||||
#latex_use_modindex = True
|
|
@ -0,0 +1,17 @@
|
|||
.. documentation master file
|
||||
|
||||
====
|
||||
Main
|
||||
====
|
||||
|
||||
.. toctree::
|
||||
:glob:
|
||||
:maxdepth: 1
|
||||
|
||||
main/*
|
||||
|
||||
==================
|
||||
Indices and tables
|
||||
==================
|
||||
|
||||
* :ref:`search`
|
|
@ -15,9 +15,9 @@
|
|||
import a10_neutron_lbaas
|
||||
|
||||
from neutron.db import l3_db
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as lb_db
|
||||
from neutron.openstack.common import log as logging
|
||||
from neutron.plugins.common import constants
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as lb_db
|
||||
from neutron_lbaas.services.loadbalancer.drivers import abstract_driver
|
||||
|
||||
VERSION = "1.0.0"
|
||||
|
|
|
@ -23,12 +23,12 @@ from neutron.common import exceptions as n_exc
|
|||
from neutron.common import rpc as n_rpc
|
||||
from neutron.common import topics
|
||||
from neutron.db import agents_db
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db
|
||||
from neutron.extensions import lbaas_agentscheduler
|
||||
from neutron.extensions import portbindings
|
||||
from neutron.i18n import _LW
|
||||
from neutron.openstack.common import log as logging
|
||||
from neutron.plugins.common import constants
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db
|
||||
from neutron_lbaas.services.loadbalancer.drivers import abstract_driver
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
|
|
@ -20,8 +20,10 @@ from heleosapi import exceptions as h_exc
|
|||
from neutron.i18n import _LE
|
||||
from neutron.openstack.common import log as logging
|
||||
from neutron.plugins.embrane.common import contexts as ctx
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane.agent import lb_operations
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import constants as econ
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane.agent \
|
||||
import lb_operations
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane \
|
||||
import constants as econ
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
||||
|
|
|
@ -20,7 +20,8 @@ from heleosapi import exceptions as h_exc
|
|||
from neutron.i18n import _LW
|
||||
from neutron.openstack.common import log as logging
|
||||
from neutron_lbaas.services.loadbalancer import constants as lcon
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import constants as econ
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane \
|
||||
import constants as econ
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
handlers = {}
|
||||
|
|
|
@ -20,7 +20,6 @@ from oslo.config import cfg
|
|||
|
||||
from neutron.api.v2 import attributes
|
||||
from neutron.common import exceptions as n_exc
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron.extensions import loadbalancer as lb_ext
|
||||
from neutron.i18n import _LW
|
||||
from neutron.openstack.common import log as logging
|
||||
|
@ -28,11 +27,14 @@ from neutron.plugins.common import constants as pcon
|
|||
from neutron.plugins.embrane.common import contexts as embrane_ctx
|
||||
from neutron.plugins.embrane.common import exceptions as h_exc
|
||||
from neutron.plugins.embrane.common import utils
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron_lbaas.services.loadbalancer import constants as lbcon
|
||||
from neutron_lbaas.services.loadbalancer.drivers import abstract_driver
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane.agent import dispatcher
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane.agent \
|
||||
import dispatcher
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import config # noqa
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import constants as econ
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane \
|
||||
import constants as econ
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import db as edb
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import poller
|
||||
|
||||
|
|
|
@ -16,14 +16,15 @@
|
|||
from heleosapi import exceptions as h_exc
|
||||
|
||||
from neutron import context
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron.db import servicetype_db as sdb
|
||||
from neutron.i18n import _LE
|
||||
from neutron.openstack.common import log as logging
|
||||
from neutron.openstack.common import loopingcall
|
||||
from neutron.plugins.common import constants as ccon
|
||||
from neutron.plugins.embrane.common import contexts as embrane_ctx
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import constants as econ
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane \
|
||||
import constants as econ
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
skip_states = [ccon.PENDING_CREATE,
|
||||
|
|
|
@ -13,8 +13,10 @@
|
|||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from neutron_lbaas.services.loadbalancer.drivers.common import agent_driver_base
|
||||
from neutron_lbaas.services.loadbalancer.drivers.haproxy import namespace_driver
|
||||
from neutron_lbaas.services.loadbalancer.drivers.common \
|
||||
import agent_driver_base
|
||||
from neutron_lbaas.services.loadbalancer.drivers.haproxy \
|
||||
import namespace_driver
|
||||
|
||||
|
||||
class HaproxyOnHostPluginDriver(agent_driver_base.AgentDriverBase):
|
||||
|
|
|
@ -15,10 +15,10 @@
|
|||
from oslo.config import cfg
|
||||
|
||||
from neutron.api.v2 import attributes
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db
|
||||
from neutron.i18n import _LI
|
||||
from neutron.openstack.common import log as logging
|
||||
from neutron.plugins.common import constants
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db
|
||||
from neutron_lbaas.services.loadbalancer.drivers import abstract_driver
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler import ncc_client
|
||||
|
||||
|
|
|
@ -31,13 +31,14 @@ from six.moves import queue as Queue
|
|||
from neutron.api.v2 import attributes
|
||||
from neutron.common import log as call_log
|
||||
from neutron import context
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as lb_db
|
||||
from neutron.extensions import loadbalancer
|
||||
from neutron.i18n import _LE, _LI, _LW
|
||||
from neutron.openstack.common import log as logging
|
||||
from neutron.plugins.common import constants
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as lb_db
|
||||
from neutron_lbaas.services.loadbalancer.drivers import abstract_driver
|
||||
from neutron_lbaas.services.loadbalancer.drivers.radware import exceptions as r_exc
|
||||
from neutron_lbaas.services.loadbalancer.drivers.radware \
|
||||
import exceptions as r_exc
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
||||
|
|
|
@ -18,15 +18,15 @@ from oslo.utils import excutils
|
|||
from neutron.api.v2 import attributes as attrs
|
||||
from neutron.common import exceptions as n_exc
|
||||
from neutron import context
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron.db import servicetype_db as st_db
|
||||
from neutron.extensions import loadbalancer
|
||||
from neutron.i18n import _LE
|
||||
from neutron.openstack.common import log as logging
|
||||
from neutron.plugins.common import constants
|
||||
from neutron.services import provider_configuration as pconf
|
||||
from neutron.services import service_base
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron_lbaas.services.loadbalancer import agent_scheduler
|
||||
from neutron_lbaas.services import provider_configuration as pconf
|
||||
from neutron_lbaas.services import service_base
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
# Copyright 2011 OpenStack Foundation.
|
||||
# All Rights Reserved.
|
||||
#
|
||||
# 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.
|
||||
|
||||
from oslo.config import cfg
|
||||
|
||||
|
||||
cfg.CONF.use_stderr = False
|
|
@ -24,18 +24,18 @@ from neutron.api import extensions
|
|||
from neutron.common import config
|
||||
from neutron.common import exceptions as n_exc
|
||||
from neutron import context
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron.db import servicetype_db as sdb
|
||||
import neutron.extensions
|
||||
from neutron.extensions import loadbalancer
|
||||
from neutron import manager
|
||||
from neutron.plugins.common import constants
|
||||
from neutron.services import provider_configuration as pconf
|
||||
from neutron.tests.unit import test_db_plugin
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron_lbaas.services.loadbalancer import (
|
||||
plugin as loadbalancer_plugin
|
||||
)
|
||||
from neutron_lbaas.services.loadbalancer.drivers import abstract_driver
|
||||
from neutron_lbaas.services import provider_configuration as pconf
|
||||
from neutron.tests.unit import test_db_plugin
|
||||
|
||||
|
||||
DB_CORE_PLUGIN_KLASS = 'neutron.db.db_base_plugin_v2.NeutronDbPluginV2'
|
|
@ -16,8 +16,8 @@ import contextlib
|
|||
import mock
|
||||
from oslo.config import cfg
|
||||
|
||||
from neutron_lbaas.services.loadbalancer.agent import agent
|
||||
from neutron.tests import base
|
||||
from neutron_lbaas.services.loadbalancer.agent import agent
|
||||
|
||||
|
||||
class TestLbaasService(base.BaseTestCase):
|
|
@ -17,8 +17,8 @@ import contextlib
|
|||
import mock
|
||||
|
||||
from neutron.plugins.common import constants
|
||||
from neutron_lbaas.services.loadbalancer.agent import agent_manager as manager
|
||||
from neutron.tests import base
|
||||
from neutron_lbaas.services.loadbalancer.agent import agent_manager as manager
|
||||
|
||||
|
||||
class TestManager(base.BaseTestCase):
|
|
@ -16,8 +16,8 @@ import contextlib
|
|||
import copy
|
||||
import mock
|
||||
|
||||
from neutron_lbaas.services.loadbalancer.agent import agent_api as api
|
||||
from neutron.tests import base
|
||||
from neutron_lbaas.services.loadbalancer.agent import agent_api as api
|
||||
|
||||
|
||||
class TestApiCache(base.BaseTestCase):
|
|
@ -17,10 +17,11 @@ import sys
|
|||
import mock
|
||||
|
||||
from neutron import context
|
||||
from neutron.tests.unit.db.loadbalancer import test_db_loadbalancer
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as lb_db
|
||||
with mock.patch.dict(sys.modules, {'a10_neutron_lbaas': mock.Mock()}):
|
||||
from neutron_lbaas.services.loadbalancer.drivers.a10networks import driver_v1
|
||||
from neutron.tests.unit.db.loadbalancer import test_db_loadbalancer
|
||||
from neutron_lbaas.services.loadbalancer.drivers.a10networks \
|
||||
import driver_v1
|
||||
|
||||
|
||||
def fake_model(id):
|
|
@ -15,8 +15,8 @@
|
|||
|
||||
from oslo.config import cfg
|
||||
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import config # noqa
|
||||
from neutron.tests import base
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import config # noqa
|
||||
|
||||
|
||||
class ConfigurationTest(base.BaseTestCase):
|
|
@ -25,7 +25,8 @@ from neutron.tests.unit.db.loadbalancer import test_db_loadbalancer
|
|||
HELEOSAPIMOCK = mock.Mock()
|
||||
sys.modules["heleosapi"] = HELEOSAPIMOCK
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import config # noqa
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import constants as h_con
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane \
|
||||
import constants as h_con
|
||||
from neutron_lbaas.services.loadbalancer.drivers.embrane import db as h_db
|
||||
# Stop the mock from persisting indefinitely in the global modules space
|
||||
del sys.modules["heleosapi"]
|
|
@ -17,8 +17,8 @@ import contextlib
|
|||
|
||||
import mock
|
||||
|
||||
from neutron_lbaas.services.loadbalancer.drivers.haproxy import cfg
|
||||
from neutron.tests import base
|
||||
from neutron_lbaas.services.loadbalancer.drivers.haproxy import cfg
|
||||
|
||||
|
||||
class TestHaproxyCfg(base.BaseTestCase):
|
|
@ -17,8 +17,9 @@ import contextlib
|
|||
import mock
|
||||
|
||||
from neutron.common import exceptions
|
||||
from neutron_lbaas.services.loadbalancer.drivers.haproxy import namespace_driver
|
||||
from neutron.tests import base
|
||||
from neutron_lbaas.services.loadbalancer.drivers.haproxy \
|
||||
import namespace_driver
|
||||
|
||||
|
||||
class TestHaproxyNSDriver(base.BaseTestCase):
|
|
@ -15,8 +15,8 @@
|
|||
import mock
|
||||
|
||||
from neutron import context
|
||||
from neutron_lbaas.services.loadbalancer.drivers.logging_noop import driver
|
||||
from neutron.tests.unit.db.loadbalancer import test_db_loadbalancer
|
||||
from neutron_lbaas.services.loadbalancer.drivers.logging_noop import driver
|
||||
|
||||
log_path = 'neutron.services.loadbalancer.drivers.logging_noop.driver.LOG'
|
||||
|
|
@ -15,9 +15,10 @@
|
|||
import mock
|
||||
import requests
|
||||
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler import ncc_client
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler import netscaler_driver
|
||||
from neutron.tests.unit import testlib_api
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler import ncc_client
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler \
|
||||
import netscaler_driver
|
||||
|
||||
NCC_CLIENT_CLASS = ('neutron.services.loadbalancer.drivers'
|
||||
'.netscaler.ncc_client.NSClient')
|
|
@ -18,12 +18,13 @@ import mock
|
|||
|
||||
from neutron.common import exceptions
|
||||
from neutron import context
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db
|
||||
from neutron import manager
|
||||
from neutron.plugins.common import constants
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler import ncc_client
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler import netscaler_driver
|
||||
from neutron.tests.unit.db.loadbalancer import test_db_loadbalancer
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler import ncc_client
|
||||
from neutron_lbaas.services.loadbalancer.drivers.netscaler \
|
||||
import netscaler_driver
|
||||
|
||||
|
||||
LBAAS_DRIVER_CLASS = ('neutron.services.loadbalancer.drivers'
|
|
@ -25,9 +25,10 @@ from neutron import context
|
|||
from neutron.extensions import loadbalancer
|
||||
from neutron import manager
|
||||
from neutron.plugins.common import constants
|
||||
from neutron_lbaas.services.loadbalancer.drivers.radware import driver
|
||||
from neutron_lbaas.services.loadbalancer.drivers.radware import exceptions as r_exc
|
||||
from neutron.tests.unit.db.loadbalancer import test_db_loadbalancer
|
||||
from neutron_lbaas.services.loadbalancer.drivers.radware import driver
|
||||
from neutron_lbaas.services.loadbalancer.drivers.radware \
|
||||
import exceptions as r_exc
|
||||
|
||||
GET_200 = ('/api/workflow/', '/api/service/', '/api/workflowTemplate')
|
||||
SERVER_DOWN_CODES = (-1, 301, 307)
|
|
@ -19,17 +19,18 @@ from six import moves
|
|||
from webob import exc
|
||||
|
||||
from neutron import context
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron.db import servicetype_db as st_db
|
||||
from neutron.extensions import loadbalancer
|
||||
from neutron.extensions import portbindings
|
||||
from neutron import manager
|
||||
from neutron.openstack.common import uuidutils
|
||||
from neutron.plugins.common import constants
|
||||
from neutron_lbaas.services.loadbalancer.drivers.common import agent_driver_base
|
||||
from neutron.tests import base
|
||||
from neutron.tests.unit.db.loadbalancer import test_db_loadbalancer
|
||||
from neutron.tests.unit import testlib_api
|
||||
from neutron_lbaas.db.loadbalancer import loadbalancer_db as ldb
|
||||
from neutron_lbaas.services.loadbalancer.drivers.common \
|
||||
import agent_driver_base
|
||||
|
||||
|
||||
class TestLoadBalancerPluginBase(
|
|
@ -1,19 +0,0 @@
|
|||
# Copyright 2011 OpenStack Foundation.
|
||||
# All Rights Reserved.
|
||||
#
|
||||
# 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.
|
||||
|
||||
from oslo.config import cfg
|
||||
|
||||
|
||||
cfg.CONF.use_stderr = False
|
|
@ -0,0 +1,22 @@
|
|||
# Copyright 2012 OpenStack Foundation.
|
||||
# All Rights Reserved.
|
||||
#
|
||||
# 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 unittest
|
||||
|
||||
|
||||
class FakeTest(unittest.TestCase):
|
||||
|
||||
def test_true(self):
|
||||
self.assertTrue(True)
|
|
@ -0,0 +1,17 @@
|
|||
# Copyright 2011 OpenStack Foundation
|
||||
#
|
||||
# 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 pbr.version
|
||||
|
||||
version_info = pbr.version.VersionInfo('neutron-lbaas')
|
|
@ -1,7 +1,7 @@
|
|||
[metadata]
|
||||
name = neutron
|
||||
name = neutron-lbaas
|
||||
version = 2015.1
|
||||
summary = OpenStack Networking
|
||||
summary = OpenStack Networking Load Balancing as a Service
|
||||
description-file =
|
||||
README.rst
|
||||
author = OpenStack
|
||||
|
@ -19,7 +19,7 @@ classifier =
|
|||
|
||||
[files]
|
||||
packages =
|
||||
neutron-lbaas
|
||||
neutron_lbaas
|
||||
data_files =
|
||||
etc/neutron =
|
||||
etc/lbaas_agent.ini
|
||||
|
@ -30,7 +30,7 @@ setup-hooks =
|
|||
|
||||
[entry_points]
|
||||
console_scripts =
|
||||
neutron-lbaas-agent = neutron.services.loadbalancer.agent.agent:main
|
||||
neutron-lbaas-agent = neutron_lbaas.services.loadbalancer.agent.agent:main
|
||||
|
||||
[build_sphinx]
|
||||
all_files = 1
|
||||
|
|
21
tox.ini
21
tox.ini
|
@ -1,5 +1,5 @@
|
|||
[tox]
|
||||
envlist = py27,py33,py34,pep8
|
||||
envlist = py27,py33,py34,pep8,pylint
|
||||
minversion = 1.6
|
||||
skipsdist = True
|
||||
|
||||
|
@ -9,9 +9,8 @@ skipsdist = True
|
|||
setenv = VIRTUAL_ENV={envdir}
|
||||
PYTHONHASHSEED=0
|
||||
usedevelop = True
|
||||
install_command = pip install -U {opts} {packages}
|
||||
deps = -r{toxinidir}/requirements.txt
|
||||
-r{toxinidir}/test-requirements.txt
|
||||
install_command = pip install -r requirements.txt -U {opts} {packages}
|
||||
deps = -r{toxinidir}/test-requirements.txt
|
||||
whitelist_externals = sh
|
||||
commands =
|
||||
sh tools/pretty_tox.sh '{posargs}'
|
||||
|
@ -27,7 +26,7 @@ setenv = VIRTUAL_ENV={envdir}
|
|||
[testenv:functional]
|
||||
setenv = OS_TEST_PATH=./neutron-lbaas/tests/functional
|
||||
commands =
|
||||
python -m neutron.openstack.common.lockutils python setup.py testr --slowest --testr-args='{posargs}'
|
||||
python -m neutron_lbaas.openstack.common.lockutils python setup.py testr --slowest --testr-args='{posargs}'
|
||||
|
||||
[testenv:dsvm-functional]
|
||||
setenv = OS_TEST_PATH=./neutron-lbaas/tests/functional
|
||||
|
@ -36,7 +35,7 @@ setenv = OS_TEST_PATH=./neutron-lbaas/tests/functional
|
|||
OS_FAIL_ON_MISSING_DEPS=1
|
||||
sitepackages=True
|
||||
commands =
|
||||
python -m neutron.openstack.common.lockutils python setup.py testr --slowest --testr-args='{posargs}'
|
||||
python -m neutron_lbaas.openstack.common.lockutils python setup.py testr --slowest --testr-args='{posargs}'
|
||||
|
||||
[tox:jenkins]
|
||||
sitepackages = True
|
||||
|
@ -46,16 +45,16 @@ downloadcache = ~/cache/pip
|
|||
commands =
|
||||
sh ./tools/check_bash.sh
|
||||
flake8
|
||||
neutron-db-manage check_migration
|
||||
sh -c "find neutron-lbaas -type f -regex '.*\.pot?' -print0|xargs -0 -n 1 msgfmt --check-format -o /dev/null"
|
||||
#neutron-db-manage check_migration
|
||||
#sh -c "find neutron_lbaas -type f -regex '.*\.pot?' -print0|xargs -0 -n 1 msgfmt --check-format -o /dev/null"
|
||||
whitelist_externals = sh
|
||||
|
||||
[testenv:i18n]
|
||||
commands = python ./tools/check_i18n.py ./neutron ./tools/i18n_cfg.py
|
||||
commands = python ./tools/check_i18n.py ./neutron_lbaas ./tools/i18n_cfg.py
|
||||
|
||||
[testenv:cover]
|
||||
commands =
|
||||
python -m neutron.openstack.common.lockutils python setup.py testr --coverage --testr-args='{posargs}'
|
||||
python -m neutron_lbaas.openstack.common.lockutils python setup.py testr --coverage --testr-args='{posargs}'
|
||||
|
||||
[testenv:venv]
|
||||
commands = {posargs}
|
||||
|
@ -85,7 +84,7 @@ deps =
|
|||
{[testenv]deps}
|
||||
pylint
|
||||
commands =
|
||||
pylint --rcfile=.pylintrc --output-format=colorized {posargs:neutron}
|
||||
pylint --rcfile=.pylintrc --output-format=colorized {posargs:neutron_lbaas}
|
||||
|
||||
[hacking]
|
||||
import_exceptions = neutron.i18n
|
||||
|
|
Loading…
Reference in New Issue