kondratyev-nv / vscode-python-test-adapter

Python Test Adapter for the VS Code Test Explorer
https://marketplace.visualstudio.com/items?itemName=LittleFoxTeam.vscode-python-test-adapter
MIT License
117 stars 27 forks source link

launch.json: "envFile" configuration seems to need '.test' suffix amended to the filepath #312

Open lks-dev opened 1 month ago

lks-dev commented 1 month ago

tl:dr: "envFile": "env/file/path.test" works as expected "envFile": "env/file/path" does not, even though there is no version of the file on the filesystem ending with a ".test" suffix.

On Setting up pytest with an pytest.ini config in the source file, configuring coverage, i needed to a debug launch config setup used by the python-test-adapter extension to add the pytest addopts: '--no-cov' for debugging. The needed environment manipulations in in the .env file even though I had explicitly given the "envFile":"env/file/path" as a parameter in the launch config did not take effect. After some time playing with the example given on the overview page on the marketplace, I added the ".test" suffix to the filepath of my .env file resolving the issue for the me.

As there is no file called "env/file/path.test" on my file system i would consider this a bug or, if it is a in some circles popular convention, something worth explaining on the overview section regarding the launch config.