From 399713200318a97fd6977f35f79a17168edf113b Mon Sep 17 00:00:00 2001 From: Mingyuan Qi Date: Tue, 14 Jan 2020 12:10:11 +0800 Subject: [PATCH] Add test class for kube_app AppOperator Add test class and setup method. Mock method/operator will be added in individual commits which use that method or operator. Story: 2007082 Task: 37998 Change-Id: I60a4b235417f288adb4a13577b9779d79169a233 Signed-off-by: Mingyuan Qi --- .../conductor/test_kube_app_app_operator.py | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 sysinv/sysinv/sysinv/sysinv/tests/conductor/test_kube_app_app_operator.py diff --git a/sysinv/sysinv/sysinv/sysinv/tests/conductor/test_kube_app_app_operator.py b/sysinv/sysinv/sysinv/sysinv/tests/conductor/test_kube_app_app_operator.py new file mode 100644 index 0000000000..b9f4dfda32 --- /dev/null +++ b/sysinv/sysinv/sysinv/sysinv/tests/conductor/test_kube_app_app_operator.py @@ -0,0 +1,24 @@ +# +# SPDX-License-Identifier: Apache-2.0 +# +# Copyright (C) 2020 Intel Corporation +# + +"""Test class for Sysinv kube_app AppOperator.""" + +from sysinv.conductor import kube_app +from sysinv.db import api as dbapi +from sysinv.openstack.common import context + +from sysinv.tests.db import base + + +class AppOperatorTestCase(base.DbTestCase): + + def setUp(self): + super(AppOperatorTestCase, self).setUp() + + # Set up objects for testing + self.app_operator = kube_app.AppOperator(dbapi.get_instance()) + self.context = context.get_admin_context() + self.dbapi = dbapi.get_instance()