cleanup some logging stuff
Signed-off-by: Nico Schottelius <nico@brief.schottelius.org>
This commit is contained in:
parent
7d57d1df79
commit
1bb3c82d72
3 changed files with 3 additions and 7 deletions
|
@ -20,10 +20,9 @@
|
|||
#
|
||||
#
|
||||
|
||||
import getpass
|
||||
import os
|
||||
import shutil
|
||||
import getpass
|
||||
import logging
|
||||
|
||||
import cdist
|
||||
from cdist import core
|
||||
|
@ -63,8 +62,6 @@ class CodeTestCase(test.CdistTestCase):
|
|||
self.cdist_object = core.CdistObject(self.cdist_type, self.local.object_path, 'whatever')
|
||||
self.cdist_object.create()
|
||||
|
||||
self.log = logging.getLogger("cdist")
|
||||
|
||||
def tearDown(self):
|
||||
shutil.rmtree(self.out_path)
|
||||
shutil.rmtree(self.remote_base_path)
|
||||
|
|
|
@ -23,7 +23,6 @@
|
|||
import os
|
||||
import shutil
|
||||
import getpass
|
||||
import logging
|
||||
|
||||
import cdist
|
||||
from cdist import core
|
||||
|
@ -67,8 +66,6 @@ class ExplorerClassTestCase(test.CdistTestCase):
|
|||
self.local,
|
||||
self.remote)
|
||||
|
||||
self.log = logging.getLogger(self.target_host)
|
||||
|
||||
def tearDown(self):
|
||||
shutil.rmtree(self.temp_dir)
|
||||
|
||||
|
|
|
@ -107,6 +107,8 @@ class ManifestTestCase(test.CdistTestCase):
|
|||
self.assertEqual(output_dict['__object_name'], cdist_object.name)
|
||||
|
||||
def test_debug_env_setup(self):
|
||||
current_level = self.log.getEffectiveLevel()
|
||||
self.log.setLevel(logging.DEBUG)
|
||||
manifest = cdist.core.manifest.Manifest(self.target_host, self.local)
|
||||
self.assertTrue("__cdist_debug" in manifest.env)
|
||||
self.log.setLevel(current_level)
|
||||
|
|
Loading…
Reference in a new issue