use of com.goide.psi.GoExpression in project go-lang-idea-plugin by go-lang-plugin-org.
the class GoExpressionUtilTest method doTest.
@Override
protected void doTest() {
PsiFile file = myFixture.configureByText("a.go", "package main\n func foo(i interface{}, j interface{}){}\n" + vars + "\n func _(){\n fo<caret>o(" + left + ", " + right + ")\n}");
myFixture.checkHighlighting();
GoCallExpr call = PsiTreeUtil.getParentOfType(file.findElementAt(myFixture.getCaretOffset()), GoCallExpr.class);
assert call != null;
List<GoExpression> expressions = call.getArgumentList().getExpressionList();
assertTrue(left + " should " + (ok ? "" : "not ") + "be identical " + right, ok == GoExpressionUtil.identical(expressions.get(0), expressions.get(1)));
}
Aggregations