diff --git a/tests/test_cli.py b/tests/test_cli.py index f484550e..a92fb345 100644 --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -38,22 +38,28 @@ class TestRQCli(RQTestCase): get_failed_queue().quarantine(job, Exception('Some fake error')) # noqa def test_empty(self): - """rq -u empty -y""" + """rq empty -u failed""" runner = CliRunner() result = runner.invoke(main, ['empty', '-u', self.redis_url, 'failed']) self.assertEqual(result.exit_code, 0) self.assertEqual(result.output.strip(), '1 jobs removed from failed queue') def test_requeue(self): - """rq -u requeue""" + """rq requeue -u --all""" runner = CliRunner() result = runner.invoke(main, ['requeue', '-u', self.redis_url, '--all']) self.assertEqual(result.exit_code, 0) self.assertEqual(result.output.strip(), 'Requeueing 1 jobs from failed queue') def test_info(self): - """rq -u info -i 0""" + """rq info -u """ runner = CliRunner() result = runner.invoke(main, ['info', '-u', self.redis_url]) self.assertEqual(result.exit_code, 0) self.assertIn('1 queues, 1 jobs total', result.output) + + def test_worker(self): + """rq worker -u -b""" + runner = CliRunner() + result = runner.invoke(main, ['worker', '-u', self.redis_url, '-b']) + self.assertEqual(result.exit_code, 0)