exactly(2).of(jedis).type(queueKey); will(returnValue(KeyType.ZSET.toString()));
oneOf(jedis).zcard(queueKey); will(returnValue(size));
oneOf(jedis).zrange(queueKey, jobOffset, jobOffset + jobCount - 1); will(returnValue(payloads));
oneOf(pool).returnResource(jedis);
}});
final QueueInfo queueInfo = this.qInfoDAO.getQueueInfo(name, jobOffset, jobCount);
Assert.assertNotNull(queueInfo);
Assert.assertEquals(name, queueInfo.getName());
Assert.assertEquals((Long) size, queueInfo.getSize());
final List<Job> jobs = queueInfo.getJobs();
Assert.assertNotNull(jobs);
Assert.assertEquals(payloads.size(), jobs.size());
}