Esempio n. 1
0
    def __init__(self, output=sys.stdout):
        """
        Initiate the the base reporter.

        @param output: output stream
        """
        BaseReporter.__init__(self, output)
Esempio n. 2
0
    def __init__(self, output=sys.stdout):
        """
        Initiate the the base reporter.

        @param output: output stream
        """
        BaseReporter.__init__(self, output)
Esempio n. 3
0
    def set_output(self, output=None):
        """set output stream

        messages buffered for old output is processed first"""
        if self.out and self.msgs:
            self._display(Section())
        BaseReporter.set_output(self, output)
Esempio n. 4
0
    def set_output(self, output=None):
        """set output stream

        messages buffered for old output is processed first"""
        if self.out and self.msgs:
            self._display(Section())
        BaseReporter.set_output(self, output)
Esempio n. 5
0
 def __init__(self, message_store, filters, finder, targets):
     BaseReporter.__init__(self, output=None)
     self._message_store = message_store
     self._filters = compile_masks(filters)
     self._targets = targets
     self._finder = finder
     self._all_files = list(finder.files(filters=filters))
     self._tidypy_issues = []
def test_deprecation_set_output(recwarn):
    """TODO remove in 3.0."""
    reporter = BaseReporter()
    # noinspection PyDeprecation
    reporter.set_output(sys.stdout)
    warning = recwarn.pop()
    assert "set_output' will be removed in 3.0" in str(warning)
    assert reporter.out == sys.stdout
Esempio n. 7
0
    def __init__(self, output=sys.stdout):
        BaseReporter.__init__(self, output)
        self.msgs = []
        # Add placeholders for title and parsed messages
        self.header = None
        self.msgargs = []

        warnings.warn("This reporter will be removed in Pylint 2.0.",
                      DeprecationWarning)
Esempio n. 8
0
    def __init__(self, output=sys.stdout):
        BaseReporter.__init__(self, output)

        def _default(module_name):
            return junit_types.ModuleErrors(
                module_name=module_name,
                pylint_error_list=list(),
            )

        self._messages = _KeyDefaultDict(_default)
Esempio n. 9
0
    def test_add_message_is_deprecated(self):
        if __pkginfo__.numversion > (1, 6, 0):
            with self.assertRaises(AttributeError):
                BaseReporter().add_message

        with warnings.catch_warnings(record=True) as cm:
            warnings.simplefilter("always")
            BaseReporter().add_message(None, None, None)

        self.assertEqual(len(cm), 1)
        self.assertIsInstance(cm[0].message, DeprecationWarning)
        msg = ('This method is deprecated, use handle_message '
               'instead. It will be removed in Pylint 1.6.')
        self.assertEqual(str(cm[0].message), msg)
Esempio n. 10
0
 def __init__(self, gui, output=sys.stdout):
     """init"""
     BaseReporter.__init__(self, output)
     self.gui = gui
Esempio n. 11
0
File: xtdlint.py Progetto: Anvil/xtd
 def __init__(self, linter, output=None):
   BaseReporter.__init__(self, output)
   self.m_linter = linter
   self.m_data   = {}
Esempio n. 12
0
 def __init__(self, output=None):
     BaseReporter.__init__(self, output)
     self.current_module = None
     self.data = []
Esempio n. 13
0
 def __init__(self, output=None):
     BaseReporter.__init__(self, output)
     self._modules = set()
     self._template = None
Esempio n. 14
0
 def __init__(self, message_store):
     BaseReporter.__init__(self, output=None)
     self._message_store = message_store
     self._messages = []
Esempio n. 15
0
 def __init__(self, output=sys.stdout):
     BaseReporter.__init__(self, output)
     self.msgs = []
     # Add placeholders for title and parsed messages
     self.header = None
     self.msgargs = []
Esempio n. 16
0
 def __init__(self, output=sys.stdout):
     BaseReporter.__init__(self, output)
     self.items = {}
     self.current_module = None
     self.current_filepath = None
Esempio n. 17
0
 def __init__(self, message_store):
     BaseReporter.__init__(self, output=None)
     self._message_store = message_store
     self._messages = []
Esempio n. 18
0
 def __init__(self, output=None):
     BaseReporter.__init__(self, output)
     self.current_module = None
     self.data = []
Esempio n. 19
0
 def __init__(self, output=None):
     BaseReporter.__init__(self, output)
     self.data = []
Esempio n. 20
0
File: text.py Progetto: DINKIN/XDM
 def __init__(self, output=None):
     BaseReporter.__init__(self, output)
     self._modules = {}
Esempio n. 21
0
 def __init__(self, output=sys.stdout):
     BaseReporter.__init__(self, output)
     self.messages = []
Esempio n. 22
0
 def __init__(self, output=sys.stdout):
     BaseReporter.__init__(self, output)
     self.messages = []
Esempio n. 23
0
 def __init__(self, output=None):
     BaseReporter.__init__(self, output)
     self._modules = set()
     self._template = None
Esempio n. 24
0
 def __init__(self, output=None):
     BaseReporter.__init__(self, output)
     self._modules = {}
Esempio n. 25
0
 def __init__(self, output=sys.stdout):
     BaseReporter.__init__(self, output)
     self.msgs = []
     # Add placeholders for title and parsed messages
     self.header = None
     self.msgargs = []
Esempio n. 26
0
 def __init__(self, output=sys.stdout):
     BaseReporter.__init__(self, output)
     self.root_node = Element('pmd')
     self.file_nodes = {}
 def __init__(self, output=None):
     BaseReporter.__init__(self, output)
Esempio n. 28
0
 def __init__(self, linter, output=None):
     BaseReporter.__init__(self, output)
     self.m_linter = linter
     self.m_data = {}
Esempio n. 29
0
 def __init__(self, output=sys.stdout):
     BaseReporter.__init__(self, output)
     self._modules = {}
Esempio n. 30
0
 def __init__(self, gui, output=sys.stdout):
     """init"""
     BaseReporter.__init__(self, output)
     self.msgs = []
     self.gui = gui
Esempio n. 31
0
 def __init__(self, output=sys.stdout):
     BaseReporter.__init__(self, output)
     self._modules = {}
Esempio n. 32
0
 def __init__(self, root, output=sys.stdout):
     BaseReporter.__init__(self, output)
     # messages is in the following format:
     # filepath : { msgid : [ (lineno, msg) ] }
     self.root = root
     self.messages = defaultdict(lambda : defaultdict(list))
Esempio n. 33
0
 def __init__(self):
     BaseReporter.__init__(self, output=None)
     self._messages = []