> >>> proper scope - Shale doesn't read faces-config.
> > >>>
> > >>> Sent from my iPhone
> > >>>
> > >>>
> > >>> On May 19, 2008, at 11:07 AM, "Venkataganesh Thoppae" <
> > >>&
The shale mock value binding has limited EL support.
[] #parse -
http://svn.apache.org/viewvc/shale/framework/trunk/shale-test/src/main/java/org/apache/shale/test/mock/MockValueBinding.java?view=markup
-- Original message --
From: "Venkataganesh Thoppae" <[EMAIL
Actually I missed that part while typing a sample code.
But here is a clean test case runnable if you have shale-test-x.jar.
Appreciate if someone could try this on their box.
Two files are attached.
MyTestCase.java has test cases defined.
SomeBean is a simple POJO.
Thanks
On Tue, May 20, 2008 a
I think in JSF 1.1 you have to get the value from a ValueBinding. See
below.
@Test
public void test1 {
ValueBinding binding = facesContext.getApplication
().createValueBinding("#{someBean.prop[0]}"};
String val = (String) binding.getValue(facesContext);
assertEquals(val, "M");
}
Yes, I know Shale doesn't read faces-config.
Here is a sample implementation.
public class MyTestCase extends AbstractJsfTestCase {
//A valid someBean object is created in the request scope in setUp()
@Test
public void test1 {
String val=
(String)facesContext.getApplication().createValueBindi
Hmm... What errors are you getting? Or is it just returning null? If
it's just returning null, remember that you must manually but the bean
in the proper scope - Shale doesn't read faces-config.
Sent from my iPhone
On May 19, 2008, at 11:07 AM, "Venkataganesh Thoppae" <[EMAIL PROTECTED]
> w
New user of Shale Test framework. I'm trying to write some test cases for
JSF 1.1 implementation using AbstractJsfTestCase.
Experiencing few problems while trying to resolve some EL expressions
programmatically.
- MockVariableResolver not able to resolve array elements like
#{someBean.property[0]}