topology tempests

Change-Id: I960b83a4281155e61835ab3e690513f9f0b450e5
This commit is contained in:
Alexey Weyl 2016-04-05 16:31:53 +03:00
parent ffdc548d57
commit 182a86f342
12 changed files with 80 additions and 11 deletions

View File

@ -0,0 +1,15 @@
# Copyright 2016 - Nokia
#
# 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.
__author__ = 'stack'

View File

@ -11,6 +11,7 @@
# 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_log import log as logging
from vitrage_tempest_tests.tests.api.alarms.utils import AlarmsHelper
@ -21,9 +22,11 @@ LOG = logging.getLogger(__name__)
class BaseAlarmsTest(BaseVitrageTest):
"""Alarms test class for Vitrage API tests."""
def setUp(self):
super(BaseAlarmsTest, self).setUp()
self.client = AlarmsHelper()
@classmethod
def setUpClass(cls):
super(BaseAlarmsTest, cls).setUpClass()
cls.client = AlarmsHelper()
def test_compare_alarms(self):
"""Wrapper that returns a test graph."""

View File

@ -12,12 +12,12 @@
# License for the specific language governing permissions and limitations
# under the License.
# import json
import vitrage_tempest_tests.tests.utils as utils
from oslo_log import log as logging
from vitrage.api.controllers.v1.alarms import AlarmsController
# from vitrage.common.constants import VertexProperties as VProps
from vitrage_tempest_tests.tests.api.base import BaseVitrageTest
LOG = logging.getLogger(__name__)

View File

@ -22,9 +22,11 @@ LOG = logging.getLogger(__name__)
class BaseVitrageTest(base.BaseTestCase):
"""Base test class for Vitrage API tests."""
def setUp(self):
super(BaseVitrageTest, self).setUp()
self.conf = utils.get_conf()
@classmethod
def setUpClass(cls):
super(BaseVitrageTest, cls).setUpClass()
cls.conf = utils.get_conf()
def _create_graph_by_mock(self):
"""Create MOCK Graph and copied to the string """

View File

@ -0,0 +1,15 @@
# Copyright 2016 - Nokia
#
# 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.
__author__ = 'stack'

View File

@ -1 +0,0 @@
__author__ = 'stack'

View File

@ -0,0 +1,15 @@
# Copyright 2016 - Nokia
#
# 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.
__author__ = 'stack'

View File

@ -11,6 +11,7 @@
# 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_log import log as logging
from vitrage_tempest_tests.tests.api.base import BaseVitrageTest
@ -23,9 +24,10 @@ LOG = logging.getLogger(__name__)
class BaseTopologyTest(BaseVitrageTest):
"""Topology test class for Vitrage API tests."""
def setUp(self):
super(BaseTopologyTest, self).setUp()
self.topology_client = TopologyHelper()
@classmethod
def setUpClass(cls):
super(BaseTopologyTest, cls).setUpClass()
cls.topology_client = TopologyHelper()
def test_compare_graphs(self):
"""Wrapper that returns a test graph."""

View File

@ -11,6 +11,7 @@
# 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 json
import vitrage_tempest_tests.tests.utils as utils

View File

@ -11,6 +11,7 @@
# 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
from oslo_log import log as logging
from oslotest import base

View File

@ -0,0 +1,15 @@
# Copyright 2016 - Nokia
#
# 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.
__author__ = 'stack'

View File

@ -11,6 +11,7 @@
# 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
from oslo_log import log as logging
from vitrage import service