Fix test cases for 9.0

As mentioned in #168, our tests don't seem to work against PostgreSQL 9.0.  These two commits should fix them.