Debugging Unit Tests ?

It might sound trivial and the solution is more than easy - but as I am frequently asked how todo this, here is the simple answer.

Create a PHP file in the directory where you start your Unittests usually with this content:

1
2
3
4
5
6
7
8
9
10
11
12
13
 
$unitTest = '...Your Unittest name - e.g. unit_mytest.php or Alltests.php etc...';
 
$_SERVER['argv'] = array(
'/...path to your PHPUnit.../PHPUnit/TextUI/Command.php',
$unitTest
);
 
echo "<pre>";
include( '/...path to your PHPUnit.../PHPUnit/TextUI/Command.php' );
echo "</pre>";
 
...

Point your browser to this file, et voila - Unit test in the Browser.

Ok ;) - this solution is very easy and silly - but it works very well. And at least I got the impression that there are enough people around who do not know how to debug unit tests…

Testing Buildix

So as promised I finally found some time to test Buildix from Thoughtworks.

- Installed a fresh Ubuntu Version
- Installed Buildix via apt-get as described.

Unfortunatley it did not work as expected - after a short search in the forums I found the correct hint here.
Simply set execute and write permission of the folder /usr/share/buildix for all other users and reboot the system. That’s it.

Ah Mingle - I was always interested in this software ;) - so let’s give it a try. After filling in the settings for SMTP I created my first project - and - nothing happens. Server hangs, load is very high. Too bad - I simply lack the time to contact the support to figure out what happens - therefore I had to remove Mingle…

But - all the rest works great - I am amazed. I think this is the most easy way to get your continious integration server up and running.

Only User Management seem to lack some functionality. Right now everybody can register himself for write access to svn what is probably not the very best idea in the world. But it seems that they are working on it.

Let’s see how I will come along with Buildix…

Tales from the eXtreme Side - IPC 07 is over

So finally after 5 days I survived IPC and made my way home. As always it was a real pleasure to meet “la famiglia” - I learned a lot, hopefully could teach other people something and definitly had too much beer. The real reason why the IPC is so short is probably that otherwise 90% of PHP community would have to detox from alcohol :)

So - the title from my last talk could have also been the title of the whole IPC.

For those of you who are interested in the slides - you can download them directly here: tales-from-the-extreme-side_ipc_07.pdf
or if you interested in the PPT you might be able to fetch them via http://phpconference.com/

Agile Development for Beginners at IPC 07 in Frankfurt

Yesterday I did my workshop about Agile Development for Beginners - the slides will be available via the official phpconference website - and you can download them directly here.

agile-development-for-beginners_ipc_07.pdf

I think the workshop went quite well - and I found already some interesting feedback here - check it out.

Speaking at IPC 07

I want to take the chance and point you to the upcoming “International PHP Conference” early in November.

IPC 07 Speaker

There will be a full-day workshop “Practising Agile Development for Beginners” where I will introduce the basics, concepts and ideas behind agile development - focussing on the process and not so much on the tools as there is already an excellent Workshop planned by Sebastian Bergmann covering the most important tools you need like PHPUnit, SeleniumRC and cruisecontrol.

If you are interested in the methods and want to excercise Agile Development then I would be happy to meet you on IPC 07.

Practising Agile Development for Beginners
After a theoretical introduction into the major flavours of agile development, we will work on an example web project using Extreme Programming. The workshop will cover the whole project life cycle, but with more emphasis on planning and steering the project than on coding. Team motivation and practical tips from management side will round up the day.

Furthermore there will be a short Session where I will talk about the learnings and experiences I’ve made using eXtreme Programming the last years in various teams.

Tales from the eXtreme side
Exercising eXtreme Programming in larger PHP projects has provided many interesting experiences. What about refactoring? How is the team performance influenced by pair programming? And what happens when time pressure increases. Where is the difference between theory and practice? Some insights from the real world.

300 Storypoints ?

I did not know that the solution is so easy!

I am thinking about using this management approach - it would solve a lot of problems here.

Buildix 2.0 out soon

Hoi folks,

I am happy to announce that there will be a new version of buildix available soon. Thanks to sarnacke from Thoughtworks who gave me a hint - apparantly I missed this somehow.

Without having it tested it looks quite interesting:

The biggest change is that Buildix is no longer a complete operating system image. It’s now simply a package to install on an Ubuntu system. This allows you more flexibility in looking after your server, both in terms of additional software and maintaining the Buildix suite …

For sure having up to date versions of all the tools is also quite important. Unfortunately for me it’s too late now I’ve already installed my debian and all the needed tools. Right now I am hazzling with the brandnew continous inspection tools - as they are still under development it is quite natural that not everything works as expected. Hehe - did’nt even know that it’s so easy to crash PHP ;)

Thnx to sarnacke for this info!

Using safari on MAC OS X using selenium

Hoi,

while setting up our new testing Machine ( a very old PowerPC with 466 Mhz ;) ) I realized that it is not that easy to make Safari work using Selenium RC. With Michele from mayflower helping me we could make it work.

Here is the solution:

1. Use this patched Version of Selenium RC Snapshot with Safari and MAC OS X support ( it is the snapshot including the patch from here ).

2. Start Selenium using sudo

3. If you face any problems like “Please add the directory containing networksetup to your path” then you should check your disc under /System/Library/CoreServices/RemoteManagement/ARDAgent.app/
Contents/Support/networksetup - this directory should exist. If not - like on my old machine - you need to create a symlink to the correct directory - e.g.
“sudo ln -s networksetup-panther networksetup”

That’s it - I hope it helps I needed quite a few hours to figure this out.

Agile development platform on a disk

As I am asked frequently if there is a VMware image or something similar for Agile development I think it is time to point you to the most interesting release - buildix . As Martin Fowler is working at Thoughtworks I expect that this distribution should be good even though I never tried it myself. ( but I will - promised! )

Other releases:

Helix

If you know any other distribution I would be happy if you would leave me a comment.

Asshole driven development…

Scott Berkun writes about this brand new method. Actually I do belive that it is used quite often even if nobody knows that they execute this methodology.

← Previous Page