"christian.bauer(a)jboss.com" wrote : Run it inside a SeamTest.
|
Does your answer mean that EntityController subclasses can be tested in an integration
test, but not in a unit test if they rely on a logger or faces messages?
public class MyEntityControllerTest extends SeamTest
| {
|
| @Test
| public void testEntityController()
| {
| try
| {
| new FacesRequest()
| {
| @Override
| protected void invokeApplication()
| {
| assert
invokeMethod("#{myEntityController.save}").equals("OK");
| }
| }.run();
| } catch (Exception e)
| {
| Logging.getLog(MyEntityControllerTest.class).error(e.getMessage());
| }
| }
| }
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4066623#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...