use of javax.el.MethodExpression in project tomcat by apache.
the class TestMethodExpressionImpl method testInvokeWithVarArgsAABB.
@Test
public void testInvokeWithVarArgsAABB() throws Exception {
MethodExpression me5 = factory.createMethodExpression(context, "${beanC.sayHello(beanAA,beanBB,beanBB)}", null, null);
Object r5 = me5.invoke(context, null);
assertEquals("ABB[]: Hello AA from BB, BB", r5.toString());
}
use of javax.el.MethodExpression in project tomcat by apache.
the class TestMethodExpressionImpl method testBug56797a.
@Test
public void testBug56797a() {
MethodExpression me = factory.createMethodExpression(context, "${beanAA.echo1('Hello World!')}", null, null);
Object r = me.invoke(context, null);
assertEquals("AA1Hello World!", r.toString());
}
use of javax.el.MethodExpression in project tomcat by apache.
the class TestMethodExpressionImpl method testBug56797b.
@Test
public void testBug56797b() {
MethodExpression me = factory.createMethodExpression(context, "${beanAA.echo2('Hello World!')}", null, null);
Object r = me.invoke(context, null);
assertEquals("AA2Hello World!", r.toString());
}
use of javax.el.MethodExpression in project tomcat by apache.
the class TestMethodExpressionImpl method testInvokeWithVarArgsAB.
@Test
public void testInvokeWithVarArgsAB() throws Exception {
MethodExpression me1 = factory.createMethodExpression(context, "${beanC.sayHello(beanA,beanB,beanB)}", null, null);
Exception e = null;
try {
me1.invoke(context, null);
} catch (Exception e1) {
e = e1;
}
// Expected to fail
assertNotNull(e);
}
use of javax.el.MethodExpression in project tomcat by apache.
the class TestMethodExpressionImpl method testInvokeWithVarArgsABB.
@Test
public void testInvokeWithVarArgsABB() throws Exception {
MethodExpression me2 = factory.createMethodExpression(context, "${beanC.sayHello(beanA,beanBB,beanBB)}", null, null);
Object r2 = me2.invoke(context, null);
assertEquals("ABB[]: Hello A from BB, BB", r2.toString());
}
Aggregations