Fix tests for postgresql env