Package coilmq :: Package tests :: Package functional :: Class TestStompClient
[frames] | no frames]

Class TestStompClient

object --+
         |
        TestStompClient

A stomp client for use in testing.

This client spawns a listener thread and pushes anything that comes in onto the read_frames queue.

Instance Methods
 
__init__(self, addr, connect=True)
x.__init__(...) initializes x; see help(type(x)) for signature
 
connect(self, headers=None)
 
send(self, destination, message, set_content_length=True, extra_headers=None)
 
subscribe(self, destination)
 
send_frame(self, frame)
Sends a stomp frame.
 
disconnect(self)
 
close(self)

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Instance Variables
Queue.Queue containing any received stompclient.frame.Frame received_frames
A queue of Frame instances that have been received.
Properties

Inherited from object: __class__

Method Details

__init__(self, addr, connect=True)
(Constructor)

 

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  • addr (tuple) - The (host,port) tuple for connection.
  • connect (bool) - Whether to connect socket to specified addr.
Overrides: object.__init__

send_frame(self, frame)

 

Sends a stomp frame.

Parameters:
  • frame (stompclient.frame.Frame) - The stomp frame to send.