public void TestCreateCollectionSetCappedSetMaxDocuments()
{
var collection = _database.GetCollection("cappedcollection");
collection.Drop();
Assert.IsFalse(collection.Exists());
var options = CollectionOptions.SetCapped(true).SetMaxSize(10000000).SetMaxDocuments(1000);
_database.CreateCollection(collection.Name, options);
Assert.IsTrue(collection.Exists());
var stats = collection.GetStats();
Assert.IsTrue(stats.IsCapped);
Assert.IsTrue(stats.StorageSize >= 10000000);
Assert.IsTrue(stats.MaxDocuments == 1000);
collection.Drop();
}