# Path: crmsh/crash_test/utils.py
# CRED = '\033[31m'
# CYELLOW = '\033[33m'
# CGREEN = '\033[32m'
# CEND = '\033[0m'
# LEVEL = {
#     "info": logging.INFO,
#     "warn": logging.WARNING,
#     "error": logging.ERROR
# }
#     FORMAT_FLUSH = "[%(asctime)s]%(levelname)s: %(message)s"
#     FORMAT_NOFLUSH = "%(timestamp)s%(levelname)s: %(message)s"
#     COLORS = {
#         'WARNING': CYELLOW,
#         'INFO': CGREEN,
#         'ERROR': CRED
#     }
# class MyLoggingFormatter(logging.Formatter):
# class FenceInfo(object):
#     def __init__(self, flush=True):
#     def format(self, record):
# def now(form="%Y/%m/%d %H:%M:%S"):
# def manage_handler(_type, keep=True):
# def msg_raw(level, msg, to_stdout=True):
# def msg_info(msg, to_stdout=True):
# def msg_warn(msg, to_stdout=True):
# def msg_error(msg, to_stdout=True):
# def json_dumps():
#     def fence_enabled(self):
#     def fence_action(self):
#     def fence_timeout(self):
# def check_node_status(node, state):
# def online_nodes():
# def peer_node_list():
# def this_node():
# def str_to_datetime(str_time, fmt):
# def corosync_port_list():
# def get_handler(logger, _type):
# def is_root():
# def get_process_status(s):
# def _find_match_count(str1, str2):
# def is_valid_sbd(dev):
# def find_candidate_sbd(dev):
# def warning_ask(warn_string):
# 
# Path: crmsh/crash_test/main.py
# class Context(object):
# class MyArgParseFormatter(RawDescriptionHelpFormatter):
#     def __init__(self):
#     def __setattr__(self, name, value):
# def kill_process(context):
# def split_brain(context):
# def fence_node(context):
#     def __init__(self, prog):
# def parse_argument(context):
# def setup_basic_context(context):
# def run(context):


import os
import sys
    import mock
import logging
    from unittest import mock, TestCase
from crmsh.crash_test import utils, main, config
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), '../..')))

try:
except ImportError:



class TestMyLoggingFormatter(TestCase):

    @classmethod
    def setUpClass(cls):
        """
        Global setUp.
        """

    def setUp(self):
        """
        Test setUp.
        """

# Path: crmsh/crash_test/utils.py
# CRED = '\033[31m'
# CYELLOW = '\033[33m'
# CGREEN = '\033[32m'
# CEND = '\033[0m'
# LEVEL = {
#     "info": logging.INFO,
#     "warn": logging.WARNING,
#     "error": logging.ERROR
# }
#     FORMAT_FLUSH = "[%(asctime)s]%(levelname)s: %(message)s"
#     FORMAT_NOFLUSH = "%(timestamp)s%(levelname)s: %(message)s"
#     COLORS = {
#         'WARNING': CYELLOW,
#         'INFO': CGREEN,
#         'ERROR': CRED
#     }
# class MyLoggingFormatter(logging.Formatter):
# class FenceInfo(object):
#     def __init__(self, flush=True):
#     def format(self, record):
# def now(form="%Y/%m/%d %H:%M:%S"):
# def manage_handler(_type, keep=True):
# def msg_raw(level, msg, to_stdout=True):
# def msg_info(msg, to_stdout=True):
# def msg_warn(msg, to_stdout=True):
# def msg_error(msg, to_stdout=True):
# def json_dumps():
#     def fence_enabled(self):
#     def fence_action(self):
#     def fence_timeout(self):
# def check_node_status(node, state):
# def online_nodes():
# def peer_node_list():
# def this_node():
# def str_to_datetime(str_time, fmt):
# def corosync_port_list():
# def get_handler(logger, _type):
# def is_root():
# def get_process_status(s):
# def _find_match_count(str1, str2):
# def is_valid_sbd(dev):
# def find_candidate_sbd(dev):
# def warning_ask(warn_string):
# 
# Path: crmsh/crash_test/main.py
# class Context(object):
# class MyArgParseFormatter(RawDescriptionHelpFormatter):
#     def __init__(self):
#     def __setattr__(self, name, value):
# def kill_process(context):
# def split_brain(context):
# def fence_node(context):
#     def __init__(self, prog):
# def parse_argument(context):
# def setup_basic_context(context):
# def run(context):


# Path: test/unittests/test_crashtest_utils.py
import os
import sys
    import mock
import logging
    from unittest import mock, TestCase
from crmsh.crash_test import utils, main, config

sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), '../..')))

try:
except ImportError:



class TestMyLoggingFormatter(TestCase):

    @classmethod
    def setUpClass(cls):
        """
        Global setUp.
        """

    def setUp(self):
        """
        Test setUp.
        """

        self.fence_info_inst = utils.FenceInfo()