Permalink
Browse files

updates test (tasks cancellation)

  • Loading branch information...
1 parent b613ddf commit 5f66919a3687facd5fbbf2fe62321c162909a87e @featalion featalion committed May 22, 2013
Showing with 4 additions and 2 deletions.
  1. +4 −2 test.py
View
@@ -61,16 +61,18 @@ def test_getTaskDetails(self):
self.assertEqual(task_id, task.id)
def test_zcancelTask(self):
+ time.sleep(2)
tasks = self.worker.tasks()
-
for task in tasks:
self.worker.cancel(task)
+ time.sleep(3)
new_tasks = self.worker.tasks()
real_tasks = []
for task in new_tasks:
- if task.status not in ['cancelled', 'error']:
+ if task.status not in ['cancelled', 'error', 'killed']:
real_tasks.append(task)
+
self.assertEqual(len(real_tasks), 0)
def test_postSchedule(self):

0 comments on commit 5f66919

Please sign in to comment.