@Test
public void shouldLock() {

  final String token = lock.acquire(Collections.singletonList("1"), "locks", 1000);
  assertThat(token).isEqualTo("abc");
  assertThat(redisTemplate.opsForValue().get("locks:1")).isEqualTo("abc");
  assertThat(redisTemplate.getExpire("locks:1", TimeUnit.MILLISECONDS)).isCloseTo(1000, Offset.offset(100L));
}