Set the MongoClient instance to wrap.
public setMongo ( MongoClient $mongoClient ) | ||
$mongoClient | MongoClient |
/** * @expectedException InvalidArgumentException */ public function testSetMongoShouldThrowExceptionForInvalidArgument() { $mongoDB = $this->getMockBuilder('MongoDB')->disableOriginalConstructor()->getMock(); $conn = new Connection(); $conn->setMongo($mongoDB); }