testtools-dev team mailing list archive
-
testtools-dev team
-
Mailing list archive
-
Message #00107
[Bug 657780] [NEW] Per-test decorator syntax for test runner
Public bug reported:
It would be really nice to be able to specify a test runner (e.g.
RunTest) on a per-test basis using decorator syntax. That way tests
with special running needs would not have to be split into separate
classes. Ideally, this would not require the use of a special loader.
e.g.
{{{
class TestFoo(TestCase):
def test_normal(self):
pass
@use_runner(DeferredRunTest)
def test_deferred(self):
return defer.succeed(None)
}}}
Spelling can vary.
** Affects: testtools
Importance: Undecided
Status: New
--
Per-test decorator syntax for test runner
https://bugs.launchpad.net/bugs/657780
You received this bug notification because you are a member of testtools
developers, which is subscribed to testtools.
Status in testtools: New
Bug description:
It would be really nice to be able to specify a test runner (e.g. RunTest) on a per-test basis using decorator syntax. That way tests with special running needs would not have to be split into separate classes. Ideally, this would not require the use of a special loader.
e.g.
{{{
class TestFoo(TestCase):
def test_normal(self):
pass
@use_runner(DeferredRunTest)
def test_deferred(self):
return defer.succeed(None)
}}}
Spelling can vary.
Follow ups
References