def readiness_probe(self) -> bool:
        """Test if the RabbitMQ broker is ready."""
        connection = pika.BlockingConnection(self.get_connection_params())
        if connection.is_open:
            connection.close()
            return self
        raise RuntimeError("Could not open connection to RabbitMQ broker.")
Test if the RabbitMQ broker is ready.
modules/rabbitmq/testcontainers/rabbitmq/__init__.py