" select {" +
" case i1 := <-c1: {}" +
" } " +
"}"));
GoSelectStatement selectStatement =
castAs(GoSelectStatement.class, 0,
get(
childAt(0,
file.getFunctions()
).getBlock()
).getStatements()
);
assertEquals(1, selectStatement.getCommClauses().length);
GoSelectCommClauseRecv clauseRecv =
castAs(GoSelectCommClauseRecv.class,
0, selectStatement.getCommClauses());
assertNotNull(clauseRecv.getShortVarDeclaration());
assertEquals(1, clauseRecv.getShortVarDeclaration().getDeclarations().length);
assertEquals("i1", childAt(0, clauseRecv.getShortVarDeclaration().getDeclarations()).getText());