Despite all the fancy tools we have today, software projects fail as often as 15 years ago.

More frameworks & tools are not a solution. Instead we need to explore more humane ways of collaborating, establish a culture of continuous learning and strive for technical excellence.

Using SQL fixtures for database related unit tests

This is a short tutorial to show how to use fixtures for database related unit tests. The inspiration for this post came from a conversation I had at the recent PHP Unconference in Hamburg, Germany. From my experience, the usual way to test database related classes is to use a special test database, that needs a reset before each run (drop the existing tables and import the test dump). That approach has several severe drawbacks, all observed in real life projects many, many times:

Exceptions: Andrew Hunt/David Thomas vs Robert C. Martin

There is a subtle difference between what Robert C. Martin recommends in Clean Code and what Andrew Hunt / David Thomas recommend in The Pragmatic Programmer. Martin encourages you to always use exceptions if the normal program flow is interrupted to avoid if statements (or even worse: forgotten if statements and mixed result types) while Hunt/Thomas say this can cause harm (“it’s a kind of cascading goto”) and should only be used if something truly unexpected happens (tip 34).

About Passion

What does passion mean for a Software Engineer? Depends on the context. First, and that’s what start-up companies usually expect from their employes, it means you love the company, the business idea and the team you work with. Some people are also passionate about their Apple computer/phone/tablet in a similar way (the term “Fanboy” is frequently used in Web forums to describe this behavior). * Second, it can mean that you stay ahead of the curve and have strong opinions about how to do your job (independent from the company you’re currently working for): For example, I’m obsessed with clean code and unit tests.

Wunderkit and the 6Wunderkinder – 8 months later

As you can see on my Linkedin profile, I used to work as consultant for 6Wunderkinder, a Berlin based start-up company, last year. My job was to provide training for the developers and help building the initial Web frontend for Wunderkit, their next product after the popular Wunderlist app. Even though I could say a lot about what I liked and didn’t like about any company I worked with, I’m never disclosing internal details.

The Clean Coder

I’m currently reading The Clean Coder by Robert C. Martin. Here are some of my favorite quotes: Caffeine “There is no doubt that some of us can make more efficient use of our focus-manna by consuming moderate amounts of caffeine. But take care. Caffeine also puts a strange jitter on our focus.” Arrogance “Programmers tend to be arrogant, self-absorbed introverts.We didn’t go into this business because we like people. Most of us got into programming because we prefer to deeply focus on sterile minutia, juggle lots of concepts simultaneously, and in general prove to ourselves that we have brains the size of a planet, all while not having to interact with the messy complexities of other people.

Eclipse is not the solution!

During the last couple of days, I’ve been updating my posting about cargo cult coding standards for PHP. There are some examples now. Thanks to Arturas Smorgun for retweeting it. I’m sure my post doesn’t have a huge impact on the community, but for me it’s still worth talking about my experiences. Guess what’s bothering me the most is that the popular PEAR/Zend Framework coding standard actually forces you to lose the context of your currently edited code.

Green wallpaper for the new iPad

Just came back from the botanic garden and brought this iPad 3 wallpaper with me (2048×2048 px):

Cargo Cult Coding Standards (CCCS) for PHP

Cargo cult means that you copy some (previously) successful behavior from others and expect something good to happen to you (or your project) as well. For coding standards, that’s a very good starting point. Especially since formatting standards are often not based on any science – life is just easier, if everyone is using the same formatting for source code and we all hate the discussions at the start of projects, when some junior developer tries to promote it’s own fancy ideas.

Replacing OpenJDK with Oracle JDK

Since I can’t use OpenJDK for most applications (see last post), I was looking for a way to easily replace it with the original JDK. Thankfully I found a good howto. The short version: # Download Java from Oracle * and extract the contents of the tar.gz archive to "java-7-oracle" sudo mv java-7-oracle/ /usr/lib/jvm/ sudo add-apt-repository ppa:nilarimogard/webupd8 sudo apt-get update sudo apt-get install update-java sudo update-java This should work for Ubuntu 11.