commit eb3f925af7baeeee8330e610797337aaf7423ee0 Author: Arturo Filastò hellais@torproject.org Date: Thu May 31 15:56:53 2012 +0200
Rename TwistedTest to OONITest --- ooni/plugins/blocking.py | 4 ++-- ooni/plugins/httphost.py | 4 ++-- ooni/plugins/skel.py | 4 ++-- ooni/plugoo/tests.py | 4 ++-- ooni/scaffolding.py | 4 ++-- 5 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/ooni/plugins/blocking.py b/ooni/plugins/blocking.py index 4638834..b6b63b6 100644 --- a/ooni/plugins/blocking.py +++ b/ooni/plugins/blocking.py @@ -3,14 +3,14 @@ from twisted.python import usage from twisted.plugin import IPlugin
from ooni.plugoo.assets import Asset -from ooni.plugoo.tests import ITest, TwistedTest +from ooni.plugoo.tests import ITest, OONITest
class BlockingArgs(usage.Options): optParameters = [['asset', 'a', None, 'Asset file'], ['resume', 'r', 0, 'Resume at this index'], ['shit', 'o', None, 'Other arguments']]
-class BlockingTest(TwistedTest): +class BlockingTest(OONITest): implements(IPlugin, ITest)
shortName = "blocking" diff --git a/ooni/plugins/httphost.py b/ooni/plugins/httphost.py index 9b4de22..2c7f8af 100644 --- a/ooni/plugins/httphost.py +++ b/ooni/plugins/httphost.py @@ -19,7 +19,7 @@ from twisted.python import usage from twisted.plugin import IPlugin
from ooni.plugoo.assets import Asset -from ooni.plugoo.tests import ITest, TwistedTest +from ooni.plugoo.tests import ITest, OONITest
class HTTPHostArgs(usage.Options): optParameters = [['asset', 'a', None, 'Asset file'], @@ -49,7 +49,7 @@ class HTTPHostAsset(Asset): return line.split(',')[1].replace('\n','')
-class HTTPHostTest(TwistedTest): +class HTTPHostTest(OONITest): implements(IPlugin, ITest)
shortName = "httphost" diff --git a/ooni/plugins/skel.py b/ooni/plugins/skel.py index c5eec47..de95b48 100644 --- a/ooni/plugins/skel.py +++ b/ooni/plugins/skel.py @@ -1,7 +1,7 @@ from zope.interface import implements from twisted.python import usage from twisted.plugin import IPlugin -from plugoo.tests import ITest, TwistedTest +from plugoo.tests import ITest, OONITest from ooni import log
class SkelArgs(usage.Options): @@ -9,7 +9,7 @@ class SkelArgs(usage.Options): ['resume', 'r', 0, 'Resume at this index'], ['other', 'o', None, 'Other arguments']]
-class SkelTest(TwistedTest): +class SkelTest(OONITest): implements(IPlugin, ITest)
shortName = "skeleton" diff --git a/ooni/plugoo/tests.py b/ooni/plugoo/tests.py index 3f63476..7bb2321 100644 --- a/ooni/plugoo/tests.py +++ b/ooni/plugoo/tests.py @@ -16,7 +16,7 @@ from ooni.plugoo.reports import Report from ooni.plugoo.interface import ITest
-class TwistedTest(object): +class OONITest(object): blocking = False
def __init__(self, local_options, global_options, report, ooninet=None): @@ -34,7 +34,7 @@ class TwistedTest(object): return {'asset': None}
def __repr__(self): - return "<TwistedTest %s %s %s>" % (self.options, self.global_options, + return "<OONITest %s %s %s>" % (self.options, self.global_options, self.assets)
def finished(self, control): diff --git a/ooni/scaffolding.py b/ooni/scaffolding.py index b1d3f59..9004754 100755 --- a/ooni/scaffolding.py +++ b/ooni/scaffolding.py @@ -15,13 +15,13 @@ Safe hacking :). from zope.interface import implements from twisted.python import usage from twisted.plugin import IPlugin -from plugoo.tests import ITest, TwistedTest +from plugoo.tests import ITest, OONITest
class %(testName)sArgs(usage.Options): optParameters = [['asset', 'a', None, 'Asset file'], ['resume', 'r', 0, 'Resume at this index']]
-class %(testName)sTest(TwistedTest): +class %(testName)sTest(OONITest): implements(IPlugin, ITest)
shortName = "%(testShortname)s"