eddyd
|
Posted: April 24, 2009 00:02 by eddyd
|
|
The code I need to unit test depends on JSF for messages and IOC. There are pieces like these: FacesContext context = FacesContext.getCurrentInstance(); context.addMessage(null, new FacesMessage("add entry failed - see log for details")); FacesContext context = FacesContext.getCurrentInstance(); ELResolver elResolver = context.getApplication().getELResolver(); ELContext elContext = context.getELContext(); dbManager = (DBManagerResident) elResolver.getValue( elContext, null, dbManagerResidentName); Can I only set "facestester.webAppPath" and create "new FacesTester()" in JUnit setUp and then have the FacesContext properly set for the tests? |
Does it allow to test the IOC side of JSF?
Replies: 2 - Last Post: April 27, 2009 09:49
by: eddyd
by: eddyd
showing 1 - 3 of 3
Replies: 2 - Last Post: April 27, 2009 09:49
by: eddyd
by: eddyd






