public IMongoCollection <TDocument> GetCollection <TDocument>(string name, MongoCollectionSettings settings = null)
        {
            if (!collections.TryGetValue(name.ToLower(), out IFakeMongoCollection fakeMongoCollection))
            {
                collections.Add(name.ToLower(), fakeMongoCollection = new FakeMongoCollection <TDocument>(this, name, settings ?? new MongoCollectionSettings()));
            }

            return((IMongoCollection <TDocument>)fakeMongoCollection);
        }
 public FakeMongoIndexManager(FakeMongoCollection <TDocument> collection)
 {
     this.collection = collection ?? throw new ArgumentNullException(nameof(collection));
 }