Continuous Integration: Automated database setup with Doctrine on Travis-CI

Testing is important — most people understand that by now. A lot of people write tests for their open source code already, but in-house testing is still hard. For example, many of us had an encounter with Jenkins: it runs well to a point where it becomes harder to maintain the Jenkins than it is to write tests. Another obstacle is test setup and environments: When I write and run tests, there is sometimes only so much I can do to mock and avoid actual calls to my storage backend....

August 13, 2012 · 4 min

Too much abstraction: Doctrine and PHP

Personally — I feel like I’m really, really late to get on the Doctrine train. I’ve tried Doctrine 1 a few years back and found it mostly too complicated for my needs. For all I know, I still find PEAR::DB and PEAR::MDB2 the perfect database abstraction layers (DBAL). Though of course they may or may not be totally up to date in terms of PHP etc.. The overall concept of an ORM never stuck with me....

July 6, 2012 · 5 min

Vagrant sans Ruby

Development, testing, staging and production — this is how most people devide up different environments for application development. Maintenance and setup of these environments is often not a trivial goal to achieve. Having worked with a couple different code bases and setups over the last decade, I often noticed things like environment specific hacks (if ($env == 'testing') { ... }) in application code and service configurations and a lot of manual labour all around....

June 5, 2012 · 4 min

From Subversion to GIT (and beyond!)

Here’s a more or less simple way to migrate from Subversion to GIT(hub), this includes mapping commits and tags and what not! Authors If multiple people congtributed to your project, this is probably the toughest part. If you’re not migration from let’s say Google Code but PHP’s Subversion repository, then it’s really pretty simple indeed: the username is the email address. I found a nifty bash script to get it done (and adjusted it a little bit):...

December 9, 2011 · 5 min

Tracking PHP errors

track_errors provides the means to catch an error message emitted from PHP. It’s something I like to use during the development of various applications, or to get a handle on legacy code. Here are a few examples why! For example Imagine the following remote HTTP call: So whenever this call fails, it will return false and also emit an error message: Some people use @ to suppress this error message — an absolute no-go for reasons such as:...

November 27, 2010 · 2 min