[Python-Dev] Proposal for Python 3.3: dependence injection
Michael Foord
fuzzyman at voidspace.org.uk
Thu Mar 24 20:04:21 CET 2011
On 24/03/2011 17:46, Andrew McNabb wrote:
> On Thu, Mar 24, 2011 at 10:12:18AM -0700, Guido van Rossum wrote:
>> On Thu, Mar 24, 2011 at 9:46 AM, Benjamin Peterson<benjamin at python.org> wrote:
>>>> I want to test the dev community interest in modifying the stdlib to
>>>> ease dependence injection.
>>> I, for one, am -1. Code shouldn't be uglified for the purposes of
>>> testing.
>> Well, the philosophy of dependency injection requires exactly that.
>> Personally I am on the fence; I've seen is used effectively but I've
>> also seen code, indeed, uglified with little benefits. (Same for other
>> extreme testing practices like TDD.)
> I agree with the comments about uglification, but testing was only one
> of the use cases that Jesus provided. He also mentioned using
> alternative network implementations, integrating with event loops, etc.
> Another use case that I've run into before is setting socket options.
And some of the use cases for this seemed pretty good from the email
thread he linked to.
Michael
> --
> Andrew McNabb
> http://www.mcnabbs.org/andrew/
> PGP Fingerprint: 8A17 B57C 6879 1863 DE55 8012 AB4D 6098 8826 6868
> _______________________________________________
> Python-Dev mailing list
> Python-Dev at python.org
> http://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: http://mail.python.org/mailman/options/python-dev/fuzzyman%40voidspace.org.uk
--
http://www.voidspace.org.uk/
May you do good and not evil
May you find forgiveness for yourself and forgive others
May you share freely, never taking more than you give.
-- the sqlite blessing http://www.sqlite.org/different.html
More information about the Python-Dev
mailing list