@Test public void testGetSteps() { clock.setTime(0); long thirtySecondsStepsFromEpoch = sessionUtil.getThirtySecondsStepsFromEpoch(); Assert.assertEquals(0, thirtySecondsStepsFromEpoch); clock.setTime(30000); thirtySecondsStepsFromEpoch = sessionUtil.getThirtySecondsStepsFromEpoch(); Assert.assertEquals(1, thirtySecondsStepsFromEpoch); clock.setTime(35000); thirtySecondsStepsFromEpoch = sessionUtil.getThirtySecondsStepsFromEpoch(); Assert.assertEquals(1, thirtySecondsStepsFromEpoch); clock.setTime(60000); thirtySecondsStepsFromEpoch = sessionUtil.getThirtySecondsStepsFromEpoch(); Assert.assertEquals(2, thirtySecondsStepsFromEpoch); clock.setTime(63000); thirtySecondsStepsFromEpoch = sessionUtil.getThirtySecondsStepsFromEpoch(); Assert.assertEquals(2, thirtySecondsStepsFromEpoch); }
public long getThirtySecondsStepsFromEpoch() { return clock.getEpochTime() / 30000; }
DefaultSessionUtil extends SessionUtil { public long getThirtySecondsStepsFromEpoch() { return clock.getEpochTime() / 30000; } }
DefaultSessionUtil extends SessionUtil { public long getThirtySecondsStepsFromEpoch() { return clock.getEpochTime() / 30000; } DefaultSessionUtil(Clock clock);   DefaultSessionUtil(); }
DefaultSessionUtil extends SessionUtil { public long getThirtySecondsStepsFromEpoch() { return clock.getEpochTime() / 30000; } DefaultSessionUtil(Clock clock);   DefaultSessionUtil(); @Override byte[] generateSessionToken(byte[] key, ByteBuf data, long count); @Override int generateRequestToken(byte[] sessionToken, ByteBuf message, long count); @Override boolean validateMessage(
      byte[] sessionToken, ByteBuf message, int requestToken, long count); long getThirtySecondsStepsFromEpoch(); }
DefaultSessionUtil extends SessionUtil { public long getThirtySecondsStepsFromEpoch() { return clock.getEpochTime() / 30000; } DefaultSessionUtil(Clock clock);   DefaultSessionUtil(); @Override byte[] generateSessionToken(byte[] key, ByteBuf data, long count); @Override int generateRequestToken(byte[] sessionToken, ByteBuf message, long count); @Override boolean validateMessage(
      byte[] sessionToken, ByteBuf message, int requestToken, long count); long getThirtySecondsStepsFromEpoch();  }