public void InsertsItselfIntoTheWorkersListOnStartup()
 {
     worker.work(0,
                 (Job job) =>
     {
         Assert.That(Resque.workers()[0].workerId(), Is.EqualTo(worker.workerId())); return(true);
     });
 }
 public void RemovesItselfFromTheWorkersListOnShutdown()
 {
     worker.work(0,
                 (Job job) =>
     {
         Assert.That(Resque.workers()[0].workerId(), Is.EqualTo(worker.workerId())); return(true);
     });
     Assert.That(Resque.workers().Length, Is.EqualTo(0));
 }
 public void RemovesWorkerWithStringifiedId()
 {
     worker.work(0,
                 (Job job) =>
     {
         var workerId = Resque.workers()[0].workerId();
         Resque.removeWorker(workerId);
         Assert.That(Resque.workers().Length, Is.EqualTo(0));
         return(true);
     });
 }