@Test
public void testSwitchStatement() {

  Parser<Statement> parser = StatementParser.switchStatement(ExpressionParser.IDENTIFIER, SIMPLE_STATEMENT);
  TerminalParserTest.assertResult(parser, "switch (foo) {}", SwitchStatement.class, "switch (foo) {}");
  TerminalParserTest.assertResult(parser, "switch (foo) { default:}", SwitchStatement.class, "switch (foo) {}");
  TerminalParserTest.assertResult(parser, "switch (foo) { case foo:}",
      SwitchStatement.class, "switch (foo) { case foo:}");
  TerminalParserTest.assertResult(parser, "switch (foo) { case foo: case bar: baz;}",
      SwitchStatement.class, "switch (foo) { case foo: case bar: baz;}");
  TerminalParserTest.assertResult(parser, "switch (foo) { case foo: case bar: baz; default: x;}",
      SwitchStatement.class, "switch (foo) { case foo: case bar: baz; default: x;}");
}