assumeThatMongoVersionIsGreaterThan("2.1.1");
collection.insert("{version : 1, days:[{name:'monday'},{name:'sunday'}]}");
collection.insert("{version : 2, days:[{name:'wednesday'}]}");
String monday = collection.findOne("{version:1}").projection("{days:{$elemMatch:{name: 'monday'}}}").map(new JSONResultHandler());
assertThat(monday).contains("\"days\" : [ { \"name\" : \"monday\"}]");
}