spring-projects/spring-boot — pull request #2002 by hekonsek (2014-11-25 21:43:31+00:00)
Title: Embedmongo

Hi,

I've added autoconfiguration for the EmbedMongo library. EmbedMongo [1] is something like H2 or HSQL, but for MongoDB, so basically you can run your tests against Mongo server instead of mocks. EmbedMongo is even better then H2/HSQL, because it starts *real* MongoDB server, not emulator of your RDBMS.

EmbedMongo is Apache 2 licenses, available in the Maven Central and actively developed/maintained for a long time. I can't imagine working with Mongo without it anymore :) .

What this autoconfig does is detecting if EmbedMongo + JavaDriver are present in the classpath. If so, then new embedded MongoDB process is started on port specified in `spring.data.mongodb.port` property.

Cheers.

[1] https://github.com/flapdoodle-oss/de.flapdoodle.embed.mongo