@Test
public void testPopQueueToUnlock(TestContext context){

    Async async = context.async();
    context.assertFalse(jedis.exists(STORAGE_QUEUES_TO_UNLOCK));
    storage.popQueueToUnlock().setHandler(event -> {
        context.assertTrue(event.succeeded());
        context.assertNull(event.result());
        addToQueuesToUnlock("q3");
        addToQueuesToUnlock("q1");
        addToQueuesToUnlock("q2");
        assertQueuesToUnlockItems(context, Arrays.asList("q1", "q2", "q3"));
        storage.popQueueToUnlock().setHandler(event1 -> {
            context.assertTrue(event1.succeeded());
            context.assertEquals("q3", event1.result());
            storage.popQueueToUnlock().setHandler(event2 -> {
                context.assertTrue(event2.succeeded());
                context.assertEquals("q1", event2.result());
                storage.popQueueToUnlock().setHandler(event3 -> {
                    context.assertTrue(event3.succeeded());
                    context.assertEquals("q2", event3.result());
                    storage.popQueueToUnlock().setHandler(event4 -> {
                        context.assertTrue(event4.succeeded());
                        context.assertNull(event4.result());
                        async.complete();
                    });
                });
            });
        });
    });
}