From 6a28c2d175e5ce8b98439afa685625257def0690 Mon Sep 17 00:00:00 2001 From: Renato Alves Date: Sun, 13 Jul 2014 19:53:32 +0100 Subject: [PATCH] UnitTest - Alias for runSuccess * Use t() (given t = Task()) as an alias to t.runSuccess() --- test/basetest/task.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/basetest/task.py b/test/basetest/task.py index d2f93855c..0929814e8 100644 --- a/test/basetest/task.py +++ b/test/basetest/task.py @@ -58,6 +58,10 @@ class Task(object): txt = super(Task, self).__repr__() return "{0} running from {1}>".format(txt[:-1], self.datadir) + def __call__(self, *args, **kwargs): + "Alias to runSuccess" + return self.runSuccess(*args, **kwargs) + def bind_taskd_server(self, taskd): """Configure the present task client to talk to given taskd server