Universal database tests

Some reformulating and updating of Nathan's database tests (also moving the commits to the official/universaldatabase branch so that everybody can contribute.)