Skip to content

Commit

Permalink
Merge branch 'develop' into feature/feature/ZEN-26894-fix-production-…
Browse files Browse the repository at this point in the history
…state-sort-error
  • Loading branch information
jonathan borden committed Mar 15, 2017
2 parents f7ce431 + 9ea5506 commit 05441fa
Show file tree
Hide file tree
Showing 4 changed files with 18,786 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Products/ZenModel/BatchDeviceLoader.py
Expand Up @@ -45,11 +45,11 @@
from zenoss.protocols.protobufs.zep_pb2 import SEVERITY_INFO, SEVERITY_ERROR

def transactional(f):
def wrapper(*args):
if args[0].options.nocommit:
f.__call__(*args)
def wrapper(obj, *args, **kwargs):
if obj.options.nocommit:
return f.__call__(obj, *args, **kwargs)
else:
transact(f).__call__(*args)
return transact(f).__call__(obj, *args, **kwargs)
return wrapper

class BatchDeviceLoader(ZCmdBase):
Expand Down
@@ -0,0 +1,21 @@
#!/usr/bin/env python

import os
import unittest

import Globals
import common


class Test_UpdateOpenTSDBSkipResolvedTags(unittest.TestCase, common.ServiceMigrationTestCase):
"""
Test that open tsdb configs have the skip_unresolved_tagvs setting added/set.
"""
initial_servicedef = 'zenoss-resmgr-5.1.5.json'
expected_servicedef = 'zenoss-resmgr-5.1.5-updateOpenTSDBSkipUnresolvedTags.json'
migration_module_name = 'updateOpenTSDBSkipUnresolvedTags'
migration_class_name = 'UpdateOpenTSDBSkipUnresolvedTags'

if __name__ == '__main__':
unittest.main()

0 comments on commit 05441fa

Please sign in to comment.