A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2008-July/081354.html below:

[Python-Dev] Unittest PEP do's and don'ts (BDFL pronouncement)

[Python-Dev] Unittest PEP do's and don'ts (BDFL pronouncement) [Python-Dev] Unittest PEP do's and don'ts (BDFL pronouncement)Nick Coghlan ncoghlan at gmail.com
Fri Jul 18 00:41:12 CEST 2008
Tres Seaver wrote:
> Ron Adam wrote:
>> Nick Coghlan wrote:
> 
>>> The essence of the function remains unchanged - you're still asserting 
>>> that a particular exception is raised. Returning the actual exception 
>>> object that was caught is merely a convenience that makes a lot of sense.
>> I'm not sure I understand...
> 
>> If "a particular exception is raised", every thing is good and there is no 
>> error to report.  ie... the code being tested did the right thing.
> 
> I *think* that in this case the propoent wants to be able to make
> further assertions about the raised exception (e.g., to test its message).

Exactly.

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia
---------------------------------------------------------------
             http://www.boredomandlaziness.org
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4