public AstNode rewrite(final AstNode node, final C context) {
    return rewriter.process(node, context);
  }
@Test
  public void shouldRewriteStatements() {
    // Given:
    final Statement statement1 = mock(Statement.class);
    final Statement statement2 = mock(Statement.class);
    final Statement rewritten1 = mock(Statement.class);
    final Statement rewritten2 = mock(Statement.class);
    final Statements statements =
        new Statements(location, ImmutableList.of(statement1, statement2));
    when(mockRewriter.apply(statement1, context)).thenReturn(rewritten1);
    when(mockRewriter.apply(statement2, context)).thenReturn(rewritten2);

    // When:
    final AstNode rewritten = rewriter.rewrite(statements, context);

    // Then:
    assertThat(
        rewritten,
        equalTo(new Statements(location, ImmutableList.of(rewritten1, rewritten2)))
    );
  }