← Back to team overview

testtools-dev team mailing list archive

Re: [Merge] lp:~jml/testtools/run-test-improvements into lp:testtools

 

A few thoughts.

The decorator is hard to read. What is 'f'? Why is make_test_runner an
inner method (its not a closure)?

A comment saying what it what it does ('sets an attribute on the
method to run') would address this.

Secondly, I don't think setting an attribute on the method to run is
wise: it won't survive multiple decorators:

@foo
@run_test_with(..)
def test_foo()

will use the default test runner. Setting the attribute on the object
not the method will work even though it requires more work.

If you don't think this is important, thats ok, we can iterate to
improve, but needing a specific decorator order will surprise people,
I think.

-Rob
-- 
https://code.launchpad.net/~jml/testtools/run-test-improvements/+merge/38659
Your team testtools developers is requested to review the proposed merge of lp:~jml/testtools/run-test-improvements into lp:testtools.



References