Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.xs4all.nl!newsfeed3a.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.006 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'subject:error': 0.03; 'doctest': 0.09; 'indicates': 0.09; 'lawrence': 0.09; 'api': 0.11; 'cc:addr:python-list': 0.11; 'mostly': 0.14; 'thread': 0.14; 'changes': 0.15; '"assert",': 0.16; 'benefit.': 0.16; 'from:addr:pobox.com': 0.16; 'from:addr:skip': 0.16; 'nose': 0.16; 'pytest,': 0.16; 'subject:after': 0.16; 'subject:continue': 0.16; 'unfair': 0.16; 'folks': 0.16; 'sender:addr:gmail.com': 0.17; 'wrote:': 0.18; 'trying': 0.19; 'appears': 0.22; 'aug': 0.22; 'issue.': 0.22; 'tests': 0.22; 'cc:addr:python.org': 0.22; 'certainly': 0.24; 'either.': 0.24; 'skip': 0.24; 'stick': 0.24; 'mon,': 0.24; 'cc:2**0': 0.24; 'compiled': 0.26; 'header:In-Reply- To:1': 0.27; 'installed': 0.27; 'possibility': 0.29; 'statement': 0.30; 'message-id:@mail.gmail.com': 0.30; "i'm": 0.30; '(which': 0.31; 'code': 0.31; '25,': 0.31; 'assert': 0.31; 'base,': 0.31; 'bunch': 0.31; 'dated': 0.31; 'minor': 0.31; 'run': 0.32; 'cases': 0.33; 'actual': 0.34; 'subject:from': 0.34; 'problem': 0.35; 'something': 0.35; 'test': 0.35; 'but': 0.35; 'received:google.com': 0.35; 'there': 0.35; 'replies': 0.36; 'subject:?': 0.36; 'unit': 0.37; 'list': 0.37; 'others.': 0.38; 'requiring': 0.38; 'pm,': 0.38; 'realize': 0.39; 'changed': 0.39; 'even': 0.60; 'skip:u 10': 0.60; 'gone': 0.61; 'you.': 0.62; 'more': 0.64; 'different': 0.65; '(that': 0.65; 'latest': 0.67; 'wish': 0.70; 'obvious': 0.74; 'lack': 0.78; 'plugins': 0.84; 'presumably': 0.84; 'to:addr:yahoo.co.uk': 0.84; 'try.': 0.91 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=yspxOylt1coeUyW0JD541i8Um0Fqg5RTEpur26LL1nA=; b=wKZdQhQEvzJU6gjdRNIWMJ+fvEVWln8fhGwUh2gnP1HNV0sGVJPTdIyfw+TuWgao7g QYXEGQFoQPLI03whexgjy59SCiPLgSJcHcc7nM7r1M7t4q6th6GOlR+MR7Ho4Bw+bAlA E+vs+8Eciz4KwCe0dIRjdq45nKbuIc56rGCy9jhj+UbiBTLAfo2BL+tZ5gblvWWXyWCx cvFIoliWrUZbZ8oK4OM3qI9APYaq+8i+XnKbPCoexdv3dC5mHYoIt2R1SIHER/ozHCIn py9Bg29RDcPzzrVN3yWeJbQtWMQiz+0DJjBgso1eGXj+teutPEe0Ky49SZoqp9gDVxWk u37A== MIME-Version: 1.0 X-Received: by 10.50.78.167 with SMTP id c7mr17500538igx.6.1408996490348; Mon, 25 Aug 2014 12:54:50 -0700 (PDT) Sender: skip.montanaro@gmail.com In-Reply-To: References: Date: Mon, 25 Aug 2014 14:54:50 -0500 X-Google-Sender-Auth: qmYzULBSXh5VgXgvixK1S4nmilI Subject: Re: Switching from nose to unittest2 - how to continue after an error? From: Skip Montanaro To: Mark Lawrence Content-Type: text/plain; charset=UTF-8 Cc: Python X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 27 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1408996493 news.xs4all.nl 2959 [2001:888:2000:d::a6]:42727 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:77000 On Mon, Aug 25, 2014 at 1:59 PM, Mark Lawrence wrote: > If you wish to write tests using something that can be compiled out please > don't let me stop you. Having said that if nose or even nose2 works for you > why not stick with it? There's also testfixtures, pytest, doctest and > presumably others. Horses for courses? The test cases are run independently of the actual installed code base, so use of the assert statement is, at best, a minor issue. We don't use -O where I work either. Certainly, for me, the possibility that code might get compiled out was outweighed by its convenience. The nose folks say nose v1 will no longer be extended, that nose2 is the future. Alas, the API changed for plugins (which I'm currently trying unsuccessfully to get working). A couple questions to that list have so far gone unanswered (granted one of them was today), and before my questions, the latest thread with any replies was dated Aug 6. (That indicates to me that the nose group is pretty quiet.) Seeing that nose2 was mostly unittest2 and no longer having any <2.7 constraint, I thought I would give it a try. Unfortunately, from my perspective it appears that the authors of that package mostly came up with a bunch of different spellings of "assert", requiring a bunch of tedious unit test changes for no obvious benefit. I realize that is almost certainly an unfair criticism, that there is more under the covers, but the lack of support for the assert statement is a problem for me. Skip