[jboss-user] [JBoss Seam] - Testing FacesMessages with wmbedded container and injection
dsvmacdonald@nuarch.com
do-not-reply at jboss.com
Mon Jan 15 22:29:45 EST 2007
When I try to test my login module using a TestNG integration test, it throws the following error:
[testng] javax.ejb.EJBException: javax.el.PropertyNotFoundException: Property 'jboss' is not found on type: org.jboss.seam.Namespace
After some debugging, I have tracked down the error message to the fact that I am injecting the FacesNessages in my LoginAction class using
@In(create=true)
private FacesMessages facesMessages;
and
facesMessages.addFromResourceBundle("some message");
in the login method.
If I rewrite the LogicAction class to use FacesMessages w/o injection, such as
FacesMessages.instance().addFromResourceBundle("some message");
it compiles fine and runs to completion. However, the assertion fails when I check the FacesMessages b/c it is null.
Any ideas on how to fix this?
Thanks,
Dan
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4002084#4002084
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4002084
More information about the jboss-user
mailing list