小编mys*_*age的帖子

How can I get XDebug to run with PHPUnit on the CLI in Windows using VSCode?

I ran this command:

"C:\xampp\php\.\php.exe" "C:\xampp\php\phpunit" -d xdebug.profiler_enable=on -d xdebug.idekey=VSCODE

C:\xampp\php\php.ini has the following:

[XDebug]
zend_extension = "C:\xampp\php\ext\php_xdebug-2.5.0-7.1-vc14.dll"
xdebug.idekey=VSCODE
xdebug.profiler_enable=1
xdebug.default_enable=1
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.remote_autostart=1
Run Code Online (Sandbox Code Playgroud)

If I run the command without Listen for XDebug, I will see the following in the command line window:

Installing...
Running as single site... To run multisite, use -c tests/phpunit/multisite.xml
Not running ajax tests. To execute these, use --group ajax.
Not running ms-files tests. To execute these, use --group ms-files.
Not running external-http tests. …
Run Code Online (Sandbox Code Playgroud)

php xdebug visual-studio-code

3
推荐指数
2
解决办法
1337
查看次数

标签 统计

php ×1

visual-studio-code ×1

xdebug ×1