fixed database tests