Add unit test for MongoServerExternalResource and a few other minor changes