public function readPrimaryOnly() { $this->getMongoCollection()->setReadPreference(\MongoClient::RP_PRIMARY); return $this; }
public function testReadPrimaryOnly() { $this->collection->readPrimaryOnly(); $this->assertEquals(array('type' => \MongoClient::RP_PRIMARY), $this->collection->getReadPreference()); }