### Question:
TokenStream { public boolean matches( String expected ) throws IllegalStateException { return !completed && (expected == ANY_VALUE || currentToken().matches(expected)); } TokenStream( String content,
                        Tokenizer tokenizer,
                        boolean caseSensitive ); TokenStream start(); void rewind(); Position previousPosition(); Position nextPosition(); int consumeInteger(); long consumeLong(); boolean consumeBoolean(); String consume(); void consume( String expected ); void consume( char expected ); void consume( int expectedType ); void consume( String expected,
                         String... expectedForNextTokens ); void consume( String[] nextTokens ); void consume( Iterable<String> nextTokens ); boolean canConsume( String expected ); boolean canConsume( char expected ); boolean canConsume( int expectedType ); boolean canConsume( String currentExpected,
                               String... expectedForNextTokens ); boolean canConsume( String[] nextTokens ); boolean canConsume( Iterable<String> nextTokens ); boolean canConsumeAnyOf( String firstOption,
                                    String... additionalOptions ); boolean canConsumeAnyOf( String[] options ); boolean canConsumeAnyOf( Iterable<String> options ); boolean canConsumeAnyOf( int firstTypeOption,
                                    int... additionalTypeOptions ); boolean canConsumeAnyOf( int[] typeOptions ); boolean matches( String expected ); boolean matches( char expected ); boolean matches( int expectedType ); boolean matches( String currentExpected,
                            String... expectedForNextTokens ); boolean matches( String[] nextTokens ); boolean matches( Iterable<String> nextTokens ); boolean matches( int currentExpectedType,
                            int... expectedTypeForNextTokens ); boolean matches( int[] typesForNextTokens ); boolean matchesAnyOf( String firstOption,
                                 String... additionalOptions ); boolean matchesAnyOf( String[] options ); boolean matchesAnyOf( Iterable<String> options ); boolean matchesAnyOf( int firstTypeOption,
                                 int... additionalTypeOptions ); boolean matchesAnyOf( int[] typeOptions ); boolean hasNext(); @Override String toString(); void saveState(); void regenerate(); String getContentBetween( Position starting,
                                     Position end ); static BasicTokenizer basicTokenizer( boolean includeComments ); static final String ANY_VALUE; static final int ANY_TYPE; }### Answer:
@Test public void shouldReturnFalseFromMatchesWithCaseSensitiveTokenStreamIfMatchStringDoesMatchCaseExactly() { makeCaseSensitive(); assertThat(tokens.matches("select"), is(false)); assertThat(tokens.matches("SElect"), is(false)); assertThat(tokens.matches("Select"), is(true)); }
@Test public void shouldReturnFalseFromMatchesWithCaseInsensitiveTokenStreamIfMatchStringIsUppercaseAndDoesNotMatch() { makeCaseInsensitive(); assertThat(tokens.matches("ALL"), is(false)); assertThat(tokens.matches("SElect"), is(false)); assertThat(tokens.matches("SELECT"), is(true)); }
@Test public void shouldReturnTrueFromMatchIfAllTypeValuesMatch() { makeCaseInsensitive(); assertThat(tokens.matches(BasicTokenizer.WORD, BasicTokenizer.WORD), is(true)); }
@Test public void shouldReturnFalseFromMatchIfAllTypeValuesDoNotMatch() { makeCaseInsensitive(); assertThat(tokens.matches(BasicTokenizer.WORD, BasicTokenizer.DECIMAL), is(false)); assertThat(tokens.matches(BasicTokenizer.DECIMAL, BasicTokenizer.WORD), is(false)); }