Added pubsub subscribe test, simplified test database mock