This content has been marked as final.
Show 2 replies
-
1. Re: Setting ID:s for mocked components
ssilvert Apr 14, 2010 10:06 AM (in response to nickarls)Hi Nicklas,
You don't normally need to use mocks with JSFUnit. Since you are in container and you are running the real JSF implementation you just use the real component references.
I don't know why your mock doesn't return the ID you set for it. That's up to the mock implementation. Is there some reason you think it has to do with the JSFUnit environment?
Stan
-
2. Re: Setting ID:s for mocked components
nickarls Apr 14, 2010 3:08 PM (in response to ssilvert)Actually I just need some standalone, concrete UIComponent to pass along to a JSF component event in a unit test and since I already had JSFUnit as a dependency I thought I could get away with the snippet I posted but apparently it's not designed for isolated usage like that (the setter/getter don't appear to be directly linked to a field in the implementation).