typeddjango / pytest-mypy-plugins

pytest plugin for testing mypy types, stubs, and plugins
https://pypi.org/project/pytest-mypy-plugins/
MIT License
102 stars 24 forks source link

Improve error message when parsing tests #29

Open sobolevn opened 4 years ago

sobolevn commented 4 years ago

Currently, when parsing error happens, you will end up with something like this:

  File "/Users/sobolev/Documents/github/returns/.venv/lib/python3.7/site-packages/pytest_mypy_plugins/utils.py", line 256, in assert_string_arrays_equal
    lineno = int(first_failure.split(" ")[0].strip(":").split(":")[1])
IndexError: list index out of range

We need to improve it!