--TEST-- Test ispersistent on context and socket --SKIPIF-- --FILE-- getSocket(ZMQ::SOCKET_REQ, 'persistentId'); $socket2 = $context->getSocket(ZMQ::SOCKET_REQ, null); var_dump($context->isPersistent(), $socket->isPersistent(), $socket->getPersistentId(), $socket2->isPersistent(), $socket2->getPersistentId()); /* Non-persistent context */ $context = new ZMQContext(1, false); $socket = $context->getSocket(ZMQ::SOCKET_REQ, 'persistentId'); $socket2 = $context->getSocket(ZMQ::SOCKET_REQ, null); var_dump($context->isPersistent(), $socket->isPersistent(), $socket->getPersistentId(), $socket2->isPersistent(), $socket2->getPersistentId()); --EXPECTF-- bool(true) bool(true) string(12) "persistentId" bool(false) NULL bool(false) bool(false) NULL bool(false) NULL