Ejemplo n.º 1
0
    def test_should_print_pipeline(self):
        printer = PipelinePrinter()
        name, kind = 'test-x', 'TestX'

        part = LoggerParts.Pipeline(name, kind)
        output = printer.flush(colors=False, pipeline=part)

        assert output.find(name) != -1
        assert output.find(kind) != -1
        assert re.search(self.COLOR_REGEXP, output) is None
Ejemplo n.º 2
0
    def test_should_ignore_extra_arguments(self):
        printer = PipelinePrinter()
        name, kind = 'test-x', 'TestX'

        part = LoggerParts.Pipeline(name, kind)
        output_base = printer.flush(colors=False, pipeline=part)
        output_extra = printer.flush(colors=False,
                                     pipeline=part,
                                     extra=[1, 2, 3])

        assert output_base == output_extra