public void testSequenceSequenceQuery() throws Throwable {
  ServerStateMachineContext context=mock(ServerStateMachineContext.class);
  ServerSessionContext session=new ServerSessionContext(10,UUID.randomUUID(),mock(Log.class),context,1000);
  AtomicBoolean complete=new AtomicBoolean();
  session.registerSequenceQuery(10,null);
  assertFalse(complete.get());
  session.setCommandSequence(9);
  assertFalse(complete.get());
  session.setCommandSequence(10);
  assertTrue(complete.get());
}

public void testSequenceSequenceQuery ( ) throws Throwable { ServerStateMachineContext context = mock ( ServerStateMachineContext . class ) ; ServerSessionContext session = new ServerSessionContext ( 10 , UUID . randomUUID ( ) , mock ( Log . class ) , context , 1000 ) ; AtomicBoolean complete = new AtomicBoolean ( ) ; session . registerSequenceQuery ( 10 , null ) ; assertFalse ( complete . get ( ) ) ; session . setCommandSequence ( 9 ) ; assertFalse ( complete . get ( ) ) ; session . setCommandSequence ( 10 ) ; assertTrue ( complete . get ( ) ) ; }
tests sequencing a sequence query .
