recca0120 / vscode-phpunit

The VS Code Test Explorer extension for PHPUnit
MIT License
130 stars 45 forks source link

Could not open input file on Mac #166

Open KenHuangisGood opened 1 year ago

KenHuangisGood commented 1 year ago

當我在Mac的vsCode安裝這個套件時,我出現了以下問題

php vendor/bin/phpunit /Users/MyName/MyProject/server/tests/Unit/SubBranchArticleRepositoryTest.php --filter=^.*::(testGetSubBranchArticleGroup)( with data set .*)?$ --teamcity --colors=never

❌ Could not open input file: vendor/bin/phpunit

我的系統資訊 Mac I5 - Ventura 13.3.1(a) PHP - 8.2 Laravel - 9

recca0120 commented 1 year ago

php 給絕對路徑

KenHuangisGood commented 1 year ago

使用絕對路徑後就沒有這個問題了 但之後出現了zsh: no matches found: --filter=^.*::(testValidateGetAnnouncementGroupRequestData)( with data set .*)?$

像這樣

/usr/local/bin/php vendor/bin/phpunit /Users/MyName/MyProject/server/tests/Unit/AnnouncementValidateTest.php --filter=^.*::(testValidateGetAnnouncementGroupRequestData)( with data set .*)?$ --teamcity --colors=never

後來得到這個回應

zsh: no matches found: --filter=^.*::(testValidateGetAnnouncementGroupRequestData)( with data set .*)?$