'Return a L{Todo} object if the test is marked todo. Checks on the
instance first, then the class, then the module, then packages. As
soon as it finds something with a C{todo} attribute, returns that.
Returns L{None} if it cannot find anything. See L{TestCase} docstring
for more details.'

def getTodo(self):

    todo = util.acquireAttribute(self._parents, 'todo', None)
    if (todo is None):
        return None
    return makeTodo(todo)
