fix tests on older versions of postgres