--TEST-- ExecutionTimeoutException: exceeding maxTimeMS (commands) --SKIPIF-- --FILE-- selectServer(new \MongoDB\Driver\ReadPreference('primary')); $cmd = array( "count" => "collection", "query" => array("a" => 1), "maxTimeMS" => 100, ); $command = new MongoDB\Driver\Command($cmd); failMaxTimeMS($server); throws(function() use ($server, $command) { $result = $server->executeCommand(DATABASE_NAME, $command); }, "MongoDB\Driver\Exception\ExecutionTimeoutException"); ?> ===DONE=== --EXPECT-- OK: Got MongoDB\Driver\Exception\ExecutionTimeoutException ===DONE===