This site is about a previous instance of this event. For the current event, please see the updated site.

Conference Schedule - PGConf.EU 2014

Database Unit Testing with PgTAP

Date: 2014-10-24
Time: 09:30 - 10:20
Room: Medici I
Level: Beginner

Throughout the entire software stack it is common and encouraged today to write tests.

Thanks to David Wheeler's "PgTAP" testing framework (also available as "MyTAP" for MySQL) it is very convenient to directly test your databases.

"pgTAP is a unit testing framework for PostgreSQL written in PL/pgSQL and PL/SQL. It includes a comprehensive collection of TAP-emitting assertion functions, as well as the ability to integrate with other TAP-emitting test frameworks. It can also be used in the xUnit testing style."

PgTAP's testing capabilities include schemas, functions, selects, relations and many more aspects of a postgres database and runs independently of the programming language you're using on top of your Postgres databases.

I'll give an overview of PgTAP's usage, it's capabilities and in particular I'd like to illustrate how "cheap" testing can be to give a taste of in-database unit testing.

PgTAP is available here: and a Postgres extension:


Susanne Schmidt