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