I'm new to VScode coming from PHPStorm only cause Github Copilot chat is better than PHPStorm. I'm having trouble setting up PHPUnit Test Explorer for VSCode. I always get this annoying error:
It works perfectly fine in PHPStorm and in VScode in the terminal (bash) when I run the command "./vendor/bin/phpunit --filter testSomeTestFunction". I'm trying to run my tests like in PHPStorm it's just the way I'm used to it.
My setup is Laravel Homestead/vagrant. I have PHP installed in my Windows 10 machine in: C:\php82
and my current project has a "server" directory where Laravel application is in.
This is my current VScode settings.json file:
{ "editor.inlineSuggest.suppressSuggestions": true, "files.autoSave": "afterDelay", "phpunit.php": "C:\\php82\\php.exe", "terminal.integrated.defaultProfile.windows": "Git Bash", "editor.fontLigatures": true, "editor.fontSize": 13, "editor.lineHeight": 1.2, "[php]": {}, "php.executablePath": "C:\\php82\\php.exe", "phpunit.clearOutputOnRun": true, "intelephense.environment.phpVersion": "8.1", "phpunit.paths": { "c:/Users/User/code/myproject/server": "./vendor/bin" } } My projects are in the typical "code" directory. If you need more info, definitely let me know.
Источник: https://stackoverflow.com/questions/780 ... for-vscode