Like most professional developers, we like to ensure we have a solid suite of tests across our code. This gives us a base level of confidence that our software is doing what we expect, it also protects us from introducing bugs when integrating new features.

Both Gurn and Kintra rely heavily on their databases to provide much of their functionality, so it’s important to us that we have the same confidence in those databases as we do our source code. PostgreSQL is our database of choice so we were keen to scope out options available for testing in Postgres.

We took to the PostgreSQL official wiki to see what solutions were available and the documentation pointed us towards two frameworks, pgTAP and PGUnit.

After researching PGUnit it was clear that it had not been updated since Postgres 8.3+ (2008). Given how much Postgres has moved on we decided that this was probably not the right technology for the job. With PGUnit off of the table that left us with pgTAP.