Linux SRV-16 6.18.44-paas #1 SMP PREEMPT_DYNAMIC Thu Aug 13 10:08:12 UTC 2026 x86_64
/
opt
/
php-8.3
/
share
/
test
/
mongodb
/
tests
/
readPreference
/
//opt/php-8.3/share/test/mongodb/tests/readPreference/readpreference-ctor_error-007.phpt
--TEST-- MongoDB\Driver\ReadPreference construction (combining hedge with primary read preference) --FILE-- <?php require_once __DIR__ . '/../utils/basic.inc'; echo throws(function() { new MongoDB\Driver\ReadPreference(MongoDB\Driver\ReadPreference::PRIMARY, null, ['hedge' => ['enabled' => true]]); }, 'MongoDB\Driver\Exception\InvalidArgumentException'), "\n"; ?> ===DONE=== <?php exit(0); ?> --EXPECTF-- OK: Got MongoDB\Driver\Exception\InvalidArgumentException hedge may not be used with primary mode ===DONE===