Add tests for Db, DbMechanism and HttpDbMechanism