News Feed
Jobs Feed
Sections




News Archive
feed this:

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

Christian Weiske's Blog:
Visualizing PHPUnit runs
May 02, 2011 @ 10:19:48

During some of his development, Christian Weiske found the tests for a project he was working on too slow for comfort and figured there had to be a way to find the root cause:

Running the specific test cases for the part of the application you're working on is easy and fast, but that does not tell you when changes in part A of the app break part B - which happened several times, and all just because I didn't want to wait 45 seconds again and again. So a solution was badly needed; tests should be as fast as possible; preferably < 10 seconds. Before being able to make the slow tests faster, I had to find out which of the 80 tests were slow.

Tools like Jenkinks give more detail on test runs, but a normal PHPUnit install won't. So, he came up with a method that uses Phing's phpunitreport task to generate extra reporting easily. Here's some example screenshots: test results summary, test detail and single page views of the same sort of data.

0 comments voice your opinion now!
visualize phpunit runtime phing phpunitreport report


Sebastian Bergmann's Blog:
Visualization of PHPUnit Development
March 16, 2011 @ 09:02:51

On his blog Sebastian Bergmann has a recent post about how he's visualizing PHPUnit's development and pushing that information into a video based on the history of the project.

According to svn.php.net, I committed the first PHPUnit code to cvs.php.net on November 27th 2001 and the first release, PHPUnit 0.1, was made on December 1st 2001. [...] On December 26th 2009, I moved the development of PHPUnit from svn.phpunit.de to GitHub. I imported the history from Subversion into Git. As you can see in the video, moving to GitHub lead to an increased number of contributions to PHPUnit.

You can watch the video either embedded in his post or directly from Vimeo. It's interesting to watch the progress of the application and see the contributions make to each of the parts. The whole video, spanning the entire commit history of the tool, lasts about 25 minutes.

0 comments voice your opinion now!
visualize phpunit development cvs svn github git video history


Derick Rethans' Blog:
More source analysis with VLD
February 23, 2010 @ 10:49:26

Derick Rethans has been working on some updates to a tool he's developed, VLD, to make it more helpful and effecting in optimizing the opcodes in your scripts and find the dead opcodes and paths. He talks about these updates in this recent post.

Recently I've been working on some new functionality to visualise all the code paths that make up each function. These new routines sit on top of the routines that do dead code analysis. These new routines sit on top of the routines that do dead code analysis. Every branch instruction (such as if, but also for and foreach) is analysed and a list of branches is created. [...] Once all the branches and their links are found, another algorithm runs to figure out which paths can be created out of all the branches.

He illustrates with a few examples, showing both the command that was executed and the resulting output with the new path information of a simple test file using a "for" loop and an "if/else" conditional.

0 comments voice your opinion now!
vld opcode visualize dead path


Raphael Stolt's Blog:
Getting a visualization of a Phing buildfile
October 28, 2008 @ 12:03:41

Raphael Stolt recently spent some time working up a tool to visualize Phing buildfiles and he's blogged about it in this new post.

Out of the box the Phing -l option can be used to get a first overview of all available targets in a given buildfile but it doesn't untangle the target dependencies and sometimes a picture is still worth a thousand words. Luckily the Ant community already provides several tools to accomplish the visualization of Ant buildfiles, reaching from solutions that apply a Xslt stylesheet upon a given buildfile.

Using the ant2dot tool along with the Graphiz graphic library, he transforms the XML from the build file into a simple graphic showing the flow of the build. An example image is included.

0 comments voice your opinion now!
phing visualize buildfile ant2dot graphiz stylesheet tutorial xslt


Debuggable Blog:
Programming Psychology - Return home early
April 28, 2008 @ 14:36:43

Felix Geisendorfer is taking an interesting approach to defining programming in this new post to the Debuggable blog - he's coming at it more from the level of the perception the programmer has about writing good code.

I believe understanding the patterns in your own thinking will by far make the biggest impact on how good you will get as a programmer. Forget design patterns, forget unit testing, forget all those functions you know. Important is to question why they exist and how they could be improved.

He illustrates through a few examples what he means. He describes one such thought method, the "return home early" process - basically, if something looks too complex for its own good, it probably is. He offers a different way of thinking about it too, a more visual way that can help simplify things even more by laying out the pieces and seeing where they all fit.

0 comments voice your opinion now!
psychology programming return home early complexity simple visualize


William Candillon's Blog:
Using XSLT to Visualize a Parse Tree
October 03, 2006 @ 08:27:00

On his "Yet andother PHP blog" today, William Candillon shares a script he's written up to create a visualization of the parse tree of a bit of PHP source code.

I wrote this xslt stylesheet to visualize the parse tree of a PHP source code. The stylesheet can actually convert any XML tree to graph in the dot format interpreted by Graphviz.

His code is a simple seven line script that outputs a nice, clean tree structure image of how the process flows. He includes links to all of the source and files he used to create the tree image.

1 comment voice your opinion now!
parse tree visualize graphviz xslt source parse tree visualize graphviz xslt source


Sebastian Bergmann's Blog:
Visualizing Text Differences in PHPUnit 3
August 23, 2006 @ 10:36:32

Sebastian Bergmann has posted this new item on his blog today detailing how to tell the differences between two strings inside of PHPUnit 3.

A long-standing feature request for PHPUnit has been the generation of a real diff between strings that span multiple lines.

Ideally this would be done by implementing the diff algorithm in PHP. But since Derick needed a working solution quickly, the two of us came up with a "hack": we just use GNU diff and invoke the diff command via shell_exec().

He gives an example, showing how to judge the difference between two strings of HTML in a test. The result catches the differences (inside the body tags) easily.

0 comments voice your opinion now!
visualize text difference phpunit test diff visualize text difference phpunit test diff



Community Events











Don't see your event here?
Let us know!


security overview language install unittest example release application code symfony2 opinion introduction podcast composer package framework hhvm facebook hack component

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework