title: How to write unit/integration tests in python with rabbitmq?
body: <p>I have a python project written using rabbitmq, and I'm wondering how I should write unit tests for it/what are best practices. </p>
  
  <p>Since the code requires a rabbitmq server to be running in the background these are the three options I've come up with:</p>
  
  <ol>
  <li>write some checker that checks at the start of a test suite whether rabbit is running and fails if it doesn't - not ideal because it requires the manual starting of rabbitmq</li>
  <li>automatically start a process with rabbitmq on each test setUp and kill it on tearDown - for some reason this creates connection errors</li>
  <li>mock out rabbitmq - does anyone have any suggestions or tips on this one?</li>
  </ol>
  
  <p>Thanks!</p>
  
  <p>Jon</p>