Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #89825
| From | Paul Rubin <no.email@nospam.invalid> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: Is this a good way to implement testing |
| Date | 2015-05-02 20:58 -0700 |
| Organization | A noiseless patient Spider |
| Message-ID | <87k2wq2tx8.fsf@jester.gateway.sonic.net> (permalink) |
| References | <878ud6mx4y.fsf@Equus.decebal.nl> |
Cecil Westerhof <Cecil@decebal.nl> writes: > Still on my journey to learn Python. > > At the moment I define the test functionality in the following way: > action = options[0][0] > if action == '--all': ... Yecch, use an option parsing library for that, whichever one is currently fashionable. I think optparse is deprecated now but I still use it because I'm used to it. > Is this an acceptable way of working? You should also use the currently fashionable unit testing library. I use unittest because yada yada but I think it's now considered old school.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Is this a good way to implement testing Cecil Westerhof <Cecil@decebal.nl> - 2015-05-03 00:29 +0200
Re: Is this a good way to implement testing Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-05-03 00:17 +0100
Re: Is this a good way to implement testing Terry Reedy <tjreedy@udel.edu> - 2015-05-02 20:06 -0400
Re: Is this a good way to implement testing Paul Rubin <no.email@nospam.invalid> - 2015-05-02 20:58 -0700
Re: Is this a good way to implement testing Ben Finney <ben+python@benfinney.id.au> - 2015-05-03 14:49 +1000
Re: Is this a good way to implement testing Cecil Westerhof <Cecil@decebal.nl> - 2015-05-03 09:36 +0200
Re: Is this a good way to implement testing Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-05-03 09:38 +0100
Re: Is this a good way to implement testing Peter Otten <__peter__@web.de> - 2015-05-03 10:45 +0200
Re: Is this a good way to implement testing Cecil Westerhof <Cecil@decebal.nl> - 2015-05-03 11:49 +0200
Re: Is this a good way to implement testing Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-05-03 11:21 +0100
Re: Is this a good way to implement testing Cecil Westerhof <Cecil@decebal.nl> - 2015-05-03 12:50 +0200
Re: Is this a good way to implement testing Ben Finney <ben+python@benfinney.id.au> - 2015-05-03 18:52 +1000
Re: Is this a good way to implement testing Peter Otten <__peter__@web.de> - 2015-05-03 11:22 +0200
csiph-web