Comments (7)
Try an absolute path. ENOENT means the file doesn't exist. In my case I had the wrong file extension.
from vscode-phpunit.
Any news on this issue? I'm running into the same problems as the others in this thread.
I've written an absolute path to phpunit.bat and it appears it's correct, as I now get this message, which is the content of the phpunit.bat file.
"@echo OFF
setlocal DISABLEDELAYEDEXPANSION
SET BIN_TARGET=%~dp0/../phpunit/phpunit/phpunit
php "%BIN_TARGET%" %*
"
I'm using Laravel.
I'm not sure what else I can try to figure it out.
I'd really like to get this working. The Test explorer is super cool, but tests can't run. I'm stuck with running them manually from Powershell.
Thanks!
from vscode-phpunit.
I had the same issue. For me I opened in vscode
Settings -> Extensions -> PHPUnit Configuration
About 8 settings down there is "Phpunit: Phpunit" Path to phpunit.
Setting this fixed my issue.
from vscode-phpunit.
Dosn't work for me.
I have set the following setting:
"phpunit.phpunit": "${workspaceFolder}\vendor\bin\phpunit",
I use Laravel Framework and the phpunit executable exists in bin/phpunit
This is the message in PHPUnit LanguageServer window now:
spawn ${workspaceFolder}\vendor\bin\phpunit ENOENT
from vscode-phpunit.
I'm rewriting this project now, it will fix this issue at next version
from vscode-phpunit.
Thanks @recca0120 do you have any ETA about this?
At least a suggestion on how I should set the phpunit.phpunit
value since it seems to be broken. My vendor
directory is in app/vendor
and I couldn't set a proper relative path. None of these worked.
"phpunit.phpunit": "app/vendor/bin/phpunit" <-- It should search for phpunit OR phpunit.bat
"phpunit.phpunit": "app/vendor/bin/phpunit.bat"
"phpunit.phpunit": "${workspaceFolder}/app/vendor/bin/phpunit"
"phpunit.phpunit": "${workspaceFolder}/app/vendor/bin/phpunit.bat"
"phpunit.phpunit": "${workspaceFolder}\\app\\vendor\\bin\\phpunit"
"phpunit.phpunit": "${workspaceFolder}\\app\\vendor\\bin\\phpunit.bat"
I always get:
spawn \${workspaceFolder}\app\vendor\bin\phpunit.bat ENOENT
Please notice it prepends a \
and it doesn't seem to resolve ${workspaceFolder}.
For now I'm using an absolute path but I want to really really really want to avoid that. It breaks multiplatform compatibility and - heck - it even breaks my PC at home if I ever wanted to commit the .vscode
directory.
"phpunit.phpunit": "C:\\Users\\User\\my-project\\app\\vendor\\bin\\phpunit.bat",
Thanks.
PS. It think this is a duplicate of #39
from vscode-phpunit.
try version 3.0
from vscode-phpunit.
Related Issues (20)
- Tests status not updating in tests explorer HOT 3
- phpunit.paths setting doesn't resolve path mapping HOT 6
- docker: invalid reference format HOT 3
- Tests are not being detected
- json5 to jsonc in README.md to match vscode's settings.json format
- Problem with path to the test file HOT 2
- Command-line options are not recognized by phpunit HOT 1
- Extension causes high cpu load
- Editor is read-only because the file system of the file is read-only HOT 4
- Not showing all test classes HOT 2
- Could not open input file on Mac HOT 2
- Issue when cwd has spaces in directory name HOT 1
- Option to Remove --teamcity Command-line Argument HOT 1
- phpunit.paths mapping not working with warden/den HOT 1
- Don't show test as failed when failOnRisky and failOnWarning are set to false HOT 1
- Debug test with xdebug HOT 1
- Feature request: adding exclaimation mark to test with warnings to help spotting them
- Extension does not work with PHP 8.3
- Spawn Error HOT 2
- Open VSX version is outdated HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vscode-phpunit.