X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=yardstick%2Fbenchmark%2Fcontexts%2Fdummy.py;h=9faca4c63333ccd9c3625e01d73c0ad1aa621508;hb=abb0dd41a45dd6cbc0f1c0f2831aa2e0b4647566;hp=c658d325709ec3bdba0121f79216627117d27c38;hpb=6f541e757283b528d8736e314b2490f28d3c2563;p=yardstick.git diff --git a/yardstick/benchmark/contexts/dummy.py b/yardstick/benchmark/contexts/dummy.py index c658d3257..9faca4c63 100644 --- a/yardstick/benchmark/contexts/dummy.py +++ b/yardstick/benchmark/contexts/dummy.py @@ -7,33 +7,35 @@ # http://www.apache.org/licenses/LICENSE-2.0 ############################################################################## -from __future__ import absolute_import -import logging +from yardstick.benchmark import contexts +from yardstick.benchmark.contexts import base -from yardstick.benchmark.contexts.base import Context +class DummyContext(base.Context): + """Class that handle dummy info. -LOG = logging.getLogger(__name__) + This class is also used to test the abstract class Context because it + provides a minimal concrete implementation of a subclass. + """ - -class DummyContext(Context): - """Class that handle dummy info""" - - __context_type__ = "Dummy" - - def __init__(self): - super(DummyContext, self).__init__() - - def init(self, attrs): - pass + __context_type__ = contexts.CONTEXT_DUMMY def deploy(self): - """don't need to deploy""" + """Don't need to deploy""" pass def undeploy(self): - """don't need to undeploy""" - super(DummyContext, self).undeploy() + """Don't need to undeploy""" + pass def _get_server(self, attr_name): return None + + def _get_network(self, attr_name): + return None + + def _get_physical_nodes(self): + return None + + def _get_physical_node_for_server(self, server_name): + return None