Last active
February 27, 2019 08:15
-
-
Save Daniel-Peder/5d21d806f3d6e989bd10c1a406e31a3f to your computer and use it in GitHub Desktop.
netbeans 8.0.2 and PHPunit bug workaround
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$phpunit_phar =__DIR__.'\\phpunit.phar'; // @edit path to Your phpunit | |
$php_exe_path='C:\Users\[username]\AppData\Local\PHP\v5.6\php.exe'; // @edit path to Your win php | |
array_splice($argv,-1,0,array("--")); // inject argument terminator | |
$argv[0] = $phpunit_phar; // inject phpuit path | |
array_unshift($argv,$php_exe_path); // inject php executable | |
//print_r($argv); | |
$cmd = ''; | |
// build command line to execute | |
foreach($argv as $arg){ | |
$cmd .= sprintf('"%s" ',$arg); | |
} | |
// echo $cmd."\n"; | |
exec($cmd); // execute |
thanks
....
exec($cmd,$output); // execute
echo implode("\n",$output);
Thanks Daniel-Peder and mharj.
The phpUnit works with NetBeans 8.0.2
Hi,
An other way (easier) to do it : https://gist.github.com/Nick974/745c4a77e0a7dfe1b2771442f078ba62
OTHER SOLUTION:
- Download and Extract in your netbeans directory:
netbeans-support-to-phpunit-6.5.zip
- I copied this module from the netbeans 10.0, and it works for me!
OTHER SOLUTION:
1. Download and Extract in your netbeans directory: [netbeans-support-to-phpunit-6.5.zip](https://mega.nz/#!ryYCRCCK) * I copied this module from the netbeans 10.0, and it works for me!
@wandbferreira lets run it through Virustotal
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
SETUP:
phpunit4netbeans.php
to the directory holdingphpunit.phar
phpunit4netbeans.php
, example:C:\Users\[your-path-to-phpunit-script]\phpunit4netbeans.php
All done, happy testing!