kaste / PyTest

pytest runner and view annotator for sublime text
21 stars 6 forks source link

How to configure pytest in sublime to run pytest with sublime #19

Open yuzhujiutian opened 5 years ago

yuzhujiutian commented 5 years ago

I like sublime, so i want to use sublime instead of pycharm.

How to configure pytest in sublime to run pytest with sublime?

pytest version

image

python build setting (sublime -> Tools -> New Build System...) image

image

kaste commented 5 years ago

You probably set the pytest key. Ref: https://github.com/kaste/PyTest#config

  "pytest": "D:\\heloc\\...\\Scripts\\py.test.exe"

either globally or per project.

I don't know pipenv good enough but something like ["pipenv", "run", "python", "-m", "pytest"] could also work and would be more generic. (But maybe also slower?)