use of org.eclipse.core.internal.expressions.NotExpression in project eclipse.platform.runtime by eclipse.
the class ExpressionTests method testNotExpressionNotEqual.
public void testNotExpressionNotEqual() throws Exception {
NotExpression expression1 = new NotExpression(new InstanceofExpression("org.eclipse.core.internal.expressions.tests.Adapter1"));
NotExpression expression2 = new NotExpression(new InstanceofExpression("org.eclipse.core.internal.expressions.tests.Adapter2"));
assertTrue("These not expressions should not be equal", !expression1.equals(expression2));
}
use of org.eclipse.core.internal.expressions.NotExpression in project eclipse.platform.runtime by eclipse.
the class ExpressionTests method testNotExpressionHashCode.
public void testNotExpressionHashCode() throws Exception {
NotExpression expression1 = new NotExpression(new InstanceofExpression("org.eclipse.core.internal.expressions.tests.Adapter"));
NotExpression expression2 = new NotExpression(new InstanceofExpression("org.eclipse.core.internal.expressions.tests.Adapter"));
assertEquals("Equal expressions should have the same hash code", expression1.hashCode(), expression2.hashCode());
}
Aggregations