### Question:
TokenStream { public int remaining() { return tokens.size() - currentTokenPosition; } TokenStream(final Token... tokens);   TokenStream(final List<Token> tokens); Token current(); void reset(int save); void shift(); int remaining(); int getCurrentTokenPosition();  }### Answer:
@Test public void remaining() { Assert.assertEquals(4, tokenStream.remaining()); tokenStream.shift(); tokenStream.shift(); Assert.assertEquals(2, tokenStream.remaining()); tokenStream.shift(); tokenStream.shift(); Assert.assertEquals(0, tokenStream.remaining()); }