[Tutor] Problem with testing - container

Albert-Jan Roskam sjeik_appie at hotmail.com
Thu Mar 29 15:50:55 EDT 2018


Op 29 mrt. 2018 21:06 schreef "Shall, Sydney" <sydney.shall at kcl.ac.uk>:
>
> I have a problem with a specific test, I think.
>
> I use a Mac with OS X 10.13.3
> I use Anaconda with Python 3.5
>
> I have been writing tests for a Class that I have written. I am not
> finished yet, but there are already nearly 400 tests. The tests run and
> return OK. [After cleaning up many silly mistakes that I made.]
>
> However, now, when I run the tests (Unittest) I get the following warning:
> ....
> lib/python3.5/unittest/case.py:1092: FutureWarning: elementwise
> comparison failed; returning scalar instead, but in the future will
> perform elementwise comparison
>    if member in container:
> ...
>
> No other information is given.
>
> My problem is, how do I find out where exactly the problem originates.
> --

Try running Python with the option '-W error', or set PYTHONWARNINGS to 'error'. https://docs.python.org/2/using/cmdline.html#envvar-PYTHONWARNINGS


More information about the Tutor mailing list