OK, between Alan and Martin I think that I see how to make the code
snippet actually test a *function* as the snippet seems to suggest.
Recollect that my original question(s) started:
On Sat, Apr 15, 2017 at 6:17 PM, boB Stepp wrote:
> In the section
>
>
Thank you very much Martin; you filled in a lot of details. I had an
overall understanding of what unittest does, but you have now enhanced
that understanding substantially. I'm still iffy on how the mixin
class gets its test method called when this class does not subclass
from
On Sat, Apr 15, 2017 at 9:33 AM, Rafael Knuth wrote:
> can anyone point me to good learning resources on this subject?
> (python 3)
I have been liking "Testing Python -- Applying Unit Testing, TDD, BDD,
and Acceptance Testing" by David Sale, c. 2014. If you are into
On 04/14/2017 04:21 AM, Peter Otten wrote:
> Stephen P. Molnar wrote:
>
>> However, what I want to do is multiply each element ob D by each element
>> of s and sum all of the products.
>
> If you *really* want this:
>
> sum_of_all_products = s.sum() * D.sum()
>
> example:
>
> s = [a b c]
>
> D =
On 04/16/2017 10:16 AM, Jim wrote:
> On 04/16/2017 10:10 AM, Chris Warrick wrote:
>> On 16 April 2017 at 16:45, Jim wrote:
>>> My system python is 2.7.12 so I created a virtual environment using
>>> venu to
>>> run 3.5.2. I put it in /home/jfb/EVs/env. Now I would like to
giacomo.bo...@gmail.com writes:
I throw two errors in my answer, see the inline corrections
> Possibility 1
>
> c = np.outer(D, s) # c has shape (i*j, k) as outer flattens its arguments
> c = sum(c, 1) # c has shape (i*j) because se summed over 2nd index
c = np.sum(c, 1) # c has shape
Greetings boB,
>2) The big question: What is the program flow for this program? I
>am not seeing the order of execution here. How is the unittest module
>handling the execution of this?
This is a very good question and one that was (at one time)
inobvious to me, as well.
When you write a
"Stephen P. Molnar" writes:
> I have an list generated by: s = np.linspace(start,finish,points)
>
> and an array D:
>
> [ 0. 2.0598013.60937686 3.32591826 2.81569212]
> [ 2.0598010. 4.71452879 4.45776445 4.00467382]
> [ 3.60937686
On 16/04/17 16:21, boB Stepp wrote:
> I did this and it indeed works. But how do I use this technique to
> unittest the given function? I am just not seeing how to do it with
> this with this mixin approach, and I have yet to study mixins, though
> apparently I have just now started!
I'm not
On 16 April 2017 at 18:16, Jim wrote:
> On 04/16/2017 10:10 AM, Chris Warrick wrote:
>>
>> On 16 April 2017 at 16:45, Jim wrote:
>>>
>>> My system python is 2.7.12 so I created a virtual environment using venu
>>> to
>>> run 3.5.2. I put it in
On 04/16/2017 10:10 AM, Chris Warrick wrote:
On 16 April 2017 at 16:45, Jim wrote:
My system python is 2.7.12 so I created a virtual environment using venu to
run 3.5.2. I put it in /home/jfb/EVs/env. Now I would like to try 3.6 and
put it in env36. Is it possible to
On Sat, Apr 15, 2017 at 6:31 PM, Alan Gauld via Tutor wrote:
> On 16/04/17 00:17, boB Stepp wrote:
>
>> --
>> #!/usr/bin/env python3
>>
>> def mySuperWhammyFunction(any_input):
>> return
On 16 April 2017 at 16:45, Jim wrote:
> My system python is 2.7.12 so I created a virtual environment using venu to
> run 3.5.2. I put it in /home/jfb/EVs/env. Now I would like to try 3.6 and
> put it in env36. Is it possible to change env to env35 for 3.5.2 without
>
My system python is 2.7.12 so I created a virtual environment using venu
to run 3.5.2. I put it in /home/jfb/EVs/env. Now I would like to try 3.6
and put it in env36. Is it possible to change env to env35 for 3.5.2
without breaking things?
Thanks, Jim
On 04/15/2017 08:33 AM, Rafael Knuth wrote:
> can anyone point me to good learning resources on this subject?
> (python 3)
> ___
> Tutor maillist - Tutor@python.org
> To unsubscribe or change subscription options:
>
On 16/04/17 03:18, Aaron Myatt via Tutor wrote:
> My favourite book on testing. It is a pretty thorough walk through of
> building a django app that helps you get a feel for the TDD work flow and
> red, green, refactor cycle. A rather more practical and real world
> applicable introduction to TDD,
My favourite book on testing. It is a pretty thorough walk through of
building a django app that helps you get a feel for the TDD work flow and
red, green, refactor cycle. A rather more practical and real world
applicable introduction to TDD, in my opinion.
On 16 Apr 2017 12:59 a.m., "Rafael
17 matches
Mail list logo