2013 02-26 - Software Tests with Mongo db

Preview:

DESCRIPTION

Quality matters. That’s why we write software tests. They give us confidence to release complex business applications. In a schema-free world they are going to be our escape rope! This talk introduces some Unit Testing principles and separates them from Integration Tests. We will see how other databases solve common problems and how we can archive the same with MongoDB. Of course, you can expect some Test Driven Development (TDD).

Citation preview

“ ”J.B. Rainsberger

using (var documentStore = new EmbeddableDocumentStore{ RunInMemory = true}.Initialize()) { using (var session = documentStore.OpenSession()) { // Run complex test scenarious } }

https://nuget.org/packages/Mongo2Go/

using (var runner = MongoDbRunner.Start()) { var collection = new MongoClient(runner.ConnectionString) .GetServer() .GetDatabase("TestDatabase") .GetCollection<TestDocument>("TestCollection"); // Run complex test scenarious }