[SciPy-dev] new weave tar balls -- multiple fixes
Prabhu Ramachandran
prabhu at aero.iitm.ernet.in
Mon Jan 14 12:00:28 EST 2002
>>>>> "eric" == eric <eric at scipy.org> writes:
>> The test doesnt seem to have failed either. Also maybe you can
>> use
>>
>> self.assertRaises(except_type, func, args)
>>
>> for the exception tests?
eric> We could -- is there a particular benefit? I haven't look
Smaller code. Its easier writing something like this
self.assertRaises(AssertionError, func, arg1, arg2)
instead of:
try:
func(arg1, arg2)
except AssertionError:
pass
else:
raise AssertionError, \
"Test should have raised an exception." # or something
You could look at the em_viz tests or the gui_thread tests (there is
only one of these in gui_thread though) for concrete examples.
eric> at this at all, and am unlikely to run through all the tests
eric> to make the changes now. :) But maybe for future tests.
Sure, I was just suggesting. And this is useful only when you want to
make sure that something raises an error.
prabhu
More information about the SciPy-Dev
mailing list