aboutsummaryrefslogtreecommitdiffstats
path: root/keystone-moon/keystone/tests/moon/unit/test_unit_core_configuration.py
blob: e6388559a9e81ef616477cbc273b1beb4d85e16a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# Copyright 2015 Open Platform for NFV Project, Inc. and its contributors
# This software is distributed under the terms and conditions of the 'Apache-2.0'
# license which can be found in the file 'LICENSE' in this package distribution
# or at 'http://www.apache.org/licenses/LICENSE-2.0'.

"""Unit tests for core configuration."""

import uuid
from oslo_config import cfg
from keystone.tests import unit as tests
from keystone.contrib.moon.core import ConfigurationManager
from keystone.tests.unit.ksfixtures import database
from keystone.contrib.moon.exception import *
from keystone.tests.unit import default_fixtures
from keystone.contrib.moon.core import LogManager

CONF = cfg.CONF


class TestConfigurationManager(tests.TestCase):

    def setUp(self):
        self.useFixture(database.Database())
        super(TestConfigurationManager, self).setUp()
        self.load_backends()
        self.load_fixtures(default_fixtures)
        self.manager = ConfigurationManager()

    def load_extra_backends(self):
        return {
            "moonlog_api": LogManager()
        }

    def config_overrides(self):
        super(TestConfigurationManager, self).config_overrides()
        self.config_fixture.config(
            group='moon',
            tenant_driver='keystone.contrib.moon.backends.sql.ConfigurationConnector')

    def test_get_policy_template_dict(self):
        pass

    def test_get_policy_template_id_from_name(self):
        pass

    def test_get_aggregation_algorithm_dict(self):
        pass

    def test_get_aggregation_algorithm_id_from_name(self):
        pass

    def test_get_sub_meta_rule_algorithm_dict(self):
        pass

    def test_get_sub_meta_rule_algorithm_id_from_name(self):
        pass