[docs] unittest documentation
artgoldberg at gmail.com
Wed Jan 31 10:26:04 EST 2018
The first example in the unittest documentation
https://docs.python.org/2/library/unittest.html) contains the comment:
# check that s.split fails when the separator is not a string
However, this comment does not correctly describe the code, and reflects
a common misconception about testing. More accurately, the comment
# check that s.split fails when the separator is an int
Test code to "check that s.split fails when the separator is not a
string" would need to test every type other than string, which is
impossible because the set of possible types is infinite.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the docs