'Helper to make a dummy status log entry with custom rendered text.
Helpful when validating the logging since it lets the test control
the rendered text and so it doesn\'t depend on the exact formatting
of a "real" status log entry.
:param rendred_text: The value to return when rendering the entry.
:param start: An optional value indicating if this should be the start
of a nested group.
:param end: An optional value indicating if this should be the end
of a nested group.
:param subdir: An optional value to use for the entry subdir field.
:return: A dummy status log entry object with the given subdir field
and a render implementation that returns rendered_text.'

def make_dummy_entry(self, rendered_text, start=False, end=False, subdir=None):

    assert ((not start) or (not end))
    class dummy_entry(object, ):
        def is_start(self):
            return start
        def is_end(self):
            return end
        def render(self):
            return rendered_text
    entry = dummy_entry()
    entry.subdir = subdir
    return entry
