chiark / gitweb /
Comments
[disorder] / tests / queue.py
index cc0b619a31e719b97fc81640e08e4fb1694e9c17..7ed10a076aa632419475a745487fec84059a0aaf 100755 (executable)
@@ -1,7 +1,7 @@
 #! /usr/bin/env python
 #
 # This file is part of DisOrder.
-# Copyright (C) 2007 Richard Kettlewell
+# Copyright (C) 2007, 2008 Richard Kettlewell
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -23,6 +23,12 @@ import dtest,time,disorder,re
 def test():
     """Check the queue is padded to the (default) configured length"""
     dtest.start_daemon()
+    dtest.create_user()
+    print " waiting for queue to be populated..."
+    class wait_monitor(disorder.monitor):
+        def queue(self, q):
+            return False
+    wait_monitor().run()
     c = disorder.client()
     print " getting queue via python module"
     q = c.queue()