You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Create a virtual env in the project folder (we recommend this to avoid installing packages to your global environment). You can do this by running py -3 -m venv .venv (on windows), or python3 -m venv .venv (on linux/mac). Note: for nix/mac users you may have to install venv depending on your distribution.
Once you have the virtual env, select it using the Python: select interpreter command or from the status bar.
Now you have to configure tests using Python: configure tests... command from the command pallet, or go the test view and configure by using the test welcome view, or you can run tests to get a prompt to configure. Select pytest and follow the prompt.
Depending on the scenario you may either get a prompt to install pytest or the extension will install pytest for you. If for some reason it does not install for you or get the prompt (file a bug). But do install it manually using this command from a activated terminal (see the .venv in the prompt indicated it is activated)
You should see the tests in the test view. Run the tests.
Add your own test methods, or add another test file, the test UI should update accordingly.
The text was updated successfully, but these errors were encountered:
@greazer A friendly reminder to test this Test Plan Item. If you are busy with other stuff please let me know so that I can ask someone else to test. Thanks.
Refs: #15750
Complexity: 3
Create Issue
Requirements
"python.experiments.optInto": ["All"],
in your user settings. If you did not have it, add it and reload.Testing
pytest
code:test_<name>.py
.py -3 -m venv .venv
(on windows), orpython3 -m venv .venv
(on linux/mac). Note: for nix/mac users you may have to installvenv
depending on your distribution.Python: select interpreter
command or from the status bar.Python: configure tests...
command from the command pallet, or go the test view and configure by using the test welcome view, or you can run tests to get a prompt to configure. Selectpytest
and follow the prompt.pytest
or the extension will installpytest
for you. If for some reason it does not install for you or get the prompt (file a bug). But do install it manually using this command from a activated terminal (see the .venv in the prompt indicated it is activated)The text was updated successfully, but these errors were encountered: