--TEST-- MongoDB\Driver\Manager::executeCommand() connection error --FILE-- 1]); echo throws(function() use($manager, $command) { $manager->executeCommand('test', $command); }, "MongoDB\Driver\Exception\ConnectionTimeoutException"), "\n"; ?> ===DONE=== --EXPECTF-- OK: Got MongoDB\Driver\Exception\ConnectionTimeoutException No suitable servers found (`serverSelectionTryOnce` set): %s ===DONE===