"""
Make sure send doesn't work on stopped controllers
"""

include controller.repy

class Stub:
  def __init__(self, port):
    self.port = port
    
if callfunc == 'intialize':
  c = Controller()
  o = Stub(12345)
  try:
    c.send(o, "message")
  except ControllerStoppedError:
    pass
  else:
    print "Controller.stop allowed before being started"
