Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

BitExpert Blog:
Running pdepend on PHP7
Aug 18, 2015 @ 14:57:19

On the BitExpert blog there's a post that shows you how to use the pdepend tool on PHP7, an automated tool that shows you the "quality of your design in the terms of extensibility, reusability and maintainability".

Being a good citizen of the PHP community we do test out internal libs against the current PHP7 codebase. So far we had no issues but then at one day one of our Jenkins PHP7 jobs failed. After investigating a bit it turned out that the problem was not part of our codebase but part of of pdepend. The pdepend process died with the error message that "T_CHARACTER and T_BAD_CHARACTER are no longer defined" which is true. The error was already reported as an issue on Github.

Unfortunately, as the problem here is a change to the core PHP language itself, there's not much of a workaround other than to just not run those certain jobs. He outlines how they handle detecting the tests that have problems, but only when run on PHP7. This allows them to run all of the tests and allow the automated system do to its work. When/if the problem is fixed in pdepend, all that's needed is to remove this one check and they're good to go.

tagged: pdepend phpdepend php7 skip test version error github issue

Link: https://blog.bitexpert.de/blog/running-pdepend-on-php7/

DZone.com:
Automated code reviews for PHP
Jun 16, 2011 @ 15:06:47

On the Web Builder Zone (a part of DZone.com) Giorgio Sironi take a high-level look at some of the tools you can use for automated code reviews in your projects without you ever having to lift a finger (well, once it's set up, of course).

I'm exploring an approach to automated code review: it's not as precise as the human-based one, but it scales better. [...] All in all, automated code reviews, performed with tools instead of with human intellect, can be a starting point to search for the problematic zones of a codebase. Then the human may come in, since they also have to clean up the code: their intervention was already scheduled.

The tools he mentions (and, in some cases, shows how to install/use) are:

tagged: automated code review tools phpunit phpdepend pmd jenkins

Link:

DZone.com:
PHP Tool Integration (PHPsrc)
May 24, 2011 @ 17:05:15

On the PHP on Windows section of DZone.com, Eric Hogue looks at the PHPsrc extension for Eclipse - a handy tool that lets you run some of the common PHP QA tools right from the IDE.

PHPsrc is a plugin that allow you to run PHP_CodeSniffer, PHPUnit, PHP Depend and PHP Copy/Paste Detector directly in Eclipse. The site also says that more tools should come. As you work, you will see any transgression you make. That will save you from breaking the build, but it also makes it easier to fix the problem. After all, you just wrote the faulty lines of code.

He walks you through the install of the plugin and shows you how to set things up to point to the executables on your development environment (complete with some screenshots). There's even an example of the output for a particularly offensive (standards-wise, of course) piece of code.

tagged: phpsrc eclipse plugin codesniffer phpunit phpmd phpdepend

Link:

Kore Nordmann's Blog:
PHP quality assurance tools
Jun 01, 2010 @ 17:45:27

In a new post to his blog Kore Nordmann talks about quality assurance tools they've been using for their development process - PHP_Depend and phpUnderControl.

Some of the most important tools for quality assurance in PHP projects are PHP_Depend and PhpUnderControl. In the future Qafoo - passion for software quality will provide support for both.

He talks a bit about each tool and how they should be used to find and treat a lot of the issues that could come up in your application development. Since the author of the PHP_Depend tool, Manuel Pichler, works for the company, they'll be supporting it as well as offering services for integrating it into your workflow.

tagged: quality assurance tool phpdepend phpundercontrol

Link:

Manuel Pichler's Blog:
PHP_Depend jumps on the D-BUS
Nov 19, 2009 @ 18:46:17

Manuel Pichler has a new post today about a feature he's added into the PHP_Depend application that tracks the dependencies in your code - a bit of DBus magic.

Sometimes the parsing and analysis process of PHP_Depend can consume a lot of time to finish, so I always put the shell aside and do something different. Normally I take a look at the shell every few minutes to check if the process has finished, but it also happens that I totally forget that I have started a PHP_Depend process on my system. So I need something that says to me, "Hey, mapi PHP_Depend has finished its job...", and here comes D-BUS in the game.

With the help of the DBus extension, he made a way to have the PHP_Depend process send a message (in his case one similar to a Growl popup) when the dependency checking is done. You'll need the 0.9.0 branch to get the "notify-me" command line option to make it all work.

tagged: phpdepend dbus notify tutorial

Link:

Sebastian Bergmann's Blog:
Quality Assurance Tools for PHP
Mar 17, 2009 @ 17:02:53

Sebastian Bergmann has a new post that lists a few quality assurance testing tools you can use to ensure that you and your code are safe to make the jump to production.

He's laid out a map of the tools that can all interact to create a more robust environment for automatically building and testing your code. Here's his list:

The results of all of these tools running on your code is then fed into the CruiseControl instance and passed off to phpUnderControl for final deployment.

tagged: quality assurance tool phpcodesniffer phpmd phpcpd phpdepend phpunit phpundercontrol

Link:


Trending Topics: