[MERGE][bug #125784] Don't suppress original errors when .unlock() fails
Vincent Ladeuil
v.ladeuil+lp at free.fr
Tue Jun 17 16:44:32 BST 2008
>>>>> "john" == John Arbash Meinel <john at arbash-meinel.com> writes:
<snip/>
>> def load_tests(standard_tests, module, loader):
>> """Parameterize the test for tempfile creation with different
>> encodings."""
>> to_adapt, result = split_suite_by_re(standard_tests,
>> "test__create_temp_file_with_commit_template_in_unicode_dir")
>> for test in iter_suite_tests(to_adapt):
>> result.addTests(EncodingTestAdapter().adapt(test))
>> return result
>>
>> Thats an example of multiplying a *single* test in a test class.
>>
>> I don't think it really gets much simpler - I consider this an example
>> of well done adaption (except that the scenario and adapter are mixed
>> here - but the rest is about ideal).
>>
>> Rob
john> That doesn't address writing the adapter, and all of
john> the helper code involved in that. (You have
john> "EncodingTestAdapter" secretly brought into the
john> situation.)
I think the point is that EncodingTestAdapter is only a dict. The
only defined function could be avoided by inheriting from
TestScenarioApplier.
Vincent
More information about the bazaar
mailing list