Missing tests - getting everything tested

Unit tests are not often the first thing on someone’s mind when it comes to coding, unless you are in the small group of developers that have become accustomed to writing tests before writing any code. Thanks to the current project I'm busy with I have joined this group.

Due to a few (lame) reasons, unit testing has never been a high priority on Infinitas. In all the wisdom of hindsight unit testing makes writing code quicker. With a majority of time saved trying to find out why something is not working that used to work or going back to tweak some code because it does not work properly in situation X.

One of the goals for a stable release of Infintias has always been loads of unit tests. It's been discussed since the start that 0.9b would be dedicated to mostly testing with a feature lock on anything new that does not have a ticket. Basically just bug fixes, unit tests and making it shine.

Anyone that has been watching the repository on GitHub would have noticed that the last tagged branch is 0.8a. This will be followed shortly by 0.9a. The aim of the current branch is to finish up the missing bits and pieces that are known/marked on the Lighthouse account. This will also include a bunch of testing (hopefully).

In order to make sure everything is as painless as possible, I have coded up some shell scripts to automate things. One of them being a simple shell to show any missing tests. It looks something like the following:

All it does is find all the files in the application, and then cross references that with all the tests in the system. It then outputs the list nicely so you have a quick overview of your apps tests. There are a few params you can pass to change the output such as "-plugins comma,separated,list" of plug-ins to show tests for only the passed plug-ins. I have some ideas for later doing a more advanced check on things like code coverage etc. I'll save that for another post.

If you would like to see the code, you can do so on the Infinitas repo.

Read more...

Moving EC2 instances across regions on Amazon Web Services (AWS)

the moveWe started using Amazon AWS at work for hosting and I landed up being the server admin. I've been stuck in terminal for more than 3 weeks and not touched a line of code (apart from turning debug on after this move to make sure the cache was cleared) and one awesome bash backup script.

After building a monster development box on AWS to host git (new application), SVN (old application), gitweb, …

Read more...

Custom view class - Zend, CakePHP, Symfony and Kohana

There are a lot of sites out there that benchmark frameworks. Every time there is a new benchmark, there is a huge outcry from the loosing sides followers. To date there has not been anything that I know of that has not been bias or meaningful, as the person doing the benchmarking does not know each of the frameworks and its normally a 'hello world' application which is completely pointless as I …

Read more...

No more posts