使用Python 带的Pytest 运行时报错:
pytest test.py
zsh: /Library/Frameworks/Python.framework/Versions/3.8/bin/pytest: bad interpreter: /usr/local/bin/python3: no such file or directory
搜了好多文章,说是格式问题。搜了好多也不行。(可能我没搜到吧)
后来直接吧Pytest 删除重新装了一下。
成功运行!!!果然最简单的方法就是重装~
原因:感觉应该是我换Python版本 时候导致的问题。