On 7/20/06, Sreedevi Aswath <[EMAIL PROTECTED]> wrote:
Hi, It would be great if there could be a mock up for the JSF components too. That way, the unit tests for managed beans would be easier whenever there is a valuebinding involved.
I don't completely understand what you are after here. Are you trying to test JSF components themselves, or are you trying to test your application's backing beans when there is a component tree for the current view already constructed? In the latter case, you don't need mock components at all ... just use real ones. The default setUp() procedure in AbstractJsfTestCase sets up a view root for you, and your customized setUp() method can programmatically construct whatever component tree you need in advance of executing each test case. Even in the former case (testing components themselves), I'm a bit fuzzy on why using the real component classes, instead of mocking them, doesn't satisfy your needs. Thanks,
Sreedevi.
Craig