Skip to content

Commit

Permalink
Changed version and fixed flake issues
Browse files Browse the repository at this point in the history
  • Loading branch information
isaac-s committed Nov 16, 2017
1 parent 451e701 commit ce27fee
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions agent_packager/dictconfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,8 @@ def valid_ident(s):
raise ValueError('Not a valid Python identifier: %r' % s)
return True

#

# This function is defined in logging only in recent versions of Python
#
try:
from logging import _checkLevel
except ImportError:
Expand Down Expand Up @@ -538,6 +537,7 @@ def configure_root(self, config, incremental=False):
root = logging.getLogger()
self.common_logger_config(root, config, incremental)


dictConfigClass = DictConfigurator


Expand Down
14 changes: 7 additions & 7 deletions agent_packager/tests/test_agent_packager.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ def venv(func):
def execution_handler(*args, **kwargs):
try:
shutil.rmtree(TEST_VENV)
except:
except Exception:
pass
utils.make_virtualenv(TEST_VENV)
func(*args, **kwargs)
Expand All @@ -60,16 +60,16 @@ class TestUtils(testtools.TestCase):
def test_set_global_verbosity_level(self):
lgr = init(base_level=logging.INFO)

with LogCapture() as l:
with LogCapture() as log_cap:
ap.set_global_verbosity_level(is_verbose_output=False)
lgr.debug('TEST_LOGGER_OUTPUT')
l.check()
log_cap.check()
lgr.info('TEST_LOGGER_OUTPUT')
l.check(('user', 'INFO', 'TEST_LOGGER_OUTPUT'))
log_cap.check(('user', 'INFO', 'TEST_LOGGER_OUTPUT'))

ap.set_global_verbosity_level(is_verbose_output=True)
lgr.debug('TEST_LOGGER_OUTPUT')
l.check(
log_cap.check(
('user', 'INFO', 'TEST_LOGGER_OUTPUT'),
('user', 'DEBUG', 'TEST_LOGGER_OUTPUT'))

Expand Down Expand Up @@ -263,9 +263,9 @@ def test_dryrun(self):
'--no-validation': False,
'--verbose': True
}
with LogCapture(level=logging.INFO) as l:
with LogCapture(level=logging.INFO) as log_cap:
e = self.assertRaises(SystemExit, cli._run, cli_options)
l.check(('user', 'INFO', 'Dryrun complete'))
log_cap.check(('user', 'INFO', 'Dryrun complete'))
self.assertEqual(codes.notifications['dryrun_complete'], e.message)

@venv
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def read(*parts):

setup(
name='cloudify-agent-packager',
version='4.0.0',
version='4.2',
url='https://github.com/cloudify-cosmo/cloudify-agent-packager',
author='Gigaspaces',
author_email='[email protected]',
Expand Down

0 comments on commit ce27fee

Please sign in to comment.