You can limit the tests run to a single group of tests by adding the -group parameter to the Test Runner options. Now you can run the tests as shown in step 11, previously
You need to add an extra step to the previous process On the remote PHPUnit configuration: The Path to script ensure that it is the path to the mounted folder (local vagrant folder) to your Drupal installation plus autoload.php and check the Default configuration file and use your Drupal Vagrant path plus core/phpunit.xml.
The easiest is probably to install the Xcode Command Line Tools. Configure the PHPUnit tests to run over SSH on your Vagrant. There are several ways to install Git on a Mac.Add a remote PHP interpreter to your PHPStorm Configuration.Configure PHPStorm to know where your Vagrant following this configuration.If you run your Drupal installation in a Virtual Machine (Vagrant) your configuration has to be a little different, just replace the first steps for these (This functionality is PHPStorm v.8 exclusively):
, or press ctrl + R on Mac OS, or shift + F10 on Linux. Run the test suite by going to Run > Run.In the Test runner section: for the Test scope option, select Defined in the configuration file, tick the Use alternative configuration file checkbox, and enter the path to your Drupal root directory, followed by /core/phpunit.xml.Click the plus sign in the top left corner of the screen and select PHPUnit.This allows you to debug directly out of the file, without setting up a custom configuration. You can also set the Default configuration file directly to your Drupal root directory, followed by /core/phpunit.xml. For Path to script, enter the path to your Drupal root directory, followed by /vendor/autoload.php.(Earlier versions of PhpStorm call this option: Use custom autoloader or Use custom autoloader). (Earlier versions of PHPStorm place this configuration at: PhpStorm v8-9.x: Project settings > PHP > PHPUnit, PhpStorm v10.x Languages & Frameworks > PHP > PHPUnit) Click " +" button, select "PHPUnit local" from dropdown. Create a Test Framework configuration by navigating to Languages & Frameworks > PHP > Test Frameworks.On Linux or Windows, press ctrl + alt + s or go to File > Settings. Open to PhpStorm's settings/preferences.(Without this step all tests that require a database will be ignored.) Edit /core/phpunit.xml and add the site's database credentials in the SIMPLETEST_DB variable.Duplicate the /core/ file and rename the copy to /core/phpunit.xml.In a nutshell, PhpStorm is one of those apps that will make you ask yourself how have you been able to develop PHP projects before installing it. On top of this, PhpStorm automatically saves your changes and the browser smartly updates the pages as you write. The HTML/CSS/JavaScript editor comes with live editing preview that makes it possible to see the performed changes in real time in the browser. Among its advanced front-end technologies, we could mention CSS, HTML5, SCSS, Sass, Less, Compass, Stylus, CoffeScript, Jade, ECMAScript, TypeScript, JavaScript and Emmet, along with refactorings, unit testing and debugging. PhpStorm also features support for PHPunit, a fact that enables you to develop and run unit tests right from the IDE. Reliable visual debugger and remote debugging options What is more, PhpStorm makes it easy for you to take care of various routine tasks directly from within the IDE thanks to the local history, Version Control Systems integration, support for remote deployment, command-line tools, SQL and databases, Composer, Vagrant, PHP UML, built-in REST client, SSH console and more.
You can take advantage of the built-in PSR1 and PSR2, Symfony2, Drupal, Zend and other standards compliant code formatting. Moreover, the Code formatter offers code style configuration and other features that enable you to write easy to support code. Code completion and formatting capabilities The editor is accompanied by PHPDoc support, code arranger and re-arranger, PHP code sniffer and mess detector, quick fixes, code formatter and other features that will keep your code clean and valid. The built-in smart PHP editor that is compatible with modern and legacy versions of PHP, and that also features code auto-completion, on-the-fly error prevention, refactorings and support for language mixtures.Ī large number of inspections ensure the quality of your code as you type by constantly analyzing the entire project. Advanced PHP editor and reliable development environment PhpStorm is a versatile and cross-platform PHP IDE that comes with a state of the art editor for PHP, HTML and JavaScript, as well as a wide assortment of inbuilt tools and features designed to make PHP development a walk in the park.